/var partition full need help


 
Thread Tools Search this Thread
Operating Systems HP-UX /var partition full need help
# 1  
Old 02-23-2012
/var partition full need help

My /var partition is almost utilized ... Here am not sure where to release space now

OS/model : HP-UX B.11.11 U 9000/800

Code:
# bdf /var
Filesystem          kbytes    used   avail %used Mounted on
/dev/vg00/lvol9    6144000 6142176    1824  100% /var

<root@pb>/var # du -sk * | sort -n | egrep -v ^0
8       ovsuf
8       ovsuf.orig
16      statmon
24      run
32      config.txt
192     dt
392     preserve
408     asx
416     yp
472     spool
648     sam
760     tombstones
2440    tmp
10528   ios
24368   stm
74776   vx
1890784 adm

Code:
<root@pb>/var/adm # du -sk * | sort -n | egrep -v "^0|^8"
16      ptydaemonlog
16      snmpd.log
16      vtdaemonlog
24      ps_data
40      nettl.LOG000
40      syslog
272     cron
272     wtmp
1889936 sw

Any suggestion are welcome ...

--Shirish Shukla

---------- Post updated at 09:53 AM ---------- Previous update was at 09:44 AM ----------

Have already deleted as much log file can like syslog.log and mail.log from /var/adm/syslog
Am wondering if can do any thing for this dir
Code:
/var/ios
/var/stm
/var/vx
Anything can do with /var/adm/wtmp (As I know can do this with single user mode only am not sure )
/var/adm/sw 
/var/opt/sanmgr
/var/opt/perf

/var/opt/gcc
/var/opt/wbem

Excuse if am asking silly Que ... as am new on hp-ux and not aware of use of these dir/files

--Shirish
# 2  
Old 02-23-2012
Deleting logfiles usually makes the situation worse -- they're probably still in use so won't be deleted, and will exist on disk until the logger closes them. But they're no longer in the directory after you delete them, preventing you from doing anything to them!

Try restarting your logger to release the deleted files, and don't delete logfiles thereafter -- truncate them. Having it open won't let the logger stop you from doing that.

Code:
: > /path/to/file

# 3  
Old 02-23-2012
Thanks !!
have release about 20Mb space by doing so ... it's abruptly increases am not sure why before day it was about 60MB am not sure what happen ...
Have much space free on /usr if can mv and create symlink for any of directory mentioned above that is non critical as per OS term ..

--Shirish

---------- Post updated at 11:19 AM ---------- Previous update was at 10:36 AM ----------

Thanks have got the temporary solution have moved 30 MB of SAN archived logs
Code:
/var/opt/sanmgr/commandview/server/logs/performance

But still looking for long relief ...Smilie
# 4  
Old 02-23-2012
Your "bdf" and your "du -sk" do not agree. There's about 4 Gigabytes difference. That's ignoring the fact that "du -sk" follows links and can be much higher than "bdf".
You should be using "du -skx" to stop "du" traversing into other filesystems.

If you have been deleting (not nulling) active logs you probably need a reboot.

Beware that some system logging processes stop working completely if you delete their logs. Be prepared to create an empty log with exactly the same permissions as before if you find that a logging process stops working.
# 5  
Old 02-23-2012
Methyl , Thanks for this usefull info about du cmd .

Can I do any thing with my /var/adm/sw dir as near about 2.5 GB utilization by this ..
was wondering if can move it to /usr and create a symlink over here as below
Code:
 
 
/var/adm/sw   -->>  /usr/backup-var/sw 
 
or with any of below dirs ..
/var/ios
/var/stm
/var/vx
 
 
Which is less critical as per OS term ..am not aware ..

--Shirish
# 6  
Old 02-24-2012
Not a good idea...Unless you like fighting with funky issues....

That said in there (/var/adm/sw) you will find all the patches installed (and obsoleted, and uninstalled etc...) You may gain space by intellingently doing some cleanup, beware of the risk of not being able to "rollback" removed patches afterward... but very first superseeded patchs are of little risk...
What about /var/adm/syslog? what size are the logs there?
I trim them regularly ( customized by me though - important info in beginning syslog (at boot time) is always kept till next reboot...)

...
There are logs in /var/stm you can clean also and save 10-400 MB...
I have an old 10.20 that makes me sweat regularly (vital old legacy stuff nobody wanted to port : forms 3 with oracle 7.2.3...)
Code:
civ:/var/stm/logs/sys $ ll
total 434840
-rw-r--r--   1 root       root       220525916 Feb 24 11:29 activity_log
-rw-rw-r--   1 root       sys            878 May  5  2010 config.stm
-rw-r--r--   1 root       root          4584 Feb  2 09:02 diaglogd_activity_log
-rw-r--r--   1 root       root          5480 Feb  2 09:02 memlogd_activity_log
-rw-r--r--   1 root       root          5872 Feb  2 09:02 scan_hw_log
civ:/var/stm/logs/sys $ bdf /var
Filesystem          kbytes    used   avail %used Mounted on
/dev/vg00/lvol8     921600  555664  344185   62% /var

