- Timestamp:
- Jun 12, 2009 10:05:39 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Installer/solaris/ipsinstall.sh
r20490 r20494 90 90 # Create the device link 91 91 /usr/sbin/devfsadm -i vboxdrv 92 93 # Load VBoxNetAdapter vboxnet 94 if test -f /platform/i86pc/kernel/drv/vboxnet.conf; then 95 /opt/VirtualBox/vboxdrv.sh netstart 96 rc=$? 97 98 if test "$rc" -eq 0; then 99 # nwam/dhcpagent fix 100 nwamfile=/etc/nwam/llp 101 nwambackupfile=$nwamfile.vbox 102 if test -f "$nwamfile"; then 103 sed -e '/vboxnet/d' $nwamfile > $nwambackupfile 104 echo "vboxnet0 static 192.168.56.1" >> $nwambackupfile 105 mv -f $nwambackupfile $nwamfile 106 echo " -> patched /etc/nwam/llp to use static IP for vboxnet0" 92 rc=$? 93 94 if test "$rc" -eq 0; then 95 # Load VBoxNetAdapter vboxnet 96 if test -f /platform/i86pc/kernel/drv/vboxnet.conf; then 97 /opt/VirtualBox/vboxdrv.sh netstart 98 rc=$? 99 100 if test "$rc" -eq 0; then 101 # nwam/dhcpagent fix 102 nwamfile=/etc/nwam/llp 103 nwambackupfile=$nwamfile.vbox 104 if test -f "$nwamfile"; then 105 sed -e '/vboxnet/d' $nwamfile > $nwambackupfile 106 echo "vboxnet0 static 192.168.56.1" >> $nwambackupfile 107 mv -f $nwambackupfile $nwamfile 108 echo " -> patched /etc/nwam/llp to use static IP for vboxnet0" 109 fi 107 110 fi 108 111 fi 112 else 113 echo "## Failed to create device link in /dev for vboxdrv" 109 114 fi 110 115 111 116 # Load VBoxNetFilter vboxflt 112 if test -f /platform/i86pc/kernel/drv/vboxflt.conf; then117 if test "$rc" -eq 0 && test -f /platform/i86pc/kernel/drv/vboxflt.conf; then 113 118 /opt/VirtualBox/vboxdrv.sh fltstart 114 119 rc=$? … … 116 121 117 122 # Load VBoxUSBMonitor vboxusbmon (do NOT load for Solaris 10) 118 if test -f /platform/i86pc/kernel/drv/vboxusbmon.conf && test "$osversion" != "5.10"; then123 if test "$rc" -eq 0 && test -f /platform/i86pc/kernel/drv/vboxusbmon.conf && test "$osversion" != "5.10"; then 119 124 /opt/VirtualBox/vboxdrv.sh usbstart 120 125 rc=$? … … 127 132 128 133 /usr/sbin/devfsadm -i vboxusbmon 129 fi 130 fi 131 fi 132 134 rc=$? 135 if test "$rc" -ne 0; then 136 echo "## Failed to create device link in /dev for vboxusbmon" 137 fi 138 fi 139 fi 140 fi 141 142 rc2=0 133 143 # Enable Zone access service (note IPS auto-prefixes "virtualbox-" to the filename...) 134 144 if test -f "/var/svc/manifest/application/virtualbox/virtualbox-zoneaccess.xml"; then 135 145 /usr/sbin/svccfg import /var/svc/manifest/application/virtualbox/virtualbox-zoneaccess.xml 136 rc =$?137 if test "$rc " -eq 0; then146 rc2=$? 147 if test "$rc2" -eq 0; then 138 148 /usr/sbin/svcadm enable -s svc:/application/virtualbox/zoneaccess 139 rc =$?140 if test "$rc " -eq 0; then149 rc2=$? 150 if test "$rc2" -eq 0; then 141 151 echo "Enabled VirtualBox zone service." 142 152 else … … 155 165 156 166 # Install python bindings 167 rc3=0 157 168 if test -f "/opt/VirtualBox/sdk/installer/vboxapisetup.py" || test -h "/opt/VirtualBox/sdk/installer/vboxapisetup.py"; then 158 169 PYTHONBIN=`which python` … … 164 175 cd /opt/VirtualBox/sdk/installer 165 176 $PYTHONBIN ./vboxapisetup.py install > /dev/null 177 rc3=$? 166 178 echo "Done." 167 179 else … … 169 181 echo " Manually run '/opt/VirtualBox/sdk/installer/vboxapisetup.py install'" 170 182 echo " to install the bindings when python is available." 171 fi 172 fi 173 174 # Update boot archive 175 BOOTADMBIN=/sbin/bootadm 176 if test -f "$BOOTADMBIN" || test -h "$BOOTADMBIN"; then 177 echo "Updating boot archive..." 178 $BOOTADMBIN update-archive > /dev/null 183 rc3=1 184 fi 185 fi 186 187 # Update boot archive (only when driver's were all successfully loaded) 188 rc4=0 189 if test "$rc" -eq 0; then 190 BOOTADMBIN=/sbin/bootadm 191 if test -f "$BOOTADMBIN" || test -h "$BOOTADMBIN"; then 192 echo "Updating boot archive..." 193 $BOOTADMBIN update-archive > /dev/null 194 rc4=$? 195 fi 179 196 fi 180 197 181 198 echo "Done." 182 if test "$rc" -eq 0 ; then199 if test "$rc" -eq 0 && test "$rc2" -eq 0 && test "$rc3" -eq 0 && test "$rc4" -eq 0; then 183 200 echo "Post install successfully completed." 184 201 else 185 202 echo "Post install completed but with some errors." 186 fi 187 exit 0 188 203 # 20 - partially failed installed 204 $rc=20 205 fi 206 exit $rc 207
Note:
See TracChangeset
for help on using the changeset viewer.