Load thin Kernel Modules in initramfs for support on boot
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
lvm2 (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
I have an issue where lvm2 thinpool volume groups are not automatically activated after reboot.
Environmentals:
Ubuntu Server 15.10, minimal install
UEFI/Secure Boot in use
Ubuntu 15.10 (GNU/Linux 4.2.0-25-generic x86_64)
root@cluster-02:~# cat /etc/os-release
NAME="Ubuntu"
VERSION="15.10 (Wily Werewolf)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 15.10"
VERSION_ID="15.10"
HOME_URL="http://
SUPPORT_URL="http://
BUG_REPORT_URL="http://
Here is the volume config before adding the new volume:
root@cluster-02:~# lvs -a
LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
lvswap vgraid0 -wi-ao---- 29.80g
lvtmp vgraid0 -wi-ao---- 29.80g
lvvartmp vgraid0 -wi-ao---- 29.80g
lvhome vgraid10 -wi-ao---- 29.80g
lvroot vgraid10 -wi-ao---- 7.45g
lvusr vgraid10 -wi-ao---- 7.45g
lvvar vgraid10 -wi-ao---- 3.72g
lvvarcache vgraid10 -wi-ao---- 119.21g
lvvarlib vgraid10 -wi-ao---- 32.00g
lvvarlog vgraid10 -wi-ao---- 14.90g
I add a new thinpool volume using this command:
lvcreate -L 1T --type thin-pool --thinpool vgraid10/lvlxc
root@cluster-02:~# lvcreate -L 1T --type thin-pool --thinpool vgraid10/lvlxc
Logical volume "lvlxc" created.
Which results in this lvs:
root@cluster-02:~# lvs -a
LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
lvswap vgraid0 -wi-ao---- 29.80g
lvtmp vgraid0 -wi-ao---- 29.80g
lvvartmp vgraid0 -wi-ao---- 29.80g
lvhome vgraid10 -wi-ao---- 29.80g
lvlxc vgraid10 twi-a-tz-- 1.00t 0.00 0.42
[lvlxc_tdata] vgraid10 Twi-ao---- 1.00t
[lvlxc_tmeta] vgraid10 ewi-ao---- 128.00m
[lvol0_pmspare] vgraid10 ewi------- 128.00m
lvroot vgraid10 -wi-ao---- 7.45g
lvusr vgraid10 -wi-ao---- 7.45g
lvvar vgraid10 -wi-ao---- 3.72g
lvvarcache vgraid10 -wi-ao---- 119.21g
lvvarlib vgraid10 -wi-ao---- 32.00g
lvvarlog vgraid10 -wi-ao---- 14.90g
I then create an unprivileged lxc container using the thinpool:
root@cluster-02:~# lxc-create -B lvm --vgname=vgraid10 --thinpool=lvlxc -t download -n tmpl-centos-
File descriptor 3 (/var/lib/
Logical volume "tmpl-centos-
Using image from local cache
Unpacking the rootfs
...
The lvs output:
root@cluster-02:~# lvs -a
LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
lvswap vgraid0 -wi-ao---- 29.80g
lvtmp vgraid0 -wi-ao---- 29.80g
lvvartmp vgraid0 -wi-ao---- 29.80g
lvhome vgraid10 -wi-ao---- 29.80g
lvlxc vgraid10 twi-aotz-- 1.00t 0.09 0.46
[lvlxc_tdata] vgraid10 Twi-ao---- 1.00t
[lvlxc_tmeta] vgraid10 ewi-ao---- 128.00m
[lvol0_pmspare] vgraid10 ewi------- 128.00m
lvroot vgraid10 -wi-ao---- 7.45g
lvusr vgraid10 -wi-ao---- 7.45g
lvvar vgraid10 -wi-ao---- 3.72g
lvvarcache vgraid10 -wi-ao---- 119.21g
lvvarlib vgraid10 -wi-ao---- 32.00g
lvvarlog vgraid10 -wi-ao---- 14.90g
tmpl-
Everything is ok at this point. Now, I will reboot the machine.
root@cluster-02:~# lvs -a
LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
lvswap vgraid0 -wi-ao---- 29.80g
lvtmp vgraid0 -wi-ao---- 29.80g
lvvartmp vgraid0 -wi-ao---- 29.80g
lvhome vgraid10 -wi-ao---- 29.80g
lvlxc vgraid10 twi---tz-- 1.00t
[lvlxc_tdata] vgraid10 Twi------- 1.00t
[lvlxc_tmeta] vgraid10 ewi------- 128.00m
[lvol0_pmspare] vgraid10 ewi------- 128.00m
lvroot vgraid10 -wi-ao---- 7.45g
lvusr vgraid10 -wi-ao---- 7.45g
lvvar vgraid10 -wi-ao---- 3.72g
lvvarcache vgraid10 -wi-ao---- 119.21g
lvvarlib vgraid10 -wi-ao---- 32.00g
lvvarlog vgraid10 -wi-ao---- 14.90g
tmpl-
At this point, the volume groups (thinpool and thin volume) are not active. This causes issues and requires that I manually activate the volumes:
root@cluster-02:~# lvchange -ay vgraid10/lvlxc
root@cluster-02:~# lvs -a
LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
lvswap vgraid0 -wi-ao---- 29.80g
lvtmp vgraid0 -wi-ao---- 29.80g
lvvartmp vgraid0 -wi-ao---- 29.80g
lvhome vgraid10 -wi-ao---- 29.80g
lvlxc vgraid10 twi-aotz-- 1.00t 0.09 0.46
[lvlxc_tdata] vgraid10 Twi-ao---- 1.00t
[lvlxc_tmeta] vgraid10 ewi-ao---- 128.00m
[lvol0_pmspare] vgraid10 ewi------- 128.00m
lvroot vgraid10 -wi-ao---- 7.45g
lvusr vgraid10 -wi-ao---- 7.45g
lvvar vgraid10 -wi-ao---- 3.72g
lvvarcache vgraid10 -wi-ao---- 119.21g
lvvarlib vgraid10 -wi-ao---- 32.00g
lvvarlog vgraid10 -wi-ao---- 14.90g
tmpl-
I have tried setting flags on the thinpool (vgraid10/lvlxc) as follows, to no avail:
root@cluster-02:~# lvchange -kn vgraid10/lvlxc
root@cluster-02:~# lvchange -ay vgraid10/lvlxc
root@cluster-02:~# lvchange -aye vgraid10/lvlxc
root@cluster-02:~# apt-cache policy thin-provisioni ng-tools ng-tools: us.archive. ubuntu. com/ubuntu/ wily/universe amd64 Packages dpkg/status
thin-provisioni
Installed: 0.3.2-1ubuntu1
Candidate: 0.3.2-1ubuntu1
Version table:
*** 0.3.2-1ubuntu1 0
500 http://
100 /var/lib/