I only have this unique volume group vg00 in mirror on old SCSI 9GB (all space saving is important...) with all on it.
When I forget to look (thanks for reminding me Hehe...) the system crashes... and this box is not on site but in the countryside (with snow lately and Im on motorcycle...)
I just zero activity_log periodically, So Do it today:
Code:
civ:/var/stm/logs/sys $ ll
total 434840
-rw-r--r--   1 root       root       220578080 Feb 24 11:37 activity_log
-rw-rw-r--   1 root       sys            878 May  5  2010 config.stm
-rw-r--r--   1 root       root          4584 Feb  2 09:02 diaglogd_activity_log
-rw-r--r--   1 root       root          5480 Feb  2 09:02 memlogd_activity_log
-rw-r--r--   1 root       root          5872 Feb  2 09:02 scan_hw_log
civ:/var/stm/logs/sys $ >activity_log
civ:/var/stm/logs/sys $ r bdf
bdf /var
Filesystem          kbytes    used   avail %used Mounted on
/dev/vg00/lvol8     921600  338265  547997   38% /var

Look at how fast its growing though:
Code:
-rw-r--r--   1 root       root       220525916 Feb 24 11:29 activity_log
-rw-r--r--   1 root       root       220578080 Feb 24 11:37 activity_log

approx 12k/min

Last edited by vbe; 02-24-2012 at 06:45 AM.. Reason: Addendum ...
# 7  
Old 02-24-2012
Be vary careful when moving things in system partitions because you still need an intact system when you are up single-user.

Regarding /var/adm/sw . The directory /var/adm/sw/save is all the undo information for the patches applied on the system and can be huge. I believe that there is a formal process to "commit" the patches which also means that you cannot roll back those patches. I've never needed to do it.


Still concerned about your /var partition itself. Have you been able to reboot? If it is still like this after a reboot I wonder if there has been a faulty attempt to extend the filesystem.
Also you don't seem to have a /var/opt in your "du" list.

Btw. What did you delete?

Last edited by methyl; 02-24-2012 at 09:13 AM..
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

/var/audit full

Hi, I have Solaris-10 (having multiple non global zones running on it). Its /var is getting full to 100% and I can see, there are files getting added to /var/audit. There are large in number, so even if I clearing them, it is filling /var. In past 24 hours, there are 53000 files are added. I am... (1 Reply)
Discussion started by: solaris_1977
1 Replies

2. UNIX for Dummies Questions & Answers

How can partition out /var with these two separate 10 gigabyte disks?

In my company ,there is a mail server that services approximately 3,000 users. 2,000 users access their email via a POP-3 service, while the remaining 1,000 users access their email via a Unix mail reader. Recently users have complained about speed of disk access, so a new 10 gigabyte disk has... (1 Reply)
Discussion started by: lemon_06
1 Replies

3. Solaris

Install with /var in separate partition - Zfs / 10

This is my first time working with ZFS on Solaris 10. I am trying to set up /var in a separate partition from /. During the installation, I came across the ZFS settings where I selected disks 0 and 1 to be mirrored with ZFS. Next was the option to have /var and / on separate datasets. Is... (3 Replies)
Discussion started by: 6L71
3 Replies

4. AIX

/var/spool/squeue gets full frequently

hi, im new in aix administration.. months ago, I received mails, everytime a cron was executed. but now, I don't receive these mails.. and the /var/spool/squeue, gets full frequently. i'd like to know more information about this, what can i do?? sendmail is up, because, I executed ps -ef |grep... (5 Replies)
Discussion started by: fdeivis
5 Replies

5. AIX

/var filesystem is full

Hi, Is there a way to clear the temp files from /var/tmp? Is root access required to delete the files? Thanks, Narayan (2 Replies)
Discussion started by: narayanv
2 Replies

6. BSD

Moving /var partition to USB stick

I am currently running DesktopBSD as a live-CD and need to have a large /var partition because it is currently too small. I have a USB stick which is BSD formatted, and would like to have the /var partition moved over to it. How can this be done? Could I for instance use a symlink? (1 Reply)
Discussion started by: figaro
1 Replies

7. Filesystems, Disks and Memory

partition out /var

Hi If You were the systems administrator of a mail server that services approximately 3,000 users. 2,000 users access their email via a POP-3 service, while the remaining 1,000 users access their email via a Unix mail reader. Recently users have complained about speed of disk access, so a new 10... (1 Reply)
Discussion started by: semaphore
1 Replies

8. AIX

/var 100% full

What to do if /var filesystem in Aix is completely full ? (2 Replies)
Discussion started by: kkhan
2 Replies

9. UNIX for Dummies Questions & Answers

Full Partition?

Hi Everyone, I think I've filled up one of the partitions on my drive. I suspect that one of the applications I've been running has been spitting out junk files to this partition - most of which can be deleted. The problem is that I have no idea how to go look at what's on that partition and... (2 Replies)
Discussion started by: Choppy
2 Replies

10. HP-UX

i-node full on /var

Can anyone tell me how would I troubleshoot when /var becomes full with inodes? This is on HP11.11 system. Where used is 92%, ifree is 1891 iuse is 88%. Thanks. (3 Replies)
Discussion started by: catwomen
3 Replies
Login or Register to Ask a Question