Re: [systemd-devel] mount ubifs using /dev/ubi0_X path
2017-02-02 14:27 GMT+01:00 Zbigniew Jędrzejewski-Szmek: > On Thu, Feb 02, 2017 at 02:11:28PM +0100, Lennart Poettering wrote: < snip > >> > Would you consider adding that line in upstream? IMO it fits along >> > side SUBSYSTEM=="block", TAG+="systemd" that is all ready in the file. >> > But I might me "embedded" damaged for requesting this... >> >> If ubifs is merged in the upstream kernel, then we can certainly add >> the relevant bits to systemd too. Please post a PR for that on github >> and we'll merge it. > > There's some confusion here. Ubifs vs. UBI the block device. > UBI is certainly in the kernel [1], please submit a PR to add the TAG. Yeah, that was probably my fault. Should not have mentioned UBIFS at all since this is really UBI related. Will create PR. Best Regards Mirza ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] mount ubifs using /dev/ubi0_X path
On Thu, Feb 02, 2017 at 02:11:28PM +0100, Lennart Poettering wrote: > On Mon, 23.01.17 23:02, Mirza Krak (mirza.k...@gmail.com) wrote: > > > 2017-01-23 22:36 GMT+01:00 Mirza Krak: > > > 2017-01-23 18:09 GMT+01:00 Lennart Poettering : > > >> On Mon, 23.01.17 17:56, Mirza Krak (mirza.k...@gmail.com) wrote: > > >> > > >>> Simply running "mount -a" once the system has started up gives me no > > >>> issues and /data is mounted according to my specification in > > >>> /etc/fstab. > > >>> > > >>> Also changing my fstab entry from "/dev/ubi0_2" to "ubi0_2" or > > >>> "ubi0:data" produces no errors and it is mounted as expected. But I > > >>> really want to use the "/dev" and I do not see a reason why it should > > >>> not work? > > >> > > >> systemd only picks up devices that carry the "systemd" label in udev, > > >> and do not have SYSTEMD_READY=0 set. Usually the label is added by > > >> some udev rule, most likely that's missing for your devices. > > >> > > >> See systemd.device(5) for details. > > > > > > Thank you Lennart for your fast response. > > > > > > Adding > > > > > > SUBSYSTEM=="ubi", TAG+="systemd" > > > > > > did indeed solve it. > > > > I just noticed that the file I ended up editing was 99-systemd.rules, > > which is part of systemd. This was the file that made most sense when > > I was looking trough all the .rules files I had on my system. > > > > UBI is a common file system that is used on raw FLASH systems, in the > > embedded world. > > > > Would you consider adding that line in upstream? IMO it fits along > > side SUBSYSTEM=="block", TAG+="systemd" that is all ready in the file. > > But I might me "embedded" damaged for requesting this... > > If ubifs is merged in the upstream kernel, then we can certainly add > the relevant bits to systemd too. Please post a PR for that on github > and we'll merge it. There's some confusion here. Ubifs vs. UBI the block device. UBI is certainly in the kernel [1], please submit a PR to add the TAG. Zbyszek [1] https://github.com/torvalds/linux/blob/master/drivers/mtd/ubi/Kconfig ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] mount ubifs using /dev/ubi0_X path
On Mon, 23.01.17 23:02, Mirza Krak (mirza.k...@gmail.com) wrote: > 2017-01-23 22:36 GMT+01:00 Mirza Krak: > > 2017-01-23 18:09 GMT+01:00 Lennart Poettering : > >> On Mon, 23.01.17 17:56, Mirza Krak (mirza.k...@gmail.com) wrote: > >> > >>> Simply running "mount -a" once the system has started up gives me no > >>> issues and /data is mounted according to my specification in > >>> /etc/fstab. > >>> > >>> Also changing my fstab entry from "/dev/ubi0_2" to "ubi0_2" or > >>> "ubi0:data" produces no errors and it is mounted as expected. But I > >>> really want to use the "/dev" and I do not see a reason why it should > >>> not work? > >> > >> systemd only picks up devices that carry the "systemd" label in udev, > >> and do not have SYSTEMD_READY=0 set. Usually the label is added by > >> some udev rule, most likely that's missing for your devices. > >> > >> See systemd.device(5) for details. > > > > Thank you Lennart for your fast response. > > > > Adding > > > > SUBSYSTEM=="ubi", TAG+="systemd" > > > > did indeed solve it. > > I just noticed that the file I ended up editing was 99-systemd.rules, > which is part of systemd. This was the file that made most sense when > I was looking trough all the .rules files I had on my system. > > UBI is a common file system that is used on raw FLASH systems, in the > embedded world. > > Would you consider adding that line in upstream? IMO it fits along > side SUBSYSTEM=="block", TAG+="systemd" that is all ready in the file. > But I might me "embedded" damaged for requesting this... If ubifs is merged in the upstream kernel, then we can certainly add the relevant bits to systemd too. Please post a PR for that on github and we'll merge it. Lennart -- Lennart Poettering, Red Hat ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] mount ubifs using /dev/ubi0_X path
2017-01-23 22:36 GMT+01:00 Mirza Krak: > 2017-01-23 18:09 GMT+01:00 Lennart Poettering : >> On Mon, 23.01.17 17:56, Mirza Krak (mirza.k...@gmail.com) wrote: >> >>> Simply running "mount -a" once the system has started up gives me no >>> issues and /data is mounted according to my specification in >>> /etc/fstab. >>> >>> Also changing my fstab entry from "/dev/ubi0_2" to "ubi0_2" or >>> "ubi0:data" produces no errors and it is mounted as expected. But I >>> really want to use the "/dev" and I do not see a reason why it should >>> not work? >> >> systemd only picks up devices that carry the "systemd" label in udev, >> and do not have SYSTEMD_READY=0 set. Usually the label is added by >> some udev rule, most likely that's missing for your devices. >> >> See systemd.device(5) for details. > > Thank you Lennart for your fast response. > > Adding > > SUBSYSTEM=="ubi", TAG+="systemd" > > did indeed solve it. I just noticed that the file I ended up editing was 99-systemd.rules, which is part of systemd. This was the file that made most sense when I was looking trough all the .rules files I had on my system. UBI is a common file system that is used on raw FLASH systems, in the embedded world. Would you consider adding that line in upstream? IMO it fits along side SUBSYSTEM=="block", TAG+="systemd" that is all ready in the file. But I might me "embedded" damaged for requesting this... Best Regards Mirza ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] mount ubifs using /dev/ubi0_X path
2017-01-23 18:09 GMT+01:00 Lennart Poettering: > On Mon, 23.01.17 17:56, Mirza Krak (mirza.k...@gmail.com) wrote: > >> Simply running "mount -a" once the system has started up gives me no >> issues and /data is mounted according to my specification in >> /etc/fstab. >> >> Also changing my fstab entry from "/dev/ubi0_2" to "ubi0_2" or >> "ubi0:data" produces no errors and it is mounted as expected. But I >> really want to use the "/dev" and I do not see a reason why it should >> not work? > > systemd only picks up devices that carry the "systemd" label in udev, > and do not have SYSTEMD_READY=0 set. Usually the label is added by > some udev rule, most likely that's missing for your devices. > > See systemd.device(5) for details. Thank you Lennart for your fast response. Adding SUBSYSTEM=="ubi", TAG+="systemd" did indeed solve it. Best Regards Mirza ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
Re: [systemd-devel] mount ubifs using /dev/ubi0_X path
On Mon, 23.01.17 17:56, Mirza Krak (mirza.k...@gmail.com) wrote: > Simply running "mount -a" once the system has started up gives me no > issues and /data is mounted according to my specification in > /etc/fstab. > > Also changing my fstab entry from "/dev/ubi0_2" to "ubi0_2" or > "ubi0:data" produces no errors and it is mounted as expected. But I > really want to use the "/dev" and I do not see a reason why it should > not work? systemd only picks up devices that carry the "systemd" label in udev, and do not have SYSTEMD_READY=0 set. Usually the label is added by some udev rule, most likely that's missing for your devices. See systemd.device(5) for details. Lennart -- Lennart Poettering, Red Hat ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel
[systemd-devel] mount ubifs using /dev/ubi0_X path
Hi all. I am experiencing some difficulties with mounting an UBI volume using /dev/ubi0_X path. I will start from the beginning. In my /etc/fstab I have an entry that says: /dev/ubi0_2 /dataubifs defaults,auto 0 0 So on boot I expect systemd to create an .mount unit for me and mount according above. It creates an .mount unit ~ # cat /run/systemd/generator/data.mount # Automatically generated by systemd-fstab-generator [Unit] SourcePath=/etc/fstab Documentation=man:fstab(5) man:systemd-fstab-generator(8) Before=local-fs.target [Mount] What=/dev/ubi0_2 Where=/data Type=ubifs Options=defaults,auto And it attempts to mount during boot, but fails: Jan 22 15:54:49 colibri-vf systemd[1]: dev-ubi0_2.device: Job dev-ubi0_2.device/start timed out. Jan 22 15:54:49 colibri-vf systemd[1]: Timed out waiting for device dev-ubi0_2.device. -- Subject: Unit dev-ubi0_2.device has failed -- Defined-By: systemd -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel -- -- Unit dev-ubi0_2.device has failed. -- -- The result is timeout. Jan 22 15:54:49 colibri-vf systemd[1]: Dependency failed for /data. -- Subject: Unit data.mount has failed -- Defined-By: systemd -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel -- -- Unit data.mount has failed. -- -- The result is dependency. Jan 22 15:54:49 colibri-vf systemd[1]: data.mount: Job data.mount/start failed with result 'dependency'. Jan 22 15:54:49 colibri-vf systemd[1]: dev-ubi0_2.device: Job dev-ubi0_2.device/start failed with result 'timeout' It seems that it can not not find /dev/ubi0_2", but it is there. My / is on the same UBI part, which is attached during kernel boot so I expect that all devices are there and it does succeed in mount the root file system (/) ~ # ls /dev/ubi0* /dev/ubi0/dev/ubi0_0 /dev/ubi0_1 /dev/ubi0_2 Simply running "mount -a" once the system has started up gives me no issues and /data is mounted according to my specification in /etc/fstab. Also changing my fstab entry from "/dev/ubi0_2" to "ubi0_2" or "ubi0:data" produces no errors and it is mounted as expected. But I really want to use the "/dev" and I do not see a reason why it should not work? systemd version: systemd 230 running in system mode. (-PAM -AUDIT -SELINUX -IMA -APPARMOR -SMACK +SYSVINIT -UTMP -LIBCRYPTSETUP -GCRYPT ) Any thoughts? Best Regards Mirza ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel