The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Operating Systems > SUN Solaris
.
google unix.com



SUN Solaris The Solaris Operating System, usually known simply as Solaris, is a free Unix-based operating system introduced by Sun Microsystems .

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Remove the date from the file pradkumar UNIX for Dummies Questions & Answers 5 01-10-2008 01:36 AM
Remove out date logs eric_wong_ch Shell Programming and Scripting 2 10-09-2007 11:52 AM
how to remove files with a date justintime Shell Programming and Scripting 5 09-10-2006 10:50 PM
How do I take out(remove) the date part in the file name? ruthless HP-UX 5 02-06-2006 01:32 PM
Remove files based on date hshapiro UNIX for Dummies Questions & Answers 4 12-09-2005 12:21 PM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 05-30-2008
cvdev cvdev is offline
Registered User
  
 

Join Date: May 2008
Posts: 8
Remove logs by date

Hi

I Need To Remove Logs Older Than April 1 St(4/1/2007) By Date

I Have A Script To Remove 3 Months Old Like Using 90 Days

Thanks
  #2 (permalink)  
Old 05-30-2008
ripat ripat is offline Forum Advisor  
Registered User
  
 

Join Date: Oct 2006
Location: Belgium
Posts: 438
Provide a sample file we can work on please.
  #3 (permalink)  
Old 05-30-2008
cvdev cvdev is offline
Registered User
  
 

Join Date: May 2008
Posts: 8
like

xxxxx.log.20070509125745
xxxxx.log.20070103113245
xxxxx.log.20070314105745
xxxxx.log.20070219215715
xxxxx.log.20070429162035
  #4 (permalink)  
Old 05-31-2008
ripat ripat is offline Forum Advisor  
Registered User
  
 

Join Date: Oct 2006
Location: Belgium
Posts: 438
With awk:

Code:
awk -F"." '$3 > 20070401000000' file
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 11:39 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0