History

installer.sh.in: really fix the md parsing

jbu committed 11 years ago

Commit 3f0dfe51 parent 04933781 file · +4 −3Browse files

Unified · Split

installer.sh.in+4−3
@@ -166,11 +166,12 @@ show_partitions() { · 165 unmodified lines
166 done166 done
167 # Software raid (md)167 # Software raid (md)
168 for p in $(ls -d /dev/md* 2>/dev/null|grep '[0-9]'); do168 for p in $(ls -d /dev/md* 2>/dev/null|grep '[0-9]'); do
169 if cat /proc/mdstat|grep -qw $(echo $p|sed -e 's|/dev/||g'); then169 part=$(basename $p)
170 fstype=$(lsblk -nfr /dev/$p|awk '{print $2}')170 if cat /proc/mdstat|grep -qw $part; then
171 fstype=$(lsblk -nfr /dev/$part|awk '{print $2}')
171 [ "$fstype" = "crypto_LUKS" ] && continue172 [ "$fstype" = "crypto_LUKS" ] && continue
172 [ "$fstype" = "LVM2_member" ] && continue173 [ "$fstype" = "LVM2_member" ] && continue
173 fssize=$(lsblk -nr /dev/$p|awk '{print $4}')174 fssize=$(lsblk -nr /dev/$part|awk '{print $4}')
174 echo "$p"175 echo "$p"
175 echo "size:${fssize:-unknown};fstype:${fstype:-none}"176 echo "size:${fssize:-unknown};fstype:${fstype:-none}"
176 fi177 fi

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t