[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
** Changed in: systemd (Debian) Status: Confirmed => Fix Released -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
This bug was fixed in the package systemd - 218-7ubuntu1 --- systemd (218-7ubuntu1) vivid; urgency=medium * Merge with Debian unstable. Remaining Ubuntu changes: - Hack to support system-image read-only /etc, and modify files in /etc/writable/ instead. - Keep our much simpler udev maintainer scripts (all platforms must support udev, no debconf). - initramfs init-top: Drop $ROOTDELAY, we do that in a more sensible way with wait-for-root. Will get applicable to Debian once Debian gets wait-for-root in initramfs-tools. - initramfs init-bottom: If LVM is installed, settle udev, otherwise we get missing LV symlinks. Workaround for LP #1185394. - Add debian/udev.lvm2.init: Dummy SysV init script to satisfy insserv dependencies to "lvm2" which is handled with udev rules in Ubuntu. - Provide shutdown fallback for upstart. (LP: #1370329) - debian/extra/ifup@.service: Additionally run for "auto" class. We don't really support "allow-hotplug" in Ubuntu at the moment, so we need to deal with "auto" devices appearing after "/etc/init.d/networking start" already ran. (LP: #1374521) - ifup@.service: Drop dependency on networking.service (i. e. /etc/init.d/networking), and merely ensure that /run/network exists. This avoids unnecessary dependencies/waiting during boot and dependency cycles if hooks wait for other interfaces to come up (like ifenslave with bonding interfaces). (LP: #1414544) - Add Get-RTC-is-in-local-time-setting-from-etc-default-rc.patch: In Ubuntu we currently keep the setting whether the RTC is in local or UTC time in /etc/default/rcS "UTC=yes|no", instead of /etc/adjtime. (LP: #1377258) - Put session scopes into all cgroup controllers. This makes unprivileged user LXC containers work under systemd. (LP: #1346734) - Lower Breaks: to plymouth version which has the udev inotify fix in Ubuntu. - Lower libappamor1 dep to the Ubuntu version where it moved to /lib. - Make failure of boot-and-services NSpawn.test_boot non-fatal for now. This currently fails when being triggered by Jenkins, but is totally unreproducible when running this manually on the exact same machine. Upgrade fixes, keep until 16.04 LTS release: - systemd Conflicts/Replaces/Provides systemd-services. - Remove obsolete systemd-logind upstart job. - Clean up obsolete /etc/udev/rules.d/README. systemd (218-7) experimental; urgency=medium [ Martin Pitt ] * Don't attempt to mount the same swap partition twice through different device node aliases. (Closes: #772182, LP: #1399595) * logind: handle closing sessions over daemon restarts. (Closes: #759515, LP: #1415104) * logind: Fix sd_eviocrevoke ioctl call, to make forced input device release after log out actually work. * debian/rules: Drop obsolete --disable-multi-seat-x and --with-firmware-path configure options. * debian/udev.README.Debian: Trim the parts which are obsolete, wrong, or described in manpages. Only keep the Debian specific bits. (Part of #776546) * Actually install udev's README.Debian when building for Debian. (Closes: #776546) * Create system group "input" which was introduced in 215. (LP: #1414409) * ifup@.service: Don't fail if the interface is not configured in /etc/network/interfaces at all. (LP: #1414426) [ Michael Biebl ] * Update Vcs-Browser URL to use cgit and https. * Map $x-display-manager LSB facility to display-manager.service instead of making it a target. Using a target had the downside that multiple display managers could hook into it at the same time which could lead to several failed start attempts for the non-default display manager. -- Martin PittSun, 01 Feb 2015 22:48:51 +0100 ** Changed in: systemd (Ubuntu) Status: Fix Committed => Fix Released -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
Re: [Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
Hey Tom, Tom H [2015-01-28 14:55 -]: > I wasn't sure whether I had the latest or whether I had a previous > version but you didn't bump up the package version so I ran 'apt-get > --reinstall install udev systemd libudev1 libsystemd0 libpam-systemd > libgudev-1.0-0 gir1.2-gudev-1.0'. Actually I did, you should have 218-6ubuntu1pitti1. With 218-6ubuntu1 from vivid you should still get the error. > Please let me know if you'd some more info to look into why the gpt > generator's winning. No, it's quite clear why that happens (it's a simple race condition). Lennart says it doesn't matter which wins, but I'm still a bit doubtful about that due to not respecting mout options in gpt. But either way that's already true right now, so this patch is already an improvement. > [You didn't generate libsystemd-daemon0, libsystemd-journal0, libsystemd-login0 packages. Are they still needed?] No, they are obsolete and already dropped in vivid, too. Thanks, Martin -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
You're welcome. I wasn't sure whether I had the latest or whether I had a previous version but you didn't bump up the package version so I ran 'apt-get --reinstall install udev systemd libudev1 libsystemd0 libpam-systemd libgudev-1.0-0 gir1.2-gudev-1.0'. Please let me know if you'd some more info to look into why the gpt generator's winning. The fstab generator creates a "swap.target.requires" entry and the gpt generator creates a "swap.target.wants" entry so I would've expected fstab to trump gpt. # find /run -name "*73d341f1*" /run/systemd/generator/swap.target.requires/dev-disk-by\x2duuid-73d341f1\x2deedc\x2d43fc\x2d9e53\x2dba4194dae3fb.swap /run/systemd/generator/dev-disk-by\x2duuid-73d341f1\x2deedc\x2d43fc\x2d9e53\x2dba4194dae3fb.swap /run/udev/links/\x2fdisk\x2fby-uuid\x2f73d341f1-eedc-43fc-9e53-ba4194dae3fb # find /run -name "*sda3*" /run/systemd/generator.late/swap.target.wants/dev-sda3.swap /run/systemd/generator.late/dev-sda3.swap [You didn't generate libsystemd-daemon0, libsystemd-journal0, libsystemd-login0 packages. Are they still needed?] -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
Fixed upstream: http://cgit.freedesktop.org/systemd/systemd/commit/?id=7663df377016 http://cgit.freedesktop.org/systemd/systemd/commit/?id=cdda4aa8d http://cgit.freedesktop.org/systemd/systemd/commit/?id=37cf8fee4 I got confirmation in the Debian bug that this works, but confirmation from you would be highly appreciated. The second commit was done just now and fixes a regression that caused the boot to get stuck on systems which mount swap just from fstab; I'll update the PPA accordingly. ** Changed in: systemd (Ubuntu) Status: Triaged => Fix Committed -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
Ah, so you just did, thanks! The remaining worry is that in your case the gpt generator "won", but we want to prefer the fstab one. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
Fixed: # journalctl | grep swap Jan 28 07:35:09 yoga.lenovo systemd[1]: Activating swap Swap Partition... Jan 28 07:35:09 yoga.lenovo systemd[1]: Activating swap /dev/disk/by-uuid/73d341f1-eedc-43fc-9e53-ba4194dae3fb... Jan 28 07:35:09 yoga.lenovo kernel: Adding 8298492k swap on /dev/sda3. Priority:-1 extents:1 across:8298492k SSFS Jan 28 07:35:10 yoga.lenovo systemd[1]: Activated swap Swap Partition. Jan 28 07:35:10 yoga.lenovo systemd[1]: Activated swap /dev/disk/by-uuid/73d341f1-eedc-43fc-9e53-ba4194dae3fb. # systemctl status dev-sda3.swap ● dev-sda3.swap - Swap Partition Loaded: loaded (/run/systemd/generator.late/dev-sda3.swap) Active: active since Wed 2015-01-28 07:35:09 EST; 44min ago What: /dev/sda3 Docs: man:systemd-gpt-auto-generator(8) Process: 372 ExecActivate=/sbin/swapon /dev/sda3 (code=exited, status=0/SUCCESS) Jan 28 07:35:10 yoga.lenovo systemd[1]: Activated swap Swap Partition. # systemctl status dev-disk-by\x2duuid-73d341f1\x2deedc\x2d43fc\x2d9e53\x2dba4194dae3fb.swap ● dev-disk-byx2duuid-73d341f1x2deedcx2d43fcx2d9e53x2dba4194dae3fb.swap - /dev/disk/byx2duuid/73d341f1x2deedcx2d43fcx2d9e53x2dba4194dae3fb Loaded: loaded Active: inactive (dead) What: /dev/disk/byx2duuid/73d341f1x2deedcx2d43fcx2d9e53x2dba4194dae3fb Many thanks. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
Upstream has a proposed patch for this. I built a package for vivid with this, would you be able to test this? https://launchpad.net/~pitti/+archive/ubuntu/ppa Thanks in advance! ** Changed in: systemd (Ubuntu) Assignee: (unassigned) => Martin Pitt (pitti) -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
** Changed in: systemd (Debian) Status: Unknown => Confirmed -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
** Bug watch added: Debian Bug tracker #772182 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=772182 ** Also affects: systemd (Debian) via http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=772182 Importance: Unknown Status: Unknown -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
Yes. I commented out sda3 in order to suppress the errors. (Swap was mounted nonetheless.) -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice, through both fstab and gpt generators
Forwarded to http://lists.freedesktop.org/archives/systemd- devel/2015-January/027314.html -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice
Thanks for the additional data, that helps a lot. I'll forward this to upstream now. I have an idea how to fix that, but I'd like to discuss it upstream first. > (Until your post yesterday, I've had sda3 commented out.) Was that only in response to that bug? It would be weird if that bug would still happen even if you have swap commented out in /etc/fstab -- that would mean the fstab generator wouldn't recognize comments or so. Can you confirm that this is not the case? Thanks! ** Changed in: systemd (Ubuntu) Importance: Undecided => Medium ** Changed in: systemd (Ubuntu) Status: Incomplete => Triaged ** Summary changed: - systemd is activating swap twice + systemd is activating swap twice, through both fstab and gpt generators -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice, through both fstab and gpt generators To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice
Thanks again for looking into this. systemd-gpt-auto-generator output attached. $ cat /etc/fstab # filesystem mountpoint type options dump pass # sda1 UUID=6151-AFD6/boot/efi vfat defaults 01 # sda2 UUID=b51ee688-137c-47ec-9635-b69434b4e1f8 / ext4 defaults 01 # sda3 UUID=73d341f1-eedc-43fc-9e53-ba4194dae3fb noneswap sw00 (Until your post yesterday, I've had sda3 commented out.) ** Attachment added: "result2.tar" https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+attachment/4304111/+files/result2.tar -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice
Tom, ah, sorry about that, I didn't know that the gpt generator also uses the "late" argument (it wasn't here, but then again it doesn't produce anything for me). But indeed it seems to produce a swap unit for you, which explains this bug. Can you please re-do this with mkdir /tmp/gpt; sudo /lib/systemd/system-generators/systemd-gpt-auto- generator /tmp/gpt /tmp/gpt /tmp/gpt and tar up /tmp/gpt ? Please also include your /etc/fstab for reference, or at least the line which mounts the swap partition. Thanks! -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice
Thanks. The gpt generator failed: $ sudo /lib/systemd/system-generators/systemd-gpt-auto-generator /tmp/gpt x x Failed to create unit file x/dev-sda3.swap: No such file or directory $ tar -tf /tmp/result.tar tmp/fstab/ tmp/fstab/boot-efi.mount tmp/fstab/dev-disk-by\\x2duuid-73d341f1\\x2deedc\\x2d43fc\\x2d9e53\\x2dba4194dae3fb.swap tmp/fstab/local-fs.target.wants/ tmp/fstab/local-fs.target.wants/systemd-fsck-root.service tmp/fstab/local-fs.target.requires/ tmp/fstab/local-fs.target.requires/boot-efi.mount tmp/fstab/local-fs.target.requires/-.mount tmp/fstab/swap.target.requires/ tmp/fstab/swap.target.requires/dev-disk-by\\x2duuid-73d341f1\\x2deedc\\x2d43fc\\x2d9e53\\x2dba4194dae3fb.swap tmp/fstab/-.mount tmp/gpt/ ** Attachment added: "result.tar" https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+attachment/4303820/+files/result.tar -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice
This doesn't happen on my system, but this could be a bad interaction between the GPT and the fstab generator. Can you please run the following: mkdir /tmp/fstab; /lib/systemd/system-generators/systemd-fstab-generator /tmp/fstab x x mkdir /tmp/gpt; sudo /lib/systemd/system-generators/systemd-gpt-auto-generator /tmp/gpt x x tar xf /tmp/result.tar /tmp/fstab /tmp/gpt and then attach /tmp/result.tar here? ** Changed in: systemd (Ubuntu) Status: New => Incomplete -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice
> I can't find the option to tag this report "Tags:" right below the description, above the first comment. ** Tags added: systemd-boot -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
[Bug 1399595] Re: systemd is activating swap twice
(I can't find the option to tag this report with "systemd-boot". Is this a question of Launchpad permissions or am I too stupid to find the right thing to click?) I saw that "/lib/systemd/system-generators/" has systemd-fstab-generator and systemd-gpt-auto-generator so I disabled swap in my fstab: # grep swap /etc/fstab #UUID=73d341f1-eedc-43fc-9e53-ba4194dae3fb noneswap sw0 0 And swap's now activated once: # journalctl | grep swap | grep -v unit_create_cgroups Dec 06 04:21:00 yoga.lenovo systemd[1]: Activating swap Swap Partition... Dec 06 04:21:00 yoga.lenovo kernel: Adding 8298492k swap on /dev/sda3. Priority:-1 extents:1 across:8298492k SSFS Dec 06 04:21:00 yoga.lenovo systemd[1]: Activated swap Swap Partition. # swapon -s FilenameTypeSizeUsedPriority /dev/sda3 partition 8298492 0 -1 # find /run -name "*73d341f1*" /run/udev/links/\x2fdisk\x2fby-uuid\x2f73d341f1-eedc-43fc-9e53-ba4194dae3fb # find /run -name "*sda3*" /run/systemd/generator.late/swap.target.wants/dev-sda3.swap /run/systemd/generator.late/dev-sda3.swap -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1399595 Title: systemd is activating swap twice To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1399595/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs