- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: How do you determine the current boot path/dev...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 01:58 PM
тАО11-16-2010 01:58 PM
I've run through some of the easy ones such as setboot, lvlnboot and checking syslog.
None of them give the current boot device.
Right at the start of boot on the console it lists the starting boot path but I would have to be looking at the console during boot to catch that.
This seemed like a simple thing to me when I was asked but the answer has been more elusive than I originally thought.
Thanks,
Travis
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 02:06 PM
тАО11-16-2010 02:06 PM
Re: How do you determine the current boot path/device
MODEL=`uname -m`
if [[ $MODEL = "ia64" ]]
then
echo "--- IA64 System ---"
echo "Syslog says"
grep Boot /var/adm/syslog/syslog.log
echo "\nkcpath says:"
kcpath
echo "\nADB from /stand/vmunix says:"
MINOR=`echo "bootdev/x"|adb /stand/vmunix /dev/kmem|awk 'NR == 2 {print $1}'|cut -c 5-10`
echo "\n$MINOR Translated to:"
ls -l /dev/dsk/|grep $MINOR
DEV=`ls -l /dev/dsk|awk '/'$MINOR'/ {print $10}'`
echo "Boot device is: \c"
lssf /dev/dsk/$DEV|awk '{print $15" "$16}'
else
echo "--- PA-RISC System ---"
echo "\nADB from /stand/vmunix says:"
echo boot_string/S|adb /stand/vmunix /dev/mem
echo "\nkmpath says:"
kmpath
fi
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 02:11 PM
тАО11-16-2010 02:11 PM
Re: How do you determine the current boot path/device
echo "boot_string/S" | adb -k /stand/vmunix /dev/kmem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 06:31 PM
тАО11-16-2010 06:31 PM
Solutionbootstring using adb:
Last booted using disk(0/0/2/0.6.0.0.0.0.0;0)/stand/vmunix
Boot disks and AUTO file boot command:
/dev/dsk/c1t6d0
BootCommand: "hpux -lq"
/dev/dsk/c2t6d0
BootCommand: "hpux -lq"
boot PATHS:
Primary bootpath = 0/0/2/0.6.0, /dev/dsk/c1t6d0
(disk) SEAGATE ST318404LC
Alternate bootpath = 0/0/1/0.0.0, /dev/rmt/0mn
(tape) HP C1537A
Automatic boot settings from setboot:
Autoboot is ON (enabled)
Autosearch is OFF (disabled)
lvlnboot -v:
Boot Definitions for Volume Group /dev/vg00:
Physical Volumes belonging in Root Volume Group:
/dev/dsk/c1t6d0 (0/0/2/0.6.0) -- Boot Disk
/dev/dsk/c2t6d0 (0/0/2/1.6.0) -- Boot Disk
Boot: lvol1 on: /dev/dsk/c1t6d0
/dev/dsk/c2t6d0
Root: lvol3 on: /dev/dsk/c1t6d0
/dev/dsk/c2t6d0
Swap: lvol2 on: /dev/dsk/c1t6d0
/dev/dsk/c2t6d0
Dump: lvol2 on: /dev/dsk/c1t6d0, 0
===========================================
bootstring using adb:
Last booted using 0x1000004 (disk5 or c0t0d0)
Boot disks and AUTO file boot command:
/dev/disk/disk5_p2
BootCommand: "hpux"
/dev/disk/disk10_p2
BootCommand: "hpux"
boot PATHS:
Primary bootpath = 0/1/1/0.0.0.0.0, /dev/rdsk/c0t0d0
= 0/1/1/0.0x5000c50007153089.0x0, /dev/rdisk/disk5
= (disk) 64000/0xfa00/0x1
Alternate bootpath = 0/1/1/0.0.0.1.0, /dev/rdsk/c0t1d0
= 0/1/1/0.0x5000c50007141ad5.0x0, /dev/rdisk/disk10
= (disk) 64000/0xfa00/0x0
HA Alt bootpath = 0/1/1/0.0.0.1.0, /dev/rdsk/c0t1d0
= 0/1/1/0.0x5000c50007141ad5.0x0, /dev/rdisk/disk10
= (disk) 64000/0xfa00/0x0
Automatic boot settings from setboot:
Autoboot is OFF (disabled)
lvlnboot -v:
Boot Definitions for Volume Group /dev/vg00:
Physical Volumes belonging in Root Volume Group:
/dev/disk/disk5_p2 -- Boot Disk
/dev/disk/disk10_p2 -- Boot Disk
Boot: lvol1 on: /dev/disk/disk5_p2
/dev/disk/disk10_p2
Root: lvol3 on: /dev/disk/disk5_p2
/dev/disk/disk10_p2
Swap: lvol2 on: /dev/disk/disk5_p2
/dev/disk/disk10_p2
Dump: lvol2 on: /dev/disk/disk5_p2, 0
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-16-2010 11:18 PM
тАО11-16-2010 11:18 PM
Re: How do you determine the current boot path/device
We can find currently from which boot disk the server is booted as below
# uname -a
HP-UX rx26-185 B.11.31 U ia64 3025899524 unlimited-user license
[rx26-185]/
# dmesg | grep -i boot
Boot device's HP-UX HW path is: 0.1.1.1.2.0
[rx26-185]/
# ioscan -fnH 0.1.1.1.2.0
Class I H/W Path Driver S/W State H/W Type Description
=====================================================================
disk 3 0/1/1/1.2.0 sdisk CLAIMED DEVICE HP 73.4GST373454LC
/dev/dsk/c3t2d0 /dev/dsk/c3t2d0s2 /dev/rdsk/c3t2d0 /dev/rdsk/c3t2d0s2
/dev/dsk/c3t2d0s1 /dev/dsk/c3t2d0s3 /dev/rdsk/c3t2d0s1 /dev/rdsk/c3t2d0s3
[rx26-185]/
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-17-2010 06:49 AM
тАО11-17-2010 06:49 AM
Re: How do you determine the current boot path/device
On 11.31, the command "lvlnboot -v" shows you the current boot device, root, swap and dump.
regards
Emmanuel
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-17-2010 07:22 AM
тАО11-17-2010 07:22 AM
Re: How do you determine the current boot path/device
Simple ...
#dmesg | grep HW
Regards,
Sooraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-17-2010 07:37 AM
тАО11-17-2010 07:37 AM
Re: How do you determine the current boot path/device
This is not very reliable. dmesg is a small buffer in kernel memory and old information is erased to make room for new messages. The boot path information in dmesg is only valid right after you boot...several weeks from now, it can disappear.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-23-2010 08:04 AM
тАО11-23-2010 08:04 AM
Re: How do you determine the current boot path/device
Most of the methods mentioned do work on RISC but not on Itanium.
I've still not found a reliable way to get the information from an Itanium box.
Sometimes syslog catches it but about 50% of the time it doesn't.
I thought at one point I might be able to change when syslogd starts so it would reliably capture the boot path but I haven't had time to work it in the last week.
Bill - I may give you a call directly about this, I'm the same Travis Harp with Northrop who bugs you from time to time.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-23-2010 08:30 AM
тАО11-23-2010 08:30 AM
Re: How do you determine the current boot path/device
I just have my observation here about the OS disks and I have checked few HP ux servers with root disk mirroring.
I have executed sar & iostat command which shows comparably higher io on the presently used disk than the mirror. Based on this output I confirmed that the system is using the disk having higher io activity.
sar -d 5 5
See if this works for you too. This is purely based on what I observed on few HP-UX servers and I would appreciate if somebody have their objections/ comments/observations
on what I have here.
Thanks & Regards
Jayakrishnan G Naik