I have an application that stores some files in the /tmp/appdata
folder.
I store these files so that the application does not have to copy these files from the network every time it is run.
I want to store these files for 90
days. For this I have set the value of TMPTIME
to 90
in the file /etc/default/rcS
.
The problem is that ubuntu seems to be ignoring this value. Every time I restart the ubuntu server the files in /tmp
folder are cleaned and the appdata
folder is deleted.
Why is happening? and How to fix this?
The version of ubuntu is given below.
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.3 LTS
Release: 16.04
Codename: xenial
/tmp
is temporary folder. Everything you put into it will be erased at startup. You must choose another folder to store this content. I suggest you to use/opt
,/usr/share
, or any else./tmp
is temporary folder. Everything you put into it will be erased at startup.