Sign up ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

While running the script called abc.sh, following errors are thrown.

 abc.sh: line 226: storage allocator out of space on 64946176 byte request ( region 64329285632 segments 1981 busy 202:65087584:64913312 free 1983:64264004608:64880544 ) [Cannot allocate memory]

Line number 226 has the following

  226  sed 's/||/|/g' sales.txt >>sales.1.txt
  227  var_check=`awk -F '|' 'NF!=22{print $0}' sales.1.txt`

Please let me know what might be the issue.

PS: This is not a script generated error message and not UNIX disk space issue as the environment has 40% free space left.

share|improve this question
    
we are not aware of any abc.sh, can you show us at least line 226 ? or give more context about what you are trying to do ? –  Archemar Jul 24 at 7:36
    
edited the question, Please check –  VRVigneshwara Jul 24 at 7:39
    
can the error be reproduce using the sed command ? or the var affectation below ? how big are sales.txt (though I don't think this is the issue). –  Archemar Jul 24 at 7:53
    
it is a 74 MB file. I have no idea what is var affectation ? can you please elaborate on that. –  VRVigneshwara Jul 24 at 8:08
    
According to Google 64946176 bytes = 65mb Could you also provide the output of cat /proc/meminfo? –  eyoung100 Jul 24 at 21:50

1 Answer 1

up vote 0 down vote accepted

It is because I was using a huge file in awk command which couldn't support huge data. I split it up in to two so that size was reduced and issue was solved.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.