<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Delete files from /tmp and /var/tmp in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706869#M59527</link>
    <description>Hi,&lt;BR /&gt;&lt;BR /&gt;See this similar thread:&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x86a4ba808b46d611abda0090277a778c,00.html" target="_blank"&gt;http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x86a4ba808b46d611abda0090277a778c,00.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;C.</description>
    <pubDate>Fri, 19 Apr 2002 09:13:57 GMT</pubDate>
    <dc:creator>Clemens van Everdingen</dc:creator>
    <dc:date>2002-04-19T09:13:57Z</dc:date>
    <item>
      <title>Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706868#M59526</link>
      <description>Hi !&lt;BR /&gt;&lt;BR /&gt;How to safely delete files from /tmp and /var/tmp ?&lt;BR /&gt;On my system are running Informix, Tuxedo, MQSeries.&lt;BR /&gt;&lt;BR /&gt;Thx&lt;BR /&gt;KRI&lt;BR /&gt;</description>
      <pubDate>Fri, 19 Apr 2002 09:05:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706868#M59526</guid>
      <dc:creator>KRI</dc:creator>
      <dc:date>2002-04-19T09:05:04Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706869#M59527</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;See this similar thread:&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x86a4ba808b46d611abda0090277a778c,00.html" target="_blank"&gt;http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x86a4ba808b46d611abda0090277a778c,00.html&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;C.</description>
      <pubDate>Fri, 19 Apr 2002 09:13:57 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706869#M59527</guid>
      <dc:creator>Clemens van Everdingen</dc:creator>
      <dc:date>2002-04-19T09:13:57Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706870#M59528</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Normal practise is to run a regular cron job (probably daily) that removes files older than a certain number of days.&lt;BR /&gt;&lt;BR /&gt;For example, the following command will delete all files in /tmp that are more than 7 days old:-&lt;BR /&gt;&lt;BR /&gt;find /tmp -type f -mtime +6 -exec rm -f {} \;&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;John</description>
      <pubDate>Fri, 19 Apr 2002 09:14:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706870#M59528</guid>
      <dc:creator>John Palmer</dc:creator>
      <dc:date>2002-04-19T09:14:12Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706871#M59529</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;check for files still in use (don't delete them ofcourse) and the last acces time.&lt;BR /&gt;If files haven't been accessed for say 7 days, I would think it's safe to delete them.&lt;BR /&gt;It depends on what kind of files they are and on how much space you have avainlable.&lt;BR /&gt;if more space is available, delete them later.&lt;BR /&gt;&lt;BR /&gt;Grt, E.</description>
      <pubDate>Fri, 19 Apr 2002 09:14:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706871#M59529</guid>
      <dc:creator>Emiel van Grinsven</dc:creator>
      <dc:date>2002-04-19T09:14:16Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706872#M59530</link>
      <description>Theoretically all the files in /tmp and /var/tmp are supposed to be temporary files and so if they're not currently in use, can/should be deleted.  You can find out if a file is in use by using the fuser command.&lt;BR /&gt;&lt;BR /&gt;Typically we run a script through cron which scan /tmp and /var/tmp for files older than 7 days.  If these files are not in use, then delete them.  There have been no complaints yets.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Hope this helps.&lt;BR /&gt;&lt;BR /&gt;-Santosh</description>
      <pubDate>Fri, 19 Apr 2002 09:15:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706872#M59530</guid>
      <dc:creator>Santosh Nair_1</dc:creator>
      <dc:date>2002-04-19T09:15:18Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706873#M59531</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I would suggest that you remove files in /var/tmp or /tmp in an /sbin/rc1.d startup script. &lt;BR /&gt;&lt;BR /&gt;Early during your system initialisation and startup, your applications are not launched yet, thus it would be safe to remove files in these directories. Thus I would suggest that you link your script in /sbin/rc1.d.&lt;BR /&gt;&lt;BR /&gt;If you are to remove files in these directories while in run-level 3 or beyond, you may risk removing files that are still being opened by existing processes.&lt;BR /&gt;&lt;BR /&gt;If you do not wish to wait for the next system startup, you can perform an fuser on the device mounted on by /tmp or /var/tmp to identify opened processes still using files in these directories. You can also use the lsof tool to provide finer granularity in identifying the processes currently using these directories. Subsequently, gracefully terminate these processes (only if not required) before removing the files.&lt;BR /&gt;&lt;BR /&gt;Hope this helps. Regards.&lt;BR /&gt;&lt;BR /&gt;Steven Sim Kok Leong</description>
      <pubDate>Fri, 19 Apr 2002 09:19:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706873#M59531</guid>
      <dc:creator>Steven Sim Kok Leong</dc:creator>
      <dc:date>2002-04-19T09:19:07Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706874#M59532</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;i just wonder... how often do you reboot the machine? I would go for a thorough analysis on what files come in these dirs and then create a cron job. Do as you think is best :-)&lt;BR /&gt;&lt;BR /&gt;Grt, Emiel</description>
      <pubDate>Fri, 19 Apr 2002 11:09:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706874#M59532</guid>
      <dc:creator>Emiel van Grinsven</dc:creator>
      <dc:date>2002-04-19T11:09:04Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706875#M59533</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;Regardless of whether you are removing files in /tmp during a system reboot (how conscientious are you in installing kernel patches?), automated cron job or manual deletion, the main point is to check that residing file(s) are not in use during the deletion of such file(s).&lt;BR /&gt;&lt;BR /&gt;In my environment, /tmp and /var/tmp don't usually fill up that fast. As such, a periodic deletion (eg. 7 days)is an overkill for me. Apart from deletion during system reboot, a cron script monitors when either of /tmp or /var/tmp is &amp;gt;80% full. When that occurs, I get paged and files in /tmp are selectively and manually removed.&lt;BR /&gt;&lt;BR /&gt;Hope this helps. Regards.&lt;BR /&gt;&lt;BR /&gt;Steven Sim Kok Leong</description>
      <pubDate>Fri, 19 Apr 2002 13:33:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706875#M59533</guid>
      <dc:creator>Steven Sim Kok Leong</dc:creator>
      <dc:date>2002-04-19T13:33:47Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files from /tmp and /var/tmp</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706876#M59534</link>
      <description>Steven,&lt;BR /&gt;&lt;BR /&gt;I'm not sure that I'd agree with the need to check that temp files are in use.&lt;BR /&gt;&lt;BR /&gt;The very fact that the 'modified date' is over a certain number of days old usually means that the file is not in use and even if a process still has the file open, deleting it doesn't affect that process. The file remains (unlinked and invisible) until it gets closed.&lt;BR /&gt;&lt;BR /&gt;As others have stated, a startup script is fine but we now have very few servers that are regularly rebooted. &lt;BR /&gt;&lt;BR /&gt;I prefer a cron'd daily housekeeping script which can be tailored to tidy other directories as well.&lt;BR /&gt;&lt;BR /&gt;Regards,&lt;BR /&gt;John</description>
      <pubDate>Fri, 19 Apr 2002 13:50:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/delete-files-from-tmp-and-var-tmp/m-p/2706876#M59534</guid>
      <dc:creator>John Palmer</dc:creator>
      <dc:date>2002-04-19T13:50:07Z</dc:date>
    </item>
  </channel>
</rss>

