Hi,
I want to increase the size of tmpfs mounted in /dev/shm . So I put in /etc/fstab the option size=66% for this mount entry (tmpfs /dev/shm tmpfs size=66% 0 0).
After reboot no changes at all.
If I manualy do a $mount -o remount tmpfs , then the size is adjusted to the size I wanted.
How to make this to be persistent after restart and why the value of size in /etc/fstab are not applied ?
Thanks.
Shared memory
-
- Retired Moderator
- Posts: 18276
- Joined: 2006/12/13 20:15:34
- Location: Tidewater, Virginia, North America
- Contact:
Shared memory
Welcome to the CentOS fora. Please see the recommended reading for new users linked in my signature.
I suspect the problem is due to your /etc/fstab entry which replaces the default entry "default" with only "size=66%". With the default entry I see[code]# grep tmpfs /etc/mtab
tmpfs /dev/shm tmpfs rw,rootcontext="system_u:object_r:tmpfs_t:s0" 0 0[/code]
So I'd try [code]tmpfs /dev/shm tmpfs rw,rootcontext="system_u:object_r:tmpfs_t:s0,size=66% 0 0[/code]
I suspect the problem is due to your /etc/fstab entry which replaces the default entry "default" with only "size=66%". With the default entry I see[code]# grep tmpfs /etc/mtab
tmpfs /dev/shm tmpfs rw,rootcontext="system_u:object_r:tmpfs_t:s0" 0 0[/code]
So I'd try [code]tmpfs /dev/shm tmpfs rw,rootcontext="system_u:object_r:tmpfs_t:s0,size=66% 0 0[/code]