- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- System 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
08-13-2002 11:22 AM
08-13-2002 11:22 AM
System reboot
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2002 11:27 AM
08-13-2002 11:27 AM
Re: System reboot
What you are thinking of are the KILL scripts in /sbin/rc?.d. If you want to add something to the shutdown you will have to create a new shutdown script that gets exectued at the appropriate run level.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2002 11:29 AM
08-13-2002 11:29 AM
Re: System reboot
Follow the model of start files named with "S" as the first char. Also include handling for parameters "start_msg" and "start".
If you need this at shutdown as well, another link with "K" as the first char, and handling for "stop_msg" and "stop".
Tom
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2002 11:30 AM
08-13-2002 11:30 AM
Re: System reboot
HTH
Marty
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2002 11:45 AM
08-13-2002 11:45 AM
Re: System reboot
1) /sbin/init.d/yourprogram
==> Make use of the file "template" in /sbin/init.d to customize your startup/shutdown program script.
2) /sbin/rc[0->4].d
==> Depending on at which run level you want your program to startup/shutdown. Create the appropriate symbolic link back to /sbin/init.d/yourprogram. For example to start at run level 3, you would ..
S999->/sbin/init.d/yourprogram
and to stop at run level 2, you would ..
K099->/sbin/init.d/yourprogram
3) /etc/rc.config.d/yourprogram
==> Not actually the same file but rather the file that has the CONTROL_VARIABLE defined, so that to disable/enable the script you can simply turn the 0 or 1 bit. This var is checked everytime /sbin/init.d/yourprogram runs.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2002 12:00 PM
08-13-2002 12:00 PM
Re: System reboot
The noraml level after the system reboots is 3 , so to include the files like you do in autoexec.bat you need to put the files in /sbin/init.d and link to /sbin/rc3.d
Manoj Srivastava
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2002 12:05 PM
08-13-2002 12:05 PM
Re: System reboot
The scripts are placed in /sbin/init.d
then you link to them from /etc/rcN.d
Typically you'll put the script you want to run at boot in /etc/rc3.d with the following naming convention.
/etc/rc3.d/SNNNyourscriptname
where NNN is a number between 001-999
The system executes them in alpha order so S001abc runs before S999abc.
If you want a script to run at shutdown you'll put it in /etc/rc2.d with the following naming convention.
/etc/rc2.d/KNNNyourscriptname
You link the script using the follwing command.
ln -s /sbin/init.d/yourscriptname /etc/rc3.d/SNNNyourscriptname
HTH
Sean
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2002 12:15 PM
08-13-2002 12:15 PM
Re: System reboot
This discusses the methodology of doing exactly this.,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-14-2002 10:17 AM
08-14-2002 10:17 AM
Re: System reboot
/sbin/init.d/boot.alert
(the script file)
/sbin/rc3.d/S400boot.alert
(a link to the script file)
When my system reboots, I get the email page, but I get it twice.
Not sure why I get it twice.