I have read that you should not store /tmp on a SSD, because the frequent writes will shorten the lifetime of the SSD. But what about /var/tmp?

Is it reasonable for /var/tmp to be stored on a SSD? Or should we avoid having /var/tmp stored on a SSD, to avoid killing the SSD prematurely?

  • possibly related: unix.stackexchange.com/questions/80864/… Commented Aug 11, 2013 at 19:18
  • Contrary to the header at the top, the question "What NOT to put on an SSD" does not answer my question: it says nothing about /var/tmp specifically. I did read that question before posting here, and it didn't answer my question; my question is about /var/tmp. I'm not sure why my question was marked with that header.
    – D.W.
    Commented Aug 12, 2013 at 4:16

2 Answers 2


While it is true that all flash based storage devices have a limited number of writes before the transistor insulation breaks down, it's not as bad as it was when SSDs were first introduced years ago.

Basically due to the fact that most modern SSD's employ wear leveling and are based on NandFlash, burning through a drive is not a problem like it used to be.

You shouldn't need to worry about it. A SSD with constant writes will still outlast any rotary hard drive.





  • The read cycles are unlimited on all systems.
    – ott--
    Commented Aug 11, 2013 at 19:14

There is little essential difference between /tmp and /var/tmp in this regard.

Step back a bit, though. It is by no means a settled question that you should avoid putting /tmp on an SSD. The earliest SSDs were subject to being worn out by excessive writes, but high quality modern SSDs have solved a lot of this. Partly they do this through wear leveling, and partly through reserving a large enough pool of spare blocks that they can survive a normal amount of block wear.

The cheaper the SSD, the fewer spare blocks it will have. Therefore, there may be some justification for conservative system setup strategies if you're going to use the cheapest sorts of consumer SSDs.

The line of reasoning that advises against putting any temporary filesystem on an SSD seems to be an extension of avoiding swap/virtual memory on SSDs, which at least makes somewhat more sense, because these files/partitions are fixed in place on disk. Wear leveling prevents this, too, from being as big a problem as in early SSDs.

My point here, though, is that this logic breaks down with /tmp, since the files created on it will naturally be scattered among the sectors allocated to that filesystem. The problem decreases still more when you put /tmp type directories within other filesystems, as with /usr/tmp and /var/tmp.

Bottom line, no, don't worry about it.

Observe that people have been running database servers off of SSDs in recent years. There's a fixed-data-location high-write-count setup if you ever saw one.

Not the answer you're looking for? Browse other questions tagged .