Stop Temp Clear on Every Reboot

I tend to be a little ditzy, and will sometimes start editing a file in the temp folder, and loose it on reboot.

How do I change the temp folder so it doesn’t automatically clear on reboot? I use Linux Mint 17, openSUSE 13.1, and openSUSE 13.2.

What temp folder do you mean?

On openSUSE neither /tmp nor /var/tmp is cleared or lost on reboot.

I don’t know about Mint though, or how they clear it/how you could disable it there.

I meant /tmp and /var/tmp. I thought it was - I downloaded a word document in Firefox and was editing it in LibreOffice. I saved my changes oblivious to that I had Firefox save it in a temp folder (hit Open With rather than Save File), and had to a reboot to get my wireless card’s tantrum over. When I pulled it up in LibreOffice Recent Documents history and looked through Firefox’s download history, I saw the file was somehow deleted.

Unless you manually set it up, no.
If you want to verify, have a look at /usr/lib/tmpfiles.d/tmp.conf and /etc/tmpfiles.d/tmp.conf (this will override the first one when it exists).
You’ll find lines in there like this:

d /tmp 1777 root root -
d /var/tmp 1777 root root -

The ‘-’ at the end of the line means that it is not cleaned up. If there would be ‘1d’, this would mean files older than 1 day would be removed.

Another way to clean /tmp is to create it as tmpfs. But again, you’ll have to setup this manually. By default /tmp and /var/tmp are just normal folders on your root (system) partition.
To check this, run “mount”.

I downloaded a word document in Firefox and was editing it in LibreOffice. I saved my changes oblivious to that I had Firefox save it in a temp folder (hit Open With rather than Save File), and had to a reboot to get my wireless card’s tantrum over. When I pulled it up in LibreOffice Recent Documents history and looked through Firefox’s download history, I saw the file was somehow deleted.

You clicked on a link in Firefox and told Firefox to open it with LibreOffice?

Then probably Firefox deleted it when it was quit during logout/shutdown.

Is there a way to prevent Firefox from doing that?

FireFox normally saves files to the ~/Download folder You can set where you want in Prefernces - General tab

All your things should be in YOUR home directory. It is possible that one of the tmp folders is used for the download then the file moved to the location you have selected in FF. But I don’t think that is how it works any more

On 2014-11-12 01:56, gogalthorp wrote:
>
> FireFox normally saves files to the ~/Download folder You can set where
> you want in Prefernces - General tab

For “open with”, indeed it uses /tmp/something. Dunno why there.

LO should remember where it was - BUT, it may be FF itself which clears
the file on shutdown, not the system, because it remembers that it
downloaded a temporary file.

The download manager of FF might also remember the exact location and
name of the file.

LO also has a directory for automatic backups, the file might still have
a copy in there. The location is configured in LO itself.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

If you want to edit – and continue using – a file, it would be a better to choose to save it to disk instead of open it in LibreOffice from Firefox.

Then, browse to that folder and open it from there for editing.

I rarely use the “Open with …” option from inside Firefox, in case I decide I want to do something with whatever it is I am opening.

And, BTW: I go into options and change the Download to "Always Ask where to save … "

The download list is cleared along with the history when Firefox exits, if the user has Clear History on Exit set.:wink:

On 2014-11-12 07:06, Fraser Bell wrote:
>
> robin_listas;2675398 Wrote:
>>
>> The download manager of FF might also remember the exact location and
>> name of the file.
>
> The download list is cleared along with the history when Firefox exits,
> if the user has Clear History on Exit set.:wink:

Which I don’t. My computer, my house, my control. If they can read my
history files, they can read anything else.


Cheers / Saludos,

Carlos E. R.
(from 13.1 x86_64 “Bottle” at Telcontar)

But there doesn’t seem to be a way to stop Firefox from clearing its /tmp folder upon startup and shutdown?

… I am just going to wait a bit to see if anyone else answers this comment.:\