[Bug 785818] New: iscsi boot fix proposal for mkinitrd script boot-ibft.sh
https://bugzilla.novell.com/show_bug.cgi?id=785818 https://bugzilla.novell.com/show_bug.cgi?id=785818#c0 Summary: iscsi boot fix proposal for mkinitrd script boot-ibft.sh Classification: openSUSE Product: openSUSE 12.2 Version: Final Platform: All OS/Version: SLES 11 Status: NEW Severity: Normal Priority: P5 - None Component: Basesystem AssignedTo: bnc-team-screening@forge.provo.novell.com ReportedBy: vasu.chandrasekhara@gmail.com QAContact: qa-bugs@suse.de Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Hi, I ran into an issue with sles 11 sp2 and it looks like this issue persists in opensuse as well. When installing on an iSCSI SAN LUN, one of the advantages is that you should be able to switch the physical server and boot the same LUN off iSCSI. With a changed set of iSCSI boot parameters, configured in the iSCSI capable network card and passed to the OS in the iBFT. Unfortunately, during the creation of the initrd file, mkinitrd persists ip & iscsi information of the current server setup into the init or run_all.sh script. Example: Code: [ "$debug" ] && echo preping 12-network.sh [ "$static_macaddresses" ] || static_macaddresses='eth0:11:22:33:44:55:66' [ "$static_ips" ] || static_ips='10.10.10.10:::255.255.255.0:linux:eth0:none' [ "$drvlink" ] || drvlink='pci:v00008086d000010FBsv000010CFsd000015A4bc02sc00i00' if [ "$interface" -o "$dhcp" -o "$ip" -o "$nfsaddrs" -o "$drvlink" ]; then modules=" af_packet $bonding_module" [ "$debug" ] && echo running 12-network.sh source boot/12-network.sh [ "$modules" ] && load_modules fi [ "$debug" ] && echo preping 13-iscsi.sh [ "$root_iscsi" ] || root_iscsi='1' [ "$iscsi_sessions" ] || iscsi_sessions='1' [ "$TargetName1" ] || TargetName1='iqn.1992-08.com.myiscsistorage:sn.111111111' [ "$TargetAddress1" ] || TargetAddress1='10.10.10.100' [ "$TargetPort1" ] || TargetPort1='3260' [ "$TargetPort" ] || TargetPort='3260' if [ "$root_iscsi" -o "$TargetAddress" ]; then modules=" iscsi_tcp crc32c scsi_transport_iscsi iscsi_ibft bnx2i" [ "$debug" ] && echo running 13-iscsi.sh source boot/13-iscsi.sh [ "$modules" ] && load_modules fi The information should rather be dynamically read from the iBFT table when booting via iscsi. Which is actually also done in /lib/mkinitrd/scripts/boot-ibft.sh: Code: ip="$(ibft_get_att ip-addr)::$(ibft_get_att gateway):$(ibft_get_att subnet-mask):$ibft_hostname:$(ibft_get_ethdev):$nettype" interface=$(ibft_get_ethdev) macaddress=$(ibft_get_att mac) InitiatorName=$(ibft_get_initiatorname) But the network activation in boot-network.sh expects different variables and format, see /lib/mkinitrd/scripts/boot-network.sh: Code: static_ips=($static_ips) for macaddr in $static_macaddresses -- $dhcp_macaddresses; do My fix proposal for /lib/mkinitrd/scripts/boot-ibft.sh is to create the variables required for boot-network.sh: Code: ... ip="$(ibft_get_att ip-addr)::$(ibft_get_att gateway):$(ibft_get_att subnet-mask):$ibft_hostname:$(ibft_get_ethdev):$nettype" interface=$(ibft_get_ethdev) macaddress=$(ibft_get_att mac) InitiatorName=$(ibft_get_initiatorname) ################################################## if test "$nettype" = "dhcp"; then dhcp_macaddresses="$interface:$macaddress" else static_macaddresses="$interface:$macaddress" static_ips=$ip fi ################################################## Hope, somebody can make use of this fix and include it into the next patch/release. Best, Vasu Reproducible: Always Steps to Reproduce: 1. Install SLES SP2 on iSCSI LUN (withiscsi=1) with Server A. 2. Map iSCSI LUN to Server B (which has other iSCSI Boot parameters) 3. Server B fails to boot properly. http://forums.opensuse.org/english/get-technical-help-here/install-boot-logi... -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c
Jiaying ren
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c2
Lee Duncan
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c3
--- Comment #3 from Vasu Chandrasekhara
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c4
--- Comment #4 from Lee Duncan
When installing on an iSCSI SAN LUN, one of the advantages is that you should be able to switch the physical server and boot the same LUN off iSCSI. With a changed set of iSCSI boot parameters, configured in the iSCSI capable network card and passed to the OS in the iBFT.
What do you mean by "switch the physical server"? I believe you mean that the exact same iSCSI target would become available at a different target IP address. Correct? When you answer, please change NEEDSINFO to assigned to me. NOTE: I believe I _do_ have a fix for this, so I would like to know how to test said fix. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c5
Vasu Chandrasekhara
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c6
Lee Duncan
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c7
--- Comment #7 from Vasu Chandrasekhara
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c8
--- Comment #8 from Lee Duncan
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c9
--- Comment #9 from Lee Duncan
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c10
--- Comment #10 from Lee Duncan
https://bugzilla.novell.com/show_bug.cgi?id=785818
https://bugzilla.novell.com/show_bug.cgi?id=785818#c11
Vasu Chandrasekhara
participants (1)
-
bugzilla_noreply@novell.com