Ubuntu Pastebin

Paste from egon at Wed, 7 Sep 2016 08:37:46 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
diff -Nru initramfs-tools-ubuntu-core-0.7.43+ppa11/debian/changelog initramfs-tools-ubuntu-core-0.7.43+ppa12/debian/changelog
--- initramfs-tools-ubuntu-core-0.7.43+ppa11/debian/changelog	2016-09-07 07:59:09.000000000 +0200
+++ initramfs-tools-ubuntu-core-0.7.43+ppa12/debian/changelog	2016-09-07 10:35:56.000000000 +0200
@@ -1,3 +1,10 @@
+initramfs-tools-ubuntu-core (0.7.43+ppa12) xenial; urgency=medium
+
+  * the grubenv/grub.cfg location with the latest gadget snap has
+    changed and we need to adjust the bind mounts
+
+ -- Michael Vogt <michael.vogt@ubuntu.com>  Wed, 07 Sep 2016 10:35:32 +0200
+
 initramfs-tools-ubuntu-core (0.7.43+ppa11) xenial; urgency=medium
 
   * Check also for ${tmpboot_mnt}/EFI/ubuntu/grub.cfg when detecting
diff -Nru initramfs-tools-ubuntu-core-0.7.43+ppa11/scripts/ubuntu-core-rootfs initramfs-tools-ubuntu-core-0.7.43+ppa12/scripts/ubuntu-core-rootfs
--- initramfs-tools-ubuntu-core-0.7.43+ppa11/scripts/ubuntu-core-rootfs	2016-09-07 07:58:02.000000000 +0200
+++ initramfs-tools-ubuntu-core-0.7.43+ppa12/scripts/ubuntu-core-rootfs	2016-09-07 10:37:13.000000000 +0200
@@ -322,12 +322,21 @@
 
 		# Since the boot partition is not required to actually boot
 		# the image, request the init system handle it (fsck+mount).
-		if [ -f "${tmpboot_mnt}/EFI/ubuntu/grub/grub.cfg" ] || [ -f "${tmpboot_mnt}/EFI/ubuntu/grub.cfg" ]; then
+		if [ -f "${tmpboot_mnt}/EFI/ubuntu/grub/grub.cfg" ]; then
+                        # OLD style (ubuntu-device-flash) base dir
 			efidir="/boot/efi"
 			efibinddir="${efidir}/EFI/ubuntu/grub"
 			if [ -d "${rootmnt}/${efidir}" ]; then
 				echo "$boot_partition $efidir auto defaults 0 2" >> "$fstab"
 				echo "$efibinddir $grubdir none bind 0 0" >> "$fstab"
+			fi
+                elif [ -f "${tmpboot_mnt}/EFI/ubuntu/grub.cfg" ]; then
+                        # NEW style (u-i base dir)
+			efidir="/boot/efi"
+			efibinddir="${efidir}/EFI/ubuntu/"
+			if [ -d "${rootmnt}/${efidir}" ]; then
+				echo "$boot_partition $efidir auto defaults 0 2" >> "$fstab"
+				echo "$efibinddir $grubdir none bind 0 0" >> "$fstab"
 			fi
 		else
 			echo "$boot_partition $ubootdir auto defaults 0 2" >> "$fstab"
Download as text