- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: how can i find the file that it increased most...
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
10-19-2004 01:27 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-19-2004 01:59 PM
10-19-2004 01:59 PM
SolutionHere is a simple way.
filename=$(date)
cd /
du -k | sort -rn > /tmp/$filename
Have cron run it once a day.
Then you can compare the data between the two files and figure out which one had the most growth.
I don't have time to script that right now, but if you look at the output you'll get the idea.
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
10-19-2004 02:35 PM
10-19-2004 02:35 PM
Re: how can i find the file that it increased most quickly?
You might want to reduce the number of files to monitor by setting a lower threshold of say 2.5MB, suggesting that any growth below that level is not too interesting.
So that would mean something like (untested)
filename=$(date)
find / -size +5000 -exec du -k {} \; | sort -k 2 > /xxx/$filename.xxx
:
diff...
Hein.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-19-2004 03:35 PM
10-19-2004 03:35 PM
Re: how can i find the file that it increased most quickly?
I would rely on the size and a recent time stamp of it. For ex., if you are seeing it increased in the last 5 minutes, then find all the files that are above 10 MB but modified within last 5 mins. To do that, touch a file with a time stamp less than five minutes ago and then use it as a reference with -newer option.
touch 1019103004 /tmp/stamp
find /directory -newer /tmp/stamp -size 10000000c
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-19-2004 04:34 PM
10-19-2004 04:34 PM
Re: how can i find the file that it increased most quickly?
Hein.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-19-2004 06:01 PM
10-19-2004 06:01 PM
Re: how can i find the file that it increased most quickly?
find / -type f -exec ls -s {} \; > /tmp/sizereport_$(date +'%b_%e_%H')
do cron this, so that you will get reports based on the cron execution time.
It will give format of file informations as,
size filename.
Log file represents /tmp/sizereport_Month_date_hour
HTH.