It is currently Mon, 25 Sep 2023 10:56:34 GMT



 
Author Message
 2K grep problem
Does anyone know how to make a grep in files with line lengths of more than
2K?
If you perform this command:
        find . -type f -print | xargs grep -i what-ever
AIX will fail several times with this error:
        grep: 0652-226 Maximum line length of 2048 exceeded.
Linux and Solaris doesn't have this limitation, so I was wondering why AIX
does and what can be done about it. Any ideas?

Thanks
Bent



 Sat, 13 Sep 2003 14:46:59 GMT   
 2K grep problem
W artykule <985675654.419...@ns.cci.dk>, Bent Kirkegaard napisa3(a):

try to use

        find . -type f -exec grep what-ever {} /;

--
Jan Artysiewicz



 Sat, 13 Sep 2003 22:05:02 GMT   
 2K grep problem

Uhm? Why would that make a difference??

  palm.vcf
< 1K Download


 Sat, 13 Sep 2003 23:44:32 GMT   
 2K grep problem
Try something like that with awk :
find . -type f | awk '/what-ever/ {print $0}'
Awk is not as limited as grep
For the syntax awk in docsearch has lot of examples

Hoping to be helpfull
Henri

Bent Kirkegaard a crit :



 Sun, 14 Sep 2003 05:38:29 GMT   
 2K grep problem
W artykule <3AC0C362.7BB25...@nogui.se>, Christer Palm napisa3(a):

in first case it exands to

grep what-ever file1 file2 file3 file4 file5 ...

and this command line is too long

in second

grep what-ever file1
grep what-ever file2
grep what-ever file3
grep what-ever file4
grep what-ever file5
............

--
Jan Artysiewicz



 Sun, 14 Sep 2003 16:16:04 GMT   
 2K grep problem
Also try strings <file> | grep <what-ever>

news:3AC10855.541DC6CD@wanadoo.fr...



 Sun, 14 Sep 2003 17:22:32 GMT   
 2K grep problem

xargs never generates command lines that are too long...

  palm.vcf
< 1K Download


 Mon, 15 Sep 2003 00:07:55 GMT   
 2K grep problem

** I think the line limit came from the line limit in editors.  If you
can't edit it, you can't grep it.  Maybe you need to port the gnu grep?
Probably part of the linux toolkit.

--
Norman Levin

greatest power, the village idiot will come forth to be acclaimed the
leader.'"



 Tue, 16 Sep 2003 01:13:00 GMT   
 2K grep problem
W artykule <3AC21A56.E0B57...@nogui.se>, Christer Palm napisa3(a):

it's true
xargs generated argument that grep can not handle
it's a grep problem

--
Jan Artysiewicz



 Tue, 16 Sep 2003 16:52:04 GMT   
 2K grep problem

Perhaps the you should install the gnu version of grep and try if it is
better?

Andreas Funk

f...@physnet2.uni-hamburg.de



 Mon, 06 Oct 2003 22:36:52 GMT   
 
   [ 10 post ] 

Similar Threads

1. Grep 2K Line Length?

2. 2K over 2K Lite?

3. tail | grep | grep | grep

4. grep sTerm * | grep -v grep ???

5. Win 2K + Redhat 6.1 - boot problem

6. Strange Win 2K login problem

7. Problem with Windows 2K ICS

8. Samba & win 2k problems

9. problem with telnetting to Windows 2K Pro.

10. Kerberos problems with win 2k


 
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software