1752795 Members
5765 Online
108789 Solutions
New Discussion юеВ

Re: startup script

 
sh5490
Frequent Advisor

startup script

hi
we re using dbora script for starting,stoping
listners and dtbse.
While running under root user it work fine

we want execute this script on server startup
for this we have created soft link under
/sbin/rc1.d & rc2.d like

bash-3.2# pwd

/sbin/rc2.d
bash-3.2# ls -l S99dbora
lrwxr-xr-x 1 root sys 18 Apr 25 23:05 S99dbora -> /sbin/init.d/dbora

bash-3.2# pwd
/sbin/rc1.d
bash-3.2# ls -l K100dbora
lrwxr-xr-x 1 root sys 18 Apr 25 23:04 K100dbora -> /sbin/init.d/dbora

this didn't work?

pls provide some input to resolve the issue

thanks
shabir

66 REPLIES 66
Ivan Krastev
Honored Contributor

Re: startup script

Common issue for this is missing PATH to the commands.
If you execute the scrips as any user you have a path to used in script binaries.

Use full patch in script - like /usr/bin/ping

or set PATH with appropriate values.


regards,
ivan
MarkSyder
Honored Contributor

Re: startup script

Please provide the output of:

ls -l /sbin/init.d/dbora

You should note that scripts have to be shut down in the reverse order to that in which they are started. To achieve this, you should make sure your K and S numbers add up to 1000.

Mark Syder (like the drink but spelt different)
The triumph of evil requires only that good men do nothing
Patrick Wallek
Honored Contributor

Re: startup script

>>this didn't work?

Well, that's not real helpful. What didn't work? Did you get any error messages? Was anything displayed on the console during the reboot? Did you check the /etc/rc.log file to see if there were any messages there?

Jeeshan
Honored Contributor

Re: startup script

Hi Shabir

Try to put it in rc3.d directory. and restart the server.
a warrior never quits
Yogeeraj_1
Honored Contributor

Re: startup script

hi Shabir,

this seems to be a known issue. Try above run-level 2.

hope this helps!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Yogeeraj_1
Honored Contributor

Re: startup script

hi again,


please refer to metalink note: 1074016.6 - 'dbora' does not work on Redhat linux.

Solution:
You will need to change the link to run level 3.

From:
ln -s /sbin/init.d/dbora /sbin/rc2.d/S99dbora

To:
ln -s /sbin/init.d/dbora /sbin/rc3.d/S99dbora


Explanation:
Linux uses run level 3 instead of run 2 by default for multi-user access.



hope this helps!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
sh5490
Frequent Advisor

Re: startup script

hi all/yoograj,

We have executed it on rc3.d run level
but it didn't work.

also we are using hp ux 11.23 version

thanks

shabir
Yogeeraj_1
Honored Contributor

Re: startup script

hi Shabir,

Any error messages in the rc.log?

revert!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
sh5490
Frequent Advisor

Re: startup script

hi yooograj,

there seems no message related dbora stratup

thanks

shabir