shell problems with %pre

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



1 numdisks=0
2 while read num dev
3 do
4         if [ "$dev" == "sd" ];then
5                 ((numdisks++))
6         fi
7 done < /proc/devices

Working with 7.3 and having some problems with the shell that interprets
the %pre section. The above code works under bash without issue. But
a couple of parts balk during install.

Line 4's == seems to break 7.3's installation shell. If i change it to as
ingle = sign then it works. However, the increment is broken too. I can
see 3 errors (the correct number for the target system) if I switch to the
anaconda info screen.

I've tried several variations of line 5 to no avail. Suggestions
appreciated. I think I'm just missing basic info on which shell runs
during the installation process, that way I could look up the correct
syntaxes. Problem is the 7.3 kickstart docs don't mention it at all. And
the example code for the 8.0 kickstart explicitly uses some of the
conventions I'm trying here.


--
Derek Vadala, derek@xxxxxxxxxxxx, http://www.cynicism.com/~derek







[Index of Archives]     [Red Hat General]     [CentOS Users]     [Fedora Users]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]

  Powered by Linux