[yocto] Mounting USB drives on a "read-only-rootfs" based system
Jeffrey D Boyer
Jeffrey.D.Boyer at jci.com
Wed Jun 15 06:14:08 PDT 2016
My distro is running udev. I discovered the automounter script in /etc/udev/rules.d was causing the mount point to be /media. For all I know, this is default behavior for udev.
Anyway, I think I found a solution. As suggested by another person on the thread, I went ahead and mounted a tmpfs on the /media directory. This allowed the udev automount script to function as it did when the squashfs option was disabled.
Thanks to everyone for all the help.
-----Original Message-----
From: Mike Looijmans [mailto:mike.looijmans at topic.nl]
Sent: Wednesday, June 15, 2016 4:07 AM
To: Jeffrey D Boyer <Jeffrey.D.Boyer at jci.com>; Christopher Larson <clarson at kergoth.com>
Cc: yocto at yoctoproject.org
Subject: Re: [yocto] Mounting USB drives on a "read-only-rootfs" based system
On 14-06-16 15:48, Jeffrey D Boyer wrote:
> Sorry, /media is not a symlink and there is no /run/media link or directory present on my running system. When I insert an SD card, for example, I get a bit of text on the debug serial port that a card has been detected, but I don't see a mount point anywhere after that.
>
> root at mySys:/# mmc1: new high speed SDHC card at address 1234
> mmcblk1: mmc1:1234 SA04G 3.63 GiB
> mmcblk1: p1
>
> It should be noted that if I exclude the " read-only-rootfs" option in
> the bb script, a normal read/write kernel image is produced and the
> action of inserting an SD card under those conditions will
> automatically produce a mount point at /media/mmcblk1p1
Apparently your distro or image or whatever is lacking some directories. The /run/media should have been created automagically.
Are you using udev or mdev for hotplug?
For mdev, I implemented the automounting using /run/media and that should also work on read-only-rootfs systems. So I can probably figure out what's wrong with your config.
For udev, I don't have a clue, sorry...
> FYI, I'm running 3.14 kernel. Is this a job for aufs? If so, how would I go about configuring it?
No, it's not related to autofs or aufs or whatever. It's plain simple udev or mdev.
Kind regards,
Mike Looijmans
System Expert
TOPIC Embedded Products
Eindhovenseweg 32-C, NL-5683 KH Best
Postbus 440, NL-5680 AK Best
Telefoon: +31 (0) 499 33 69 79
E-mail: mike.looijmans at topicproducts.com
Website: www.topicproducts.com
Please consider the environment before printing this e-mail
More information about the yocto
mailing list