Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

On Ubuntu Precise, I'm low on space in /run:

admin@foo:~$ df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/sda1        19G  6.6G   12G  38% /
udev             10M  8.0K   10M   1% /dev
none             50M   40M   11M  79% /run
none            5.0M     0  5.0M   0% /run/lock
none            249M     0  249M   0% /run/shm

Should I allocate more? How?

EDIT: Here's my fstab:

admin@foo:~$ cat /etc/fstab
proc            /proc       proc    defaults    0 0
/dev/sda1       /           ext3    defaults,errors=remount-ro,noatime    0 1
/dev/sda2       none        swap    sw          0 0
share|improve this question
Related answer on AU, that presents a workaround using mount in /etc/rc.local. – lgarzo Jan 26 '13 at 20:43
@lgarzo: While it seems strange to configure the size in that script, the question and answer you posted to discuss the relatively small size for /run and one guy's way to increase it. Yours is the best answer yet; please make it an answer so I can accept it. – Brian Jan 26 '13 at 21:08
up vote 7 down vote accepted

In a post on Ask Ubuntu, korrident suggested a possible workaround:

Adding a mount command to the /etc/rc.local file:

mount -t tmpfs tmpfs /run -o remount,size=85M

Make sure that the script will "exit 0" on success or any other value on error. (Excerpt from the file.)

share|improve this answer

I do not think that increasing the size of /run is necessary, but in case you do need to increase it try editing your /etc/fstab file. All mountpoints and most partitions are listed there. If your /run partition is a tmpfs(which it should be, at least according to, I would confirm before following these instructions) then you can simply change the fstab line of your /run mount to something akin to the following:

none /dev/shm tmpfs defaults,size=8G 0 0

See how the size is declared right after defaults? Try doing that. You can use megabytes as well by using M:

none /dev/shm tmpfs defaults,size=100M 0 0

Reboot the computer after this and the changes should take place.

Edit: Scratch that, looks like Ubuntu creates the run partition using files in /etc/init and /etc/init.d and not via fstab. You'd have to look through those files and find the mount command that it uses to create run and edit it manually. I don't have a box to test this on right now, but try running this:

find /etc/init* -type f | xargs grep "mount"


find /etc/init* -type f | xargs grep "run"

If it's being mounted via a bash script then this should find the file and line that does the mounting.

share|improve this answer
It's not necessary to reboot; you could just do mount -o remount /run. – Michael Hampton Jan 26 '13 at 18:53
Wouldn't that most likely fail though? Considering /run is still in use by processes on the system? – Marcos Velazquez Jan 26 '13 at 19:10
Possibly, but not very likely. Try it out and see what happens. – Michael Hampton Jan 26 '13 at 19:14
I ran into the limit on /run earlier and resized my server before posting this question, so I'm interested to hear what else you might think I could do besides increasing the size of /run. See also the fstab I posted above. – Brian Jan 26 '13 at 19:31
This doesn't appear to work - just tried it and it didn't change the size of /run. – Iain Jan 26 '13 at 19:32

Temporary increase tmpfs filesystem

1) Open /etc/fstab with vi or any text editor of your choice,

2) Locate the line of /dev/shm and use the tmpfs size option to specify your expected size,

e.g. 512MB:
tmpfs      /dev/shm      tmpfs   defaults,size=512m   0   0

e.g. 2GB:
tmpfs      /dev/shm      tmpfs   defaults,size=2g   0   0

after then

mount -o remount /dev/shm
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.