163 if [ -f "${UPDATEFILE}" ]; then
164 /usr/sbin/bootadm update-archive
165 if [ $? != 0 ]; then
166 cecho ""
167 cecho "WARNING: Automatic update of the boot archive failed."
168 cecho "Update the archives using 'bootadm update-archive'"
169 cecho "command and then reboot the system from the same device that"
170 cecho "was previously booted."
171 cecho ""
172 exit $SMF_EXIT_ERR_FATAL
173 fi
174 rm -f $UPDATEFILE
175 bootcmd=`/usr/sbin/eeprom bootcmd | /usr/bin/sed -e 's#bootcmd=##g'`
176 if [ `uname -p` = "i386" ]; then
177 /usr/sbin/reboot -f dryrun
178 if [ $? = 0 ]; then
179 /usr/sbin/reboot -f -- "$bootcmd"
180 exit $SMF_EXIT_OK
181 fi
182 boot_prop=`/usr/sbin/svccfg -s svc:/system/boot-config:default listprop config/auto-reboot-safe | \
183 /usr/bin/nawk '{ print $3}'`
184 if [ "$boot_prop" != "true" ]; then
185 cecho ""
186 cecho "WARNING: Reboot required."
187 cecho "The system has updated the cache of files (boot archive) that is used"
188 cecho "during the early boot sequence. To avoid booting and running the system"
189 cecho "with the previously out-of-sync version of these files, reboot the"
190 cecho "system from the same device that was previously booted."
191 cecho ""
192 exit $SMF_EXIT_ERR_FATAL
193 else
194 /usr/sbin/reboot -p
195 exit $SMF_EXIT_OK
196 fi
197 fi
198 /usr/sbin/reboot -- "$bootcmd"
199 fi
200
201 exit $SMF_EXIT_OK
|
163 if [ -f "${UPDATEFILE}" ]; then
164 /usr/sbin/bootadm update-archive
165 if [ $? != 0 ]; then
166 cecho ""
167 cecho "WARNING: Automatic update of the boot archive failed."
168 cecho "Update the archives using 'bootadm update-archive'"
169 cecho "command and then reboot the system from the same device that"
170 cecho "was previously booted."
171 cecho ""
172 exit $SMF_EXIT_ERR_FATAL
173 fi
174 rm -f $UPDATEFILE
175 bootcmd=`/usr/sbin/eeprom bootcmd | /usr/bin/sed -e 's#bootcmd=##g'`
176 if [ `uname -p` = "i386" ]; then
177 /usr/sbin/reboot -f dryrun
178 if [ $? = 0 ]; then
179 /usr/sbin/reboot -f -- "$bootcmd"
180 exit $SMF_EXIT_OK
181 fi
182 boot_prop=`/usr/sbin/svccfg -s svc:/system/boot-config:default listprop config/auto-reboot-safe | \
183 /usr/xpg4/bin/awk '{ print $3}'`
184 if [ "$boot_prop" != "true" ]; then
185 cecho ""
186 cecho "WARNING: Reboot required."
187 cecho "The system has updated the cache of files (boot archive) that is used"
188 cecho "during the early boot sequence. To avoid booting and running the system"
189 cecho "with the previously out-of-sync version of these files, reboot the"
190 cecho "system from the same device that was previously booted."
191 cecho ""
192 exit $SMF_EXIT_ERR_FATAL
193 else
194 /usr/sbin/reboot -p
195 exit $SMF_EXIT_OK
196 fi
197 fi
198 /usr/sbin/reboot -- "$bootcmd"
199 fi
200
201 exit $SMF_EXIT_OK
|