Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: arg list too long in unix

Re: arg list too long in unix

From: Joe Testa <jtesta_at_dmc-it.com>
Date: Thu, 29 Aug 2002 15:47:28 -0800
Message-ID: <F001.004C37A6.20020829154728@fatcity.com>


ls -1 cz* > /tmp/1.1
vi /tmp/1.1
:1,$ s/^/rm -f /
ZZ
/tmp/1.1

joe

Philip Douglass wrote:

>I'm not sure xargs will work -- it seems to me that since xargs is
>typically invoked as: 'ls cz* | xargs rm', Nuno is likely to get the same
>arg list too long error. I think the best way to delete the files would
>be: 'find . -name cz\* -exec rm -f {} \;'
>
>-- Philip
>
>----- Original Message -----
>To: "Multiple recipients of list ORACLE-L" <ORACLE-L_at_fatcity.com>
>Sent: Thursday, August 29, 2002 7:43 AM
>
>
>Use the "xargs" command.
>Read about it in the man pages.
>Or use "find", but that is more complex.
>
>Cheers
>Nuno Souto
>nsouto_at_optushome.com.au
>
>----- Original Message -----
>
>>OS: SOlaris 2.8
>>DB: 8i
>>
>>In the clean up process of the following files, I am
>>trying to list out the files that start with cz.
>>
>> cz-session-returnui177_11Jan02_0959AM_33509.txt
>> cz-session-Applet178_11Jan02_0959AM_34108.txt
>> cz-session-returnui175_11Jan02_0959AM_20504.txt
>> cz-session-DHTML176_11Jan02_0959AM_22335.txt
>> cz-session-returnui179_11Jan02_1000AM_34566.txt
>> cz-session-Applet180_11Jan02_1000AM_34818.txt
>> cz-session-BatchSingle181_11Jan02_1001AM_07757.txt
>> cz-session-BatchSingle182_11Jan02_1001AM_11687.txt
>> cz-session-BatchSingle183_11Jan02_1001AM_14010.txt
>> cz-session-BatchSingle184_11Jan02_1001AM_17708.txt
>> cz-session-BatchSingle185_11Jan02_1001AM_20029.txt
>>
>>but when I issue ls -ltr cz* , I am getting arg list
>>too long error. I 70,000-80,000 files that needs to be
>>removed from the directory.
>>
>>I cant list them using ls -ltr *session* as this
>>string may change. I have to identify the files that
>>srart with cz only.
>>
>>can somebody through somelight on this.
>>
>
>
>--
>Please see the official ORACLE-L FAQ: http://www.orafaq.com
>--
>Author: Nuno Souto
> INET: nsouto_at_optushome.com.au
>
>Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
>San Diego, California -- Public Internet access / Mailing Lists
>--------------------------------------------------------------------
>To REMOVE yourself from this mailing list, send an E-Mail message
>to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
>the message BODY, include a line containing: UNSUB ORACLE-L
>(or the name of mailing list you want to be removed from). You may
>also send the HELP command for other information (like subscribing).
>
>

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Joe Testa
  INET: jtesta_at_dmc-it.com

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Thu Aug 29 2002 - 18:47:28 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US