With systemd 219 and higher, systemd-udevd.service now has MountFlags=slave. This means that udevd runs in its own mount namespace. Whatever udev rules mount, it will only be visible inside that namespace. See [1]. The result is that after upgrading to Yocto, the mount directory is correctly created inside /run/media/sda1 but processes in the global mount namespace will see that directory as empty. Workaround hack: patch systemd-udevd.service to have MountFlags=shared, which reverts to the previous behavior. I am not sure this is desirable. I don't really understand the motivation behind this systemd change and what is the proper way of doing automounts from the systemd perspective. [1] https://github.com/systemd/systemd/commit/c2c13f2df42e0691aecabe3979ea81cd7faa35c7
After doing some research, I believe the best option is to manually specify MountFlags=slave which was the default before, also other distros are doing it too.
This patch is a backport from debian, and fizes the issue on master, I will backport it and request for it to be merged. http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=f2092e67ea880301058396b831a9a18905317d0d
Just clarifying that we DONT specify MountFlags=slave, that was a typo
Fixed here: http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?h=fido&id=c53ddb2006f04051b00df3189fe8d35bb49ef3c7