![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| remove a file after 30 days | dr46014 | Shell Programming and Scripting | 7 | 11-09-2007 09:06 AM |
| Find accessed file in past 1 or 2 minutes, and throw mail. | varungupta | UNIX for Advanced & Expert Users | 2 | 09-12-2007 03:07 AM |
| Find the file from 15 days ago | YoungBlood | Shell Programming and Scripting | 2 | 03-03-2007 07:28 PM |
| file was created before 15 days ago. | YoungBlood | UNIX for Dummies Questions & Answers | 1 | 03-02-2007 01:23 PM |
| ls latest 4 days or specify days of files in the directory | happyv | Shell Programming and Scripting | 3 | 01-22-2007 07:16 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Works for me, I get line counts here. You could see if changing the field numbers in the awk script would improve things (change $1 to $2 perhaps) but I highly doubt it will.
|
|
||||
|
find /data/XYZ -mtime -7 -name 'DailyFile*.txt' -print | xargs wc ...
How wc will be identify the list of record.if we are writing the below line entire records in the folder is getting displayed.Can you please tell me how to handle this means i need last 7 days record.Again the "xargs: a single arg was greater than the max arglist size of 2048 characters".becoz i need the MB GB info also in my csv file wc /data/XYZ/Daily_File*.txt | nawk -v OFS=, '{ print $4, $1, $3 }' |
|
||||
|
The xargs error message means that there is a single file name which is longer than 2048 bytes. This is a very low limit for ARG_MAX but not unheard of. If you can cd into the directory and then use relative file names, that might be an acceptable workaround.
I don't understand "How [will] wc identify the list of record" |
![]() |
| Bookmarks |
| Tags |
| csv, file size |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|