Kickstart Pre-Installation Script Can't Process Bash Pipe

Latest response

You can list out your block devices in your pre-execution script like this, /usr/bin/lsblk -fl However, if you attempt to pretty-print them with:

declare -i i=1
declare -a SOURCES
IFS="\n"
/usr/bin/lsblk -fl | \
while read d
do
SOURCES[$i]=$d
echo $i: ${SOURCES[$i]}
let i=$i+1
done

you get nothing--even when redirecting output to the current virtual terminal which in my case was /dev/tty6, (after saying exec < /dev/tty6 > /dev/tty6 2> /dev/tty6 chvt 6). This was to be the basis for interaction with the user to select a source disk.

Responses