[systemd-devel] systemd blocks update kernel partition table
Lennart Poettering
lennart at poettering.net
Thu Nov 22 09:48:12 UTC 2018
On Mi, 21.11.18 23:26, e-stl at gmx.de (e-stl at gmx.de) wrote:
> Hi list,
> i'm new to systemd and are working with an embedded device with yocto.
>
> In my embedded device i want to format and store my emmc device with the
> new firmware. When updating the firmware the device boots from SD card.
>
> When updating the firmware i want to (re)partition my emmc storage device
> with parted and 3 ext4 partitions. None of the partitions is mounted,
> because the device boots from SD card.
> When the emmc already contains a partition table parted complains that it
> can't update the kernel partition table after it was modified.
> It seems these partitions are already mounted anywhere. partprobe doesn't
> help either.
>
> But i don't mount them and when i check for mounted partitions by mount
> command, none of them is mounted. The only thing i see is that systemd has
> created device units for these partitions. In syslog i see that the ext4
> partition is recognized (also in /sys/fs/ext4 available). I assume that
> the systemd device units block the update of the kernel partition
> table.
.device units are just a representation of devices reported by
udev/kernel in the systemd "unit" concept. PID 1 never actually opens
them, it just tracks them. And it hence is not keeping them busy.
> I need to modify, format and fill the partitions on the emmc without
> booting after the new partition table is written.
>
> My question is: What/is systemd blocking the update of the kernel
> partition table and what can i do to prevent it?
I doubt it is. It must be something else.
Use fuser or a similar tool to figure out what is keeping it busy.
Lennart
--
Lennart Poettering, Red Hat
More information about the systemd-devel
mailing list