[prev in list] [next in list] [prev in thread] [next in thread]
List: gentoo-user
Subject: Re: [gentoo-user] Setting size of /dev/shm or cleaning up ancient /etc/fstab
From: Paul Hartman <paul.hartman+gentoo () gmail ! com>
Date: 2013-05-08 14:43:16
Message-ID: CAEH5T2MazERFj=PSrxMAb7y_hsPr5TXm+fAJaYKdh6PdWrmWgQ () mail ! gmail ! com
[Download RAW message or body]
On Wed, May 8, 2013 at 12:55 AM, Walter Dnes <waltdnes@waltdnes.org> wrote:
> I'm running mdev, so that may be related. Here's my story... a script
> I run to automatically process digital photos started blowing up on me.
> After much bashing of head against brick wall, I determined that
> /dev/shm now has an absolute max size of 10 megabytes! Any larger files
> could not be written to it. Here's all the uncommented stuff in /etc/fstab
>
>
> /dev/sda5 / ext2 noatime,nodiratime,async 0 1
> /dev/sda7 /home reiserfs noatime,nodiratime,async,notail 0 1
> /home/bindmounts/opt /opt auto bind 0 0
> /home/bindmounts/var /var auto bind 0 0
> /home/bindmounts/usr /usr auto bind 0 0
> /home/bindmounts/tmp /tmp auto bind 0 0
> /dev/sda6 none swap sw 0 0
> /dev/cdrom /mnt/cdrom iso9660 noauto,users,ro 0 0
> /dev/sr0 /mnt/dvd auto noauto,users,ro 0 0
> devpts /dev/pts devpts defaults 0 0
> none /dev/shm tmpfs rw,noatime,noexec,nosuid,nodev 0 0
>
> Meanwhile, my netbook, with the /dev/shm line commented out, runs just
> fine and handles large files in /dev/shm. I followed the example at
> http://wiki.gentoo.org/wiki/Complete_Handbook/Configuring_the_system
> with slightly more paranoid settings, e.g. noexec. What gives?
You can forcefully specify the size of /dev/shm like this:
none /dev/shm tmpfs defaults,size=10G 0 0
But it should default to 50% of your system RAM... weird... do you
have any local scripts that are remounting it, maybe?
There's a lot more information in the kernel documentation:
/usr/src/linux//Documentation/filesystems/tmpfs.txt
The default fstab from latest baselayout does not contain /dev/shm at all:
# /etc/fstab: static file system information.
#
# noatime turns off atimes for increased performance (atimes normally aren't
# needed); notail increases performance of ReiserFS (at the expense of storage
# efficiency). It's safe to drop the noatime options if you want and to
# switch between notail / tail freely.
#
# The root filesystem should have a pass number of either 0 or 1.
# All other filesystems should have a pass number of 0 or greater than 1.
#
# See the manpage fstab(5) for more information.
#
# <fs> <mountpoint> <type> <opts>
<dump/pass>
# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
/dev/BOOT /boot ext2 noauto,noatime 1 2
/dev/ROOT / ext3 noatime 0 1
/dev/SWAP none swap sw 0 0
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
/dev/fd0 /mnt/floppy auto noauto 0 0
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic