Fixed module installation error, for real.

This commit is contained in:
Bob Lantz
2010-08-17 22:32:22 -07:00
parent dd2a2442c4
commit 59d326295f
2 changed files with 13 additions and 12 deletions
+3 -4
View File
@@ -37,7 +37,7 @@ def moduleDeps( subtract=None, add=None ):
info( '*** Removing ' + mod + '\n' )
rmmodOutput = rmmod( mod )
if rmmodOutput:
error( 'Error removing ' + mod + '\n%s' % rmmodOutput )
error( 'Error removing ' + mod + ': %s\n' % rmmodOutput )
exit( 1 )
if mod in lsmod():
error( 'Failed to remove ' + mod + '; still there!\n' )
@@ -47,9 +47,8 @@ def moduleDeps( subtract=None, add=None ):
info( '*** Loading ' + mod + '\n' )
modprobeOutput = modprobe( mod )
if modprobeOutput:
error( 'Error inserting ' + mod + ';\n See INSTALL.\n%s' %
modprobeOutput )
exit( 1 )
error( 'Error inserting ' + mod + '- is it installed?\n' +
'Error was: %s\n' % modprobeOutput )
if mod not in lsmod():
error( 'Failed to insert ' + mod + '\n' )
exit( 1 )
+10 -8
View File
@@ -127,7 +127,12 @@ function of {
sudo apt-get remove -y avahi-daemon
# Disable IPv6. Add to /etc/modprobe.d/blacklist:
sudo sh -c "echo 'blacklist net-pf-10\nblacklist ipv6' >> /etc/modprobe.d/blacklist"
if [ "$DIST" = "Ubuntu" ]; then
BLACKLIST=/etc/modprobe.d/blacklist.conf
else
BLACKLIST=/etc/modprobe.d/blacklist
fi
sudo sh -c "echo 'blacklist net-pf-10\nblacklist ipv6' >> $BLACKLIST"
}
# Install OpenVSwitch
@@ -144,7 +149,7 @@ function ovs {
sudo apt-get -y --force-yes -t lenny-backports install autoconf
fi
if [ "$DIST" == "Ubuntu" ]; then
if [ "$DIST" = "Ubuntu" ]; then
sudo apt-get -y install $KERNEL_HEADERS
fi
@@ -170,9 +175,9 @@ function nox {
#Install NOX deps:
sudo apt-get -y install autoconf automake g++ libtool python python-twisted swig libxerces-c2-dev libssl-dev make
if [ "$DIST" == "Debian" ]; then
if [ "$DIST" = "Debian" ]; then
sudo apt-get -y install libboost1.35-dev
elif [ "$DIST" == "Ubuntu" ]; then
elif [ "$DIST" = "Ubuntu" ]; then
sudo apt-get -y install python-dev libboost-dev
sudo apt-get -y install libboost-filesystem-dev
sudo apt-get -y install libboost-test-dev
@@ -187,7 +192,7 @@ function nox {
# With later autoconf versions this doesn't quite work:
./boot.sh --apps-core || true
if [ "$DIST" == "Debian" ]; then
if [ "$DIST" = "Debian" ]; then
# So use this instead:
autoreconf --install --force
fi
@@ -292,9 +297,6 @@ function all {
oftest
cbench
other
# BL Hack: for some annoying reason, the first depmod doesn't
# seem to take on Ubuntu, so do it once again for good measure!
modprobe
echo "Please reboot, then run ./mininet/util/install.sh -c to remove unneeded packages."
echo "Enjoy Mininet!"
}