Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 09:18 PM
06-27-2002 09:18 PM
after 4 days, it will be moved to OLDsyslog.log
now I want the syslog.log keeps only one day
info. how can I do?
Thanks!
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 09:20 PM
06-27-2002 09:20 PM
Re: syslog
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 09:22 PM
06-27-2002 09:22 PM
Re: syslog
Kurt
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 09:26 PM
06-27-2002 09:26 PM
Re: syslog
but I want the syslog.log keeps only one day
info. the other will keep in OLDsyslog.log.
how can I do?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 09:29 PM
06-27-2002 09:29 PM
Re: syslog
but I want the syslog.log keeps only one day
info. the other will keep in OLDsyslog.log.
how can I do?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 09:31 PM
06-27-2002 09:31 PM
Re: syslog
but I want the syslog.log keeps only one day
info. the other will keep in OLDsyslog.log.
how can I do?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 09:32 PM
06-27-2002 09:32 PM
Re: syslog
but I want the syslog.log keeps only one day
info. the other will keep in OLDsyslog.log.
how can I do?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 10:01 PM
06-27-2002 10:01 PM
Re: syslog
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x77928cc5e03fd6118fff0090279cd0f9,00.html
Good luck,
Hartmut
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 10:32 PM
06-27-2002 10:32 PM
Re: syslog
you should just write a simple script, which can do this for you:
cp /var/adm/syslog/syslog.log /var/adm/syslog/syslog.old
> /var/adm/syslog/syslog.log
The first line makes a copy of your existing logfile, the second line trims the syslog.log file to zero. Put this into a cron job, which you run each day on midnight. That should do it for you!
Allways stay on the bright side of life!
Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-27-2002 10:37 PM
06-27-2002 10:37 PM
SolutionFirst create a shell script
flush_syslog as shown below.
#!/usr/bin/ksh
cp /var/adm/syslog/syslog.log /var/adm/syslog/syslog.`date +%d%b%y`
>/var/adm/syslog/syslog.log
This above script will create a syslog file for each day with the time stamp.
And later schedule a cronjob for root as below which is executed everyday.
59 23 * * * sh /usr/sbin/flush_syslog
-Sukant