- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- /var full
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
06-15-2006 10:28 PM
06-15-2006 10:28 PM
I have a problem. If I run the command "bdf /var", it outputs:
Filesystem kbytes used avail %used Mounted on
/dev/vg00/lvol8 5111808 5052688 58712 99% /var
Bur du -sk is: 1794504
I rebooted a lot of time, but it doesn't solve the problem.
Can someone help me?
Fabrizio
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:43 PM
06-15-2006 10:43 PM
Re: /var full
Find out what is occupying more.
# du -skx /var/* | sort -nr | head -10
-Arun
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:47 PM
06-15-2006 10:47 PM
Re: /var full
Also, if you have installed patches and no longer wish to keep copies for the ability to remove them, you can check how much space is in use under /var/adm/sw/save, and if ti is large then use swmodify to commit these patches or just remove the subdirectories under this directory
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 10:54 PM
06-15-2006 10:54 PM
Re: /var full
try
sam-->Routine Tasks-->System log files
and reduce the size of some of the logfiles.
regards,
John K.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:00 PM
06-15-2006 11:00 PM
Re: /var full
# find /var -xdev -type f -exec ll {} \;| awk '{ printf "%9d %3s %2d %5s %s\n" , $5, $6 , $7, $8, $9 }'|sort -r -n > /tmp/var.txt &
# more /tmp/var.txt
Others tasks,
Modifify /sbin/clean_tmps and /etc/rc.config.d/clean_tmps, for delete files in directory /var/tmp afther reboot.
Verify file /sbin/clean_adm and /etc/rc.config.d/clean for others clean files.
rgs,
ran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:11 PM
06-15-2006 11:11 PM
Re: /var full
Usually the difference in sizes shown by bdf/df and du (Usually du shows lesser than df in such cases) is because some process opens a file and then terminates before closing the file leaving the space unreleased.
But once you reboor these should more or less tally.
Next thing is how you check /var using du -
it should be du -skx /var (Because usually there are other filesystems mounted in /var like /var/tmp , /var/adm ...), if you just use du -sk it will show disk usage by all files/directories under /var DIRECTORY and will not show the disk usage of files/directories in /var FILESYSTEM.
Now solving the problem as already suggested above, check for crash files, core files
find /var -xdev -name core
Also
du -sk /var/* | sort -nr | more
to check highest disk using directories - but then you need to check that they are not seperate filesystems and are infact files/directories in /var filesystem .
And cleanup unwanted stuff.
Regards,
Ninad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:17 PM
06-15-2006 11:17 PM
Re: /var full
Heres a script which will show highest disk using directories in /var FILESYSTEM (as /var DIRECTORY may contain various filesystems which you need not see as /var FILESYSTEM is full )
du -sk /var/* | sort -nr| while read dirsize dirname
do
if [[ $(bdf $dirname | grep -c '/var$') != 0 ]]
then
echo $dirname $dirsize
fi
done
Regards,
Ninad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:25 PM
06-15-2006 11:25 PM
Re: /var full
You might also find it helpful to look at files which have been recently created/modified:
# find /var -xdev -type f -mtime -3 -exec ll {} \; |sort -k5
Also have a good long look at the contents of /var/tmp.
PCS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:27 PM
06-15-2006 11:27 PM
Solution/var/adm/syslog
/var/adm/lp
/var/mail
/var/adm/wtmp (to big?)
/var/adm/lp/log
/var/spool/lp/request
/var/spool/cron/tmp
/var/sam/log
/var/spool/mqueue
lost+found (found in any mounted file system)
Did you mount a filesystem *ON* another filesystem in /var (thus hiding what's underneath)?
Remove core files in /var?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:44 PM
06-15-2006 11:44 PM
Re: /var full
The system (HP-UX 11.23 Itanium) is new, only few weeks of life...
No software installed, only OS.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2006 11:58 PM
06-15-2006 11:58 PM
Re: /var full
get space in /var/adm/sw/save,
# cleanup -p -c 2 (previous)
# cleanup -c 2 (commit)
rgs,
ran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 12:03 AM
06-16-2006 12:03 AM
Re: /var full
What gives
cleanup -p -c 2
(this is preview mode only)
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 12:03 AM
06-16-2006 12:03 AM
Re: /var full
The used space in /var/adm/sw/save is the same for all servers. So this is not the problem...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 12:05 AM
06-16-2006 12:05 AM
Re: /var full
According to your 'bdf' output, you have 58,712 kbytes free. What happens if you create a 60,000 kbyte file? Does the /var filesystem fill up?
prealloc /var/tmp/foo 60000000
PCS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 12:37 AM
06-16-2006 12:37 AM
Re: /var full
No space left on device.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 12:56 AM
06-16-2006 12:56 AM
Re: /var full
Did you try running the script I gave you to show max space occupying directories ?
Any clue from that on where is the space going ?
I also suggest you to run lsof to see list of open files to check which files in /var are open to get a clue if there is a big file not being closed by a dead process.
You can install lsof from
http://hpux.connect.org.uk/hppd/hpux/Sysadmin/lsof-4.77/
Regards,
Ninad
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 01:10 AM
06-16-2006 01:10 AM
Re: /var full
Please post output of:
du -skx /var/* | sort -nr | head -10
find /var -type f -xdev -size +5000000c -exec ll {} \;
PCS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 01:20 AM
06-16-2006 01:20 AM
Re: /var full
du -skx /var/* | sort -nr | head -10
1670904 /var/adm
82480 /var/opt
22768 /var/jail
17128 /var/stm
616 /var/vx
264 /var/sam
128 /var/tmp
120 /var/spool
104 /var/tombstones
96 /var/yp
Second output in attachment.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-16-2006 01:34 AM
06-16-2006 01:34 AM
Re: /var full
This would seem to fit either the case of (1) a process that has created a file and unlinked (removed); and the process is still running [a common technique]; or (2) an over-mounted filesystem.
Using 'lsof' or even a combination of 'fuser' (to find processes using '/var') and 'glance' to view open files by the processes using '/var', might prove fruitful for case-1.
For case-2, run 'ncheck' and look for paths that should not appear beneath '/var':
# ncheck -F vxfs /dev/vg00/lvol8
Regards!
...JRF...