How to change the default size of tmpfs?

AJ ONeal coolaj86 at
Tue Dec 21 09:53:35 MST 2010

How do I make the system-wide default size of tmpfs smaller (or bigger for
that matter)?

I found that for one-time use I can change the size of tmpfs in this

# make tmpfs in /dev/shm 40Mb
mount -o remount,size=40M /dev/shm

Obviously, I can also change fstab

tmpfs                /var/volatile        tmpfs      size=40M
0  0
tmpfs                /dev/shm             tmpfs
size=40M,mode=0777             0  0
tmpfs                /media/ram           tmpfs      size=40M
0  0

And, of course, most obviously I can change the source code of the kernel
myself with my bare hands while walking up-hill both ways in the snow on my
netbook with full-20%-size-keyboard and a 1400 baud modem on a 8088
processor in the editor I wrote myself in assembly and punch-cards.

I don't recall seeing the option in make menuconfig

Maybe something in /etc/sysctl.conf?

AJ ONeal

More information about the PLUG mailing list