ITEM: R5894L
bosboot fails with 0506-210 error
Question:
Env: AIX 3.2.5.
Desc: Running "bosboot -a -d /dev/hdisk0" fails with:
0506-210 mkfs: the filesystem is currently mounted
0301-155 bosboot: mkfs failed for /dev/hd5
0301-165 bosboot: WARNING bosboot failed DO NOT ATTEMPT
TO REBOOT SYSTEM
rmdir: 0653-611 directory /var/tmp/blv is not empty
Action:
Debug the script with the following command:
\# ksh -x /usr/sbin/bosboot -a -d /dev/hdisk0
This gave the following results:
...
+ state_func4
+ let act += 1
+ [ 5 -le 24 ]
+ [ 5 - ne 0 ]
+ state_func5
+ let act += 1
+ [ 6 -le 24 ]
+ [ 6 -ne 0 ]
+ state_func6
0506-210 mkfs: the filesystem is currently mounted
0301-155 bosboot: mkfs failed for /dev/hd5
0301-165 bosboot: WARNING bosboot failed DO NOT ATTEMPT
TO REBOOT SYSTEM
rmdir: 0653-611 directory /var/tmp/blv is not empty
This is the part of the script where it is failing:
\# Function state_func6
state_func6 () {
\# Use boot logical volume space for holding RAM file system
\# and stripped kernel. This is used for disk image only.
\# Save logical volume recovery block and install settings
\# information block.
trap 'error_func 0' 1 2 15
dd bs=512 count=2 if=$blvdev of=/tmp/blv2blk > /dev/null 2>&1
[ ! -d "$blvmnt" ] && mkdir $blvmnt
echo y | mkfs -V jfs $blvdev
rc="$?"; [ "$rc" -ne 0 ] && error_func 42 $blvdev
mount $blvdev $blvmnt
} \# End of state_func6
We then ran the following commands to debug:
\# mkfs -V jfs /dev/hd5
0506-210 mkfs: the filesystem is currently mounted.
\# mount -- /dev/hd5 is mounted on /var/tmp/blv
\# unmount /dev/hd5 -- could not find anything to unmount
\# unmount -f /var/tmp/blv -- successful
\# mkfs -V jfs /dev/hd5 -- successful
\# bosboot -a -d /dev/hdisk0 -- failed with state_func19[3] and
state_func19[9] /etc/umount not found
That part of the "bosboot" script shows:
umount $blvdev
That /etc/umount link was missing. We ran:
\# cd /
\# ln -s /usr/sbin/umount /etc/umount
\# bosboot -a -d /dev/hdisk0 -- original errors
\# mkfs -V jfs /dev/hd5 -- successful
\# bosboot -a -d /dev/hdisk0 -- successful
Since the "etc/umount" link was gone, the "bosboot" script
could not unmount /dev/hd5. The "bosboot" command must
have already been executed once, in order to mount /dev/hd5
and cause the above errors.
Support Line: bosboot fails with 0506-210 error ITEM: R5894L
Dated: February 1995 Category: N/A
This HTML file was generated 99/06/24~13:30:37
Comments or suggestions?
Contact us