From: Vladimir Sokolovsky Date: Tue, 9 Dec 2008 08:03:03 +0000 (+0200) Subject: ipv6 can't be loaded with modprobe on OpenSuSE 10.3, causing ib_ipoib X-Git-Tag: vofed-1.4~1 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=40b97e1f9292ee7e1b412eb4d9956a40db6d6290;p=~tnikolova%2Fofed_scripts%2F.git ipv6 can't be loaded with modprobe on OpenSuSE 10.3, causing ib_ipoib loading failure with unresolved symbol. This patch comments line in /etc/modprobe.d/ipv6. BUG: https://bugs.openfabrics.org/show_bug.cgi?id=1449 Signed-off-by: Vladimir Sokolovsky --- diff --git a/install.pl b/install.pl index c42d30c..2335d63 100755 --- a/install.pl +++ b/install.pl @@ -4206,6 +4206,27 @@ sub main close MODPROBE_CONF; } } + + # BUG: https://bugs.openfabrics.org/show_bug.cgi?id=1449 + if (-f "/etc/modprobe.d/ipv6") { + open(IPV6, "/etc/modprobe.d/ipv6") or die "Can't open /etc/modprobe.d/ipv6: $!"; + my @ipv6_lines; + while () { + push @ipv6_lines, $_; + } + close(IPV6); + + open(IPV6, ">/etc/modprobe.d/ipv6") or die "Can't open /etc/modprobe.d/ipv6: $!"; + foreach my $line (@ipv6_lines) { + chomp $line; + if ($line =~ /^\s*install ipv6/) { + print IPV6 "# $line\n"; + } else { + print IPV6 "$line\n"; + } + } + close(IPV6); + } } if ( not $quiet ) { diff --git a/uninstall.sh b/uninstall.sh index e737bd0..9855769 100755 --- a/uninstall.sh +++ b/uninstall.sh @@ -312,6 +312,10 @@ uninstall() fi perl -ni -e "print unless (/mlx4_core/)" /etc/modprobe.conf + + if [ -f /etc/modprobe.d/ipv6 ]; then + perl -ni -e "s@# install ipv6 \/bin\/true@install ipv6 /bin/true@;print" /etc/modprobe.d/ipv6 + fi } echo