Results 1 to 9 of 9
  1. #1
    Join Date
    Aug 2004
    Posts
    16

    Unanswered: bcp out fails after file size reaches 2GB

    When i try to bcp out a table it fails as soon as the file size reaches 2 GB ? Unix file system is large file aware and permits files larger than 2 GB so is this a sybase limitation.

  2. #2
    Join Date
    Nov 2002
    Location
    Switzerland
    Posts
    524
    Yes, this is a limitation on Unix.

    You have to create a script executing the bcp command into a loop, using the [-F firstrow] and [-L lastrow] options
    F. Celaia
    DBA Sybase/DB2/Oracle/MS-SQL

  3. #3
    Join Date
    Aug 2004
    Posts
    16
    I was under the impression that if the unix file system is large file aware than the file size can go beyond 2 GB.

    If this is a sybase limitation , do we have it anywhere in the manuals or any sybase documentation.

  4. #4
    Join Date
    Jun 2004
    Posts
    17
    like fadace said you should try this ;-)

    my tables is about 8Go of data with more than 12 million lines . so i bcp out creating 4 files, each file is almost 2Go :

    it creates a first files from line 1 to line N 4 million then another from line number 4000001 to 8000000 ...Etc

    bcp ADMIN..avrl out avrl_1.bcp -Usa -S${SERVER} -P${SAPW} -n -F 1 -L 4000000
    bcp ADMIN..avrl out avrl_2.bcp -Usa -S${SERVER} -P${SAPW} -n -F 4000001 -L 8000000
    bcp ADMIN..avrl out avrl_3.bcp -Usa -S${SERVER} -P${SAPW} -n -F 8000001 -L 12000000
    bcp ADMIN..avrl out avrl_4.bcp -Usa -S${SERVER} -P${SAPW} -n -F 12000001

  5. #5
    Join Date
    Aug 2004
    Posts
    16
    I was aware of -F and -L options . What actually happened was that we send out data to some other systems in a single file, just this month it has reached 2 GB limit and i wanted to be sure on the fact that 2GB is a sybase limitation and not a unix limitation before i went to the other team and told them that you have to modify your application to receive 2 files from us from now on

    Is there any documentation availaible on the max file size of 2 GB permitted by Sybase in bcp , i am surprised that they do not mention this anywhere in there manuals

  6. #6
    Join Date
    Mar 2003
    Location
    Vienna
    Posts
    24

    Operationg system

    Quote Originally Posted by mspahwa
    I was aware of -F and -L options . What actually happened was that we send out data to some other systems in a single file, just this month it has reached 2 GB limit and i wanted to be sure on the fact that 2GB is a sybase limitation and not a unix limitation before i went to the other team and told them that you have to modify your application to receive 2 files from us from now on

    Is there any documentation availaible on the max file size of 2 GB permitted by Sybase in bcp , i am surprised that they do not mention this anywhere in there manuals
    I believe that the limit of 2 GBs is an operating system limit. We had similiar problem with our Solaris machines.
    kdb is the solution of all problems.
    Just try it, www.kx.com

  7. #7
    Join Date
    Aug 2004
    Posts
    16
    I also beleived so till yesterday but i concatenated the 2 bcp out files i created by -F and -L options and now i have a 2.5 GB file on the system.

    OS is a problem but in my case solaris is large file aware and allows greater than 2 GB files.

    So what could be the problem

  8. #8
    Join Date
    Jan 2003
    Posts
    26
    What version of ASE are you running? Some of the older versions couldn't handle devices larger than 2gb so I would assume that you couldn't create a bcp out file larger than that either.
    http://www.sybase.com/detail?id=800

  9. #9
    Join Date
    Nov 2002
    Location
    Switzerland
    Posts
    524
    Your concatenation is proving nothing. The operating system is able to concatenate 2 big files, but the 2Gb limitation is a problem of physical addresses
    F. Celaia
    DBA Sybase/DB2/Oracle/MS-SQL

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •