File size limit exceeded in bash

Posted by yboren on Server Fault See other posts from Server Fault or by yboren
Published on 2012-09-18T05:09:07Z Indexed on 2012/09/18 9:40 UTC
Read the original article Hit count: 187

Filed under:
|
|
|

I have tried this shell script on a SUSE 10 server, kernel 2.6.16.60, ext3 filesystem

the script has problem like this:

cat file | awk '{print $1" "$2" "$3}' | sort -n > result

the file's size is about 3.2G, and I get such error message: File size limit exceeded

in this shell, ulimit -f is unlimited

after I change script into this

cat file | awk '{print $1" "$2" "$3}' >tmp
sort -n tmp > result

the problem is gone.

I don't know why, can anyone help me with an explanation?

© Server Fault or respective owner

Related posts about shell

Related posts about awk