- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- shrinking log files
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
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
09-25-2003 03:55 AM
09-25-2003 03:55 AM
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2003 03:59 AM
09-25-2003 03:59 AM
Re: shrinking log files
We also run this script once a month:
cp swagentd.log > /backups/sdux
> swagentd.log
That nulls it out.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2003 04:05 AM
09-25-2003 04:05 AM
Re: shrinking log files
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2003 04:07 AM
09-25-2003 04:07 AM
SolutionSAM has a built-in log trimming utility.
Go to:
sam & -> Routine Tasks -> System Log Files -> highlight the log file (sw*.log are there already) -> Actions -> Trim -> select trim method.
You could then capture SAMs method/commands from the sam log & build a script to run from cron.
HTH,
Jeff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2003 04:12 AM
09-25-2003 04:12 AM
Re: shrinking log files
Try this out. This empties the swagentd.log.
As far, trimming down, Jeff's suggestion is easy and good one.
cat /dev/null > swagentd.log.
HTH,
Umapathy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2003 04:16 AM
09-25-2003 04:16 AM
Re: shrinking log files
/sbin/init.d/swagentd stop
> /var/adm/sw/swagentd.log
/sbin/init.d/swagentd start
The earlier command porbably failed because the daemon was running.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2003 06:13 AM
09-25-2003 06:13 AM
Re: shrinking log files
-GK-
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-25-2003 06:45 AM
09-25-2003 06:45 AM
Re: shrinking log files
What I usually do is in the log rotater script, I have a routine there that once the current large log is copied to a different location, I do a cp /dev/null /var/adm/someactive.log.
The reason is that sometimes, even if you have deleted that large active log file on a filesystem, it does not free up the space occupied by the deleted file...