- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Hostname after reboot
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
Forums
Discussions
Discussions
Discussions
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
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
06-30-2004 01:15 AM
06-30-2004 01:15 AM
Hostname after reboot
I have a L1000 running HPUX 11.0 that looses its hostname after a reboot. The script /sbin/init.d/hostname gets deleted sometime during the reboot. Hostname OK in /etc/hosts and netconf. DNS resolves alias and FQ hostname 100%. swagentd seems to be unhappy about the hostname in the rc.log file but no errors in syslog - hostname shown as unknown from start of boot in syslog.
Any suggestions appreciated.
Thanks
Greg
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 01:20 AM
06-30-2004 01:20 AM
Re: Hostname after reboot
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 01:21 AM
06-30-2004 01:21 AM
Re: Hostname after reboot
find /sbin/init.d -exec grep "hostname" {} \;
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 01:21 AM
06-30-2004 01:21 AM
Re: Hostname after reboot
To fix your /sbin/init.d/hostname file from being deleted probably requires a patch install.
live free or die
harry
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 01:22 AM
06-30-2004 01:22 AM
Re: Hostname after reboot
it is very strange.
I would suggest you to set hostname by set_parms command:
#/sbin/set_parms hostname
and reboot.
Anyway what is the exact message from swagentd?
Best regards,
Ettore
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 01:22 AM
06-30-2004 01:22 AM
Re: Hostname after reboot
find /sbin/init.d -exec grep -l "hostname" {} \;
/sbin/init.d
/sbin/init.d/hostname
/sbin/init.d/nfs.core
/sbin/init.d/swconfig
/sbin/init.d/swagentd
/sbin/init.d/dce
/sbin/init.d/sendmail
/sbin/init.d/nis.client
/sbin/init.d/nis.server
/sbin/init.d/nisplus.server
/sbin/init.d/comsec
/sbin/init.d/vt
/sbin/init.d/vxvm-reconfig
/sbin/init.d/vxvm-rootreconfig
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 01:24 AM
06-30-2004 01:24 AM
Re: Hostname after reboot
make sure host name is there...
When you re-create /sbin/init.d/hostname - what permissions?
ll /sbin/init.d/hostname
-r-xr-xr-x 1 bin bin 908 Nov 14 2000 /sbin/init.d/hostname
Rgds...Geoff
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 01:24 AM
06-30-2004 01:24 AM
Re: Hostname after reboot
I suggest to bootstrap the host step by step, checking the rc file at every step to isolate the script causing the problem.
Boot in single mode and check the existance of file, then init 1 and check, init 2 and check.
Also could be reasonable to perform a full file system check, the problem is that is not so simple to do it on root file system, to which /sbin belongs. I suggest to start the host with the Support CDROM in recovery shell and fsck the root file system from there with the flag -o full
Hope this help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 02:19 PM
06-30-2004 02:19 PM
Re: Hostname after reboot
/etc/rc.config.d/netconf
/etc/hosts
and then
# export HOSTNAME=hostname
# echo $HOSTNAME
check the hostname is correct.
and then logout. login.
Another Method is
# set_parms hostname
modify your hostname and reboot.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 03:16 PM
06-30-2004 03:16 PM
Re: Hostname after reboot
One another thing to check is to see if you have any backup netconf files in /etc/rc.config.d/ directory. Every file in that directory will be 'sourced' in during the start-up. To verify it, do
$cd /etc/rc.config.d
$grep -i hostname *
You shouldn't see any file other than netconf in the above output.
-Sri
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 08:17 PM
06-30-2004 08:17 PM
Re: Hostname after reboot
Netconf hostname 100%, etc/hosts 100% as per orig post. /sbin/init.d/hostname file replaced after reboot with correct perm. and owner. Hostname configured after reboot but the same happens at next boot. Have searched /sbin/init.d with cmd: cd /sbin/init.d
find . -type f | xargs grep -i "hostname"
and then gone through each file returned to see if it could cause this. No luck..
Extracts from rc.log
Configuring all unconfigured software filesets
Output from "/sbin/rc2.d/S120swconfig start":
----------------------------
* Turning off all network based resolving services in
'/etc/nsswitch.conf'
* Setting up temporary hostname in '/etc/hosts'
* Restoring '/etc/hosts' to its original contents.
* Restoring '/etc/nsswitch.conf' to its original contents
This seems OK but ......
Starting mail daemon
Output from "/sbin/rc2.d/S540sendmail start":
----------------------------
WARNING: local host name (unknown) is not qualified; fix $j in config file
/etc/mail/aliases: 6 aliases, longest 9 bytes, 76 bytes total
sendmail
Initialize Software Distributor agent daemon
Output from "/sbin/rc2.d/S870swagentd start":
----------------------------
Running /usr/lib/sw/mx/configure to reset hostname.
NOTE: Can not find fully qualified hostname with nslookup. Using unknown.
ERROR: Failed to package AgentConfig into /var/opt/mx/depot11.
swpackage did not run or produced no output.
ERROR: Failed to package AgentConfig into /var/opt/mx/depot10.
swpackage did not run or produced no output.
WARNING: Could not properly configure SD into ServiceControl.
You may try again later by running /usr/lib/sw/mx/configure.
"/sbin/rc2.d/S870swagentd start" FAILED
....................................
I am getting the idea something in the K scripts may be the problem????Just a guess
Thanks all
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 08:21 PM
06-30-2004 08:21 PM
Re: Hostname after reboot
what is in the /etc/nsswitch.conf ?
Robert-Jan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-30-2004 08:37 PM
06-30-2004 08:37 PM
Re: Hostname after reboot
Can you should us the output of:
/usr/sbin/swlist -l fileset -a state | egrep -v "^$|#|configured"
Regards
Jov
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-01-2004 09:10 PM
07-01-2004 09:10 PM
Re: Hostname after reboot
hostname should be run on runlevel 1, in my installation START ORDER NUMBER is 320. You should see in /etc/rc.log something like:
Setting hostname
Output from "/sbin/rc1.d/S320hostname start":
----------------------------
If u have this message the file exists at boot: the problem is BETWEEN run level1 and end of rc, if not the problem could be during shutdown or from power up till runlevel 1
Another way is to start in single user mode? (hpux -is at the ISL prompt)
In single mode the file /sbin/init.d/hostname exists or not?
If it does NOT exist the problem is:
1. execing rc script during SHUTDOWN not STARTUP
2. some script BEFORE rc is started at startup, see the lines in /etc/inittab BEFORE rc
If it exists the problem is execing some rc script during startup or some script AFTER rc (again see /etc/inittab)
In case the problem is caused by rc i suggest again to run step by step checking the existance of the file every time. U can start the host in single user mode and do by hand the work of rc:
go through the run level directories (/sbin/rc1.d, /sbin/rc2.d, etc...) and run in the order indicated by number each script named S* with argument start
eg.
/sbin/rc1.d/S080crashconf start
/sbin/rc1.d/S100localmount start
every time looking if /sbin/init.d/hostname still exists
if the problem is during shutdown do the same things backwards from current level (who -r) to run level 1, following link named K*
/sbin/rc3.d/K100dtlogin.rc stop
/sbin/rc2.d/K080apache stop
always checking after each execution the /sbin/init.d/hostname file
Seems to me that other problems reported are obvious consequence to this error: hostname MUST be set up for the system to work properly.
Hope this helps