egrep error - Unix

This is a discussion on egrep error - Unix ; Hi! Even though I try to use egrep in windows I posted this here because I thought I can get better help here. So this is what I try to run in a batch file, but egrep just gives me ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: egrep error

  1. egrep error

    Hi!

    Even though I try to use egrep in windows I posted this here because I
    thought I can get better help here.
    So this is what I try to run in a batch file, but egrep just gives me an
    error message.

    for %%a in (o:\logs\users\*.txt) do type %%a >> allu.tmp
    egrep -v allu.tmp > loginsu.tmp
    sort < loginsu.tmp > loginuse.txt

    Error message:
    egrep: (standard input): Not enough space

    Regardless how big is the allu.tmp file I get this error. I can see the
    loginsu.tmp file grow as egrep is processing the allu.tmp, but when it
    supposedly gets to the end it terminates with the error and the
    loginsu.tmp file ends up being a zero size file.
    Would anyone know what is going on? There can't be a shortage of space
    on the hard disk, there are lots of it free. I tried to run the batch
    file in both Windows 2000 and 2003.

  2. Re: egrep error

    In article ,
    ICS wrote:

    > Hi!
    >
    > Even though I try to use egrep in windows I posted this here because I
    > thought I can get better help here.
    > So this is what I try to run in a batch file, but egrep just gives me an
    > error message.
    >
    > for %%a in (o:\logs\users\*.txt) do type %%a >> allu.tmp
    > egrep -v allu.tmp > loginsu.tmp


    You're missing an argument to egrep -- you've given a filename, but
    haven't given a regular expression. So I'd expect it to use allu.tmp as
    the regular expression, and process standard input.

    > sort < loginsu.tmp > loginuse.txt
    >
    > Error message:
    > egrep: (standard input): Not enough space
    >
    > Regardless how big is the allu.tmp file I get this error. I can see the
    > loginsu.tmp file grow as egrep is processing the allu.tmp, but when it
    > supposedly gets to the end it terminates with the error and the
    > loginsu.tmp file ends up being a zero size file.
    > Would anyone know what is going on? There can't be a shortage of space
    > on the hard disk, there are lots of it free. I tried to run the batch
    > file in both Windows 2000 and 2003.


    --
    Barry Margolin, barmar@alum.mit.edu
    Arlington, MA
    *** PLEASE post questions in newsgroups, not directly to me ***
    *** PLEASE don't copy me on replies, I'll read them in the group ***

+ Reply to Thread