Operating System - HP-UX
1820475 Members
2847 Online
109624 Solutions
New Discussion юеВ

files in /var/tmp - ok to remove ??

 
SOLVED
Go to solution
Simon R Wootton
Regular Advisor

files in /var/tmp - ok to remove ??

I have some large files in /var/tmp which is pushing the size of /var filesystem up to 90%. The files in question start 'Ex' and are followed by a 4/5 digit number. Questions : What are these files and can I delete them without causing system problems ? All help rewarded!
6 REPLIES 6
H.Merijn Brand (procura
Honored Contributor

Re: files in /var/tmp - ok to remove ??

These are work files for vi and ex. Removing them for open vi/ex sessions works desaterous. If they're older than a week, it's most likely safe to remove them.

Please check with the owner of the files if there are open vi/ex sessions that use it.

# fuser -u Ex*

might give info on open sessions too.

Enjoy, have FUN! H.Merijn
Enjoy, Have FUN! H.Merijn
Pete Randall
Outstanding Contributor

Re: files in /var/tmp - ok to remove ??

Those are editor save files and should be removable. To be on the safe side, you could remove just the ones that are older than a couple of days using find:

find /var/tmp -name ex* -mtime +2 -exec rm {} \;


Pete

Pete
Stanimir
Trusted Contributor

Re: files in /var/tmp - ok to remove ??

Hi!
These are a different tmp-files,created by
many users. Some of them could be in use,but
removing them will not cause big troubles. :)
Anyway you should look at date: when any file
is created. Also try:
#strings ./ExNNNN to look in every file you
like to remove.
Regards,Stan
Ravi_8
Honored Contributor

Re: files in /var/tmp - ok to remove ??

Hi,

you can remove the files under/var/tmp, but not the directory tmp under /var.
Removing tmp directory under /var causes problem while swinstall/swremove etc..
never give up
Paul Sperry
Honored Contributor
Solution

Re: files in /var/tmp - ok to remove ??

You can safely remove any file older tha a few days.

Also you might want to look in
/var/adm/crash you can also delete any thing in there. This is where crash files are kept.

Also you can cat /dev/null > /var/adm/wtmp
the wtmp file contains login information and
can get quite large.

Another place you can delete files is
/var/preserve

And lastly you can use cleanup
(man cleanup)

These steps should get your /var directory
under 90%

Frank Slootweg
Honored Contributor

Re: files in /var/tmp - ok to remove ??

An even safer method:

Login as, or "su -" to, the user who owns the files. Then, as that user, run "ex -r". If that lists any files, then contact the user as to what to do with them. If it says "No files saved." then it is probably safe to remove the files.