On Tue, 27.03.12 15:36, Tollef Fog Heen (tfh...@err.no) wrote:

> Hi,
> why is /media a tmpfs?  I think that violates user expectations that
> /media will be persistent across reboots, in particular any directories
> created and such.

/media is where deaemons such as udisks dynamically mount file systems
from usb sticks and cds and suchlike. Mount points in it are dynamic,
are not listed in /etc/fstab, and hence make sense to be cleaned up at

This is in contrast to /mnt which is admin territory, where mount points
often are listed in /etc/fstab, and hence should not be cleaned up in
order not to muck with the admin's configuration

Directories in /media are usually named after the disk label of the
media that is mounted. That means that not having automatic clean-up at
boot means you'd collect tons and tons of directories in there that are
never cleaned up if the machine is turned off at the wrong time. Also,
for moutning an USB stick we should not require write disk access to the
root disk, and we should keep our delta to read-only/stateless systems
as minimal as possible.

Anyway, udisks2 recently obseleted the use of /media, replacing it by
per-user directories in /run. Due to that I am about to remove /media
from the default units of systemd. It's probably a good idea for distros
to remove the mount point entirely.

Hope that makes some sense,


Lennart Poettering - Red Hat, Inc.
systemd-devel mailing list

Reply via email to