Your message dated Sat, 18 Jan 2020 15:51:58 +0000 with message-id <a76af46c41881357cee3b45278fe9fd5d5c92e21.camel@decadent.org.uk> and subject line Re: Bug#944777: initramfs-tools-core: Resume fails when UUID= syntax used in conf.d/resume. has caused the Debian Bug report #944777, regarding initramfs-tools-core: Resume fails when UUID= syntax used in conf.d/resume. to be marked as done. This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact owner@bugs.debian.org immediately.) -- 944777: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=944777 Debian Bug Tracking System Contact owner@bugs.debian.org with problems
--- Begin Message ---
- To: Debian Bug Tracking System <submit@bugs.debian.org>
- Subject: initramfs-tools-core: Resume fails when UUID= syntax used in conf.d/resume.
- From: Glenn Washburn <development@efficientek.com>
- Date: Fri, 15 Nov 2019 01:30:59 -0600
- Message-id: <157380305984.17683.17955438597988154294.reportbug@crass-HP-ZBook-15-G2>
Package: initramfs-tools-core Version: 0.130ubuntu3.9 Severity: normal Tags: newcomer Dear Maintainer, Resume from hibernation will fail when /etc/initramfs-tools/conf.d/resume contains "RESUME=UUID=<UUID of hibernation image>". According to NEWS this should work. The reason is does not is because UUID= processing is only done for the resume kernel parameter (see init lines 123-128). No processing is done for the RESUME shell variable included from conf.d. Recognizing that conf.d/resume is being sourced as a script in init, I've created a hack to fix by adding the processing in the resume file. My resume file looks like this: """ RESUME=UUID=deadbeef-cafe-dead-beef-cafedeadbeef case $RESUME in UUID=*) RESUME="/dev/disk/by-uuid/${RESUME#UUID=}" esac """ Incidentally, I believe this is the issue in #872664. I chose to create a new bug because that one is unnecessarily specific. The bug applies to all versions on all platforms. I suggest that the case be moved out of the resume= kernel param handling and added just after line 206, before the "resume" variable is set. Actually, I see no reason to use the RESUME variable aside from the fact that its what you're supposed to use in the conf.d/resume file. But its confusing and inconsistent to provide "resume=UUID=" as the kernel parameter and "RESUME=UUID=" in the conf.d/resume file. Attached is a patch exemplifying my proposed changes (not tested). The patch should allow for documentation to notify about the depreciation of RESUME= in conf.d/resume and to start using resume= instead, but to continue being backwards compatible with the old syntax. The hooks scripts would need to be updated to account for the new variable (pretty trivial change, something like "RESUME=${RESUME:-$resume}"). Glenndiff --git a/init b/init index 1cc96c3..11788fb 100755 --- a/init +++ b/init @@ -121,11 +121,7 @@ for x in $(cat /proc/cmdline); do UBIMTD=${x#ubi.mtd=} ;; resume=*) - RESUME="${x#resume=}" - case $RESUME in - UUID=*) - RESUME="/dev/disk/by-uuid/${RESUME#UUID=}" - esac + resume="${x#resume=}" ;; resume_offset=*) resume_offset="${x#resume_offset=}" @@ -201,10 +197,15 @@ if [ -z "${BOOT}" ]; then BOOT=local fi -if [ -n "${noresume}" ] || [ "$RESUME" = none ]; then +if [ -n "${noresume}" ] || [ "${resume:-$RESUME}" = none ]; then noresume=y + unset resume else - resume=${RESUME:-} + resume=${resume:-$RESUME} + case $resume in + UUID=*) + resume="/dev/disk/by-uuid/${resume#UUID=}" + esac fi mount -t tmpfs -o "nodev,noexec,nosuid,size=${RUNSIZE:-10%},mode=0755" tmpfs /run
--- End Message ---
--- Begin Message ---
- To: 944777-done@bugs.debian.org
- Subject: Re: Bug#944777: initramfs-tools-core: Resume fails when UUID= syntax used in conf.d/resume.
- From: Ben Hutchings <ben@decadent.org.uk>
- Date: Sat, 18 Jan 2020 15:51:58 +0000
- Message-id: <a76af46c41881357cee3b45278fe9fd5d5c92e21.camel@decadent.org.uk>
- In-reply-to: <20191126022505.2c3669ac@crass-HP-ZBook-15-G2>
- References: <157380305984.17683.17955438597988154294.reportbug@crass-HP-ZBook-15-G2> <4104b5c08d2d471caef701c1c5428ef24d859680.camel@decadent.org.uk> <20191126022505.2c3669ac@crass-HP-ZBook-15-G2>
On Tue, 26 Nov 2019 02:25:05 -0600 Glenn Washburn <development@efficientek.com> wrote: > On Fri, 15 Nov 2019 22:20:53 +0000 > Ben Hutchings <ben@decadent.org.uk> wrote: > > > Control: tag -1 moreinfo > > > > On Fri, 2019-11-15 at 01:30 -0600, Glenn Washburn wrote: > > > Package: initramfs-tools-core > > > Version: 0.130ubuntu3.9 > > > > This is an Ubuntu version, so maybe you should report this on > > Launchpad. > > After further investigation, you're right its an ubuntu issue. I've > reported it there. I had thought the issue was in init where I pointed > to and since the code was the same between debian and ubuntu, I thought > debian would have the issue as well. Now, I understand that the issue > is actually in scripts/local-premount/resume, which differs where the > bug is. [...] Therefore closing this bug report. Ben. -- Ben Hutchings Humans are not rational beings; they are rationalising beings.Attachment: signature.asc
Description: This is a digitally signed message part
--- End Message ---