Create LV inodes on the target system

This commit is contained in:
Jeremy Gardais 2019-04-03 14:08:28 +02:00
parent ea717c0a75
commit da068ed9ce
Signed by: jegardai
GPG Key ID: E759BAA22501AF32
1 changed files with 14 additions and 0 deletions

14
debian/chroot.install vendored
View File

@ -132,5 +132,19 @@ done
### Fix group of disk/partitions
chgrp disk -- /target"${hdd}"*
## }}}
## Create LV inodes {{{
### Count the number of LV on the rescue system
nb_lv=$(ls -l -- /dev/dm-* | wc -l)
lv=0
### Start at 0 and less than $nb_lv cause it start at 0
while [ "${lv}" -lt "${nb_lv}" ]; do
#### Create the LV on the target system
[ -b /target/dev/dm-"${lv}" ] || mknod --mode=660 /target/dev/dm-"${lv}" b 252 "${lv}"
(( lv++ ))
done
### Fix group of LV
chgrp disk -- /target/dev/dm-*
## }}}
# }}}