Operating System - Linux
1830165 Members
6380 Online
109999 Solutions
New Discussion

Re: startup script get executed but process is not running

 
sofian wijaya
New Member

startup script get executed but process is not running

Hi there,

I am running Documentum product. We put the product start-up into our startup script at run level 3.

I monitor the server during boot up. And notice the following (same result as in /var/adm/rc.log)

1. Documentum script is executed
2. A process ID is created
3. Documentum log file said that it is started with the process id as mentioned above
4. Next i run ps - ef |grep docbroker (docbroker should be the process name created)

Then, the magic started ... I could not find the process. Try to grep the process id also return nothing.

Go back to /var/adm/rc.log, i could not find any line to say that process being terminated.

check on the syslog also couldnt find why the process is not there.

Thanks
8 REPLIES 8
Steven E. Protter
Exalted Contributor

Re: startup script get executed but process is not running

Just to review the process....

cd /sbin/rc3.d

or for linux

cd /etc/rc3.d
ln -s /etc/init.d/docscript S99doc #linux
ln -s /sbin/init.d/docscript S99doc #hpux

Now if thats okay then

check the docscript or whatever it is named.

Right after the line that actually starts the daemon,add this code....
rc=$?
echo "return code doc $rc" >> /var/adm/rc.log

If you get a zero, the script is executing all right and the problem is the daemon or deamon configuration. If you get an error you have an start time error and need to figure out whats happening and why its not starting right.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Ragu_3
Trusted Contributor

Re: startup script get executed but process is not running

I think the daemon process is segfaulting. Can you run strace and pipe its output to debug on the 'docbroker' binary?
Debian GNU/Linux for the Enterprise! Ask HP ...
sofian wijaya
New Member

Re: startup script get executed but process is not running

hi there,

i've checked the return value of the script is 0.

when you say something wrong with daemon configuration, what does it mean? any idea how to solve this?

thanks
Muthukumar_5
Honored Contributor

Re: startup script get executed but process is not running

Change the check on script as,

1> Execute on command line on the shell as

/sbin/init.d/script start

2> Stop and Execute it with debugging mode set -x

( put set -x on the second line after shell inclusion of #! there to get debugging informations )

/sbin/init.d/script start

3> Execute that script in background so that monitor that script's PID with ps for some time.

4> Check weather is there any core file formed there.

Note: Do everything on user terminal execution. No need to boot and test it there.

Send that information to us to further analyse the problem.
Easy to suggest when don't know about the problem!
Mei Jiao
Respected Contributor

Re: startup script get executed but process is not running

Hi,

I think this is on HP-UX server, though this is from Linux category.

When you say the problem may be due to daemon or daemon configuration, or the daemon may be segfaulting, may I know if the daemon is referring to the docbroker process or the HP-UX start-up process (as I never heard of daemon from HP-UX start-up process)?

Btw Sofian, do you encounter any problem if you run the script manually? For eg: /sbin/init.d/script start
sofian wijaya
New Member

Re: startup script get executed but process is not running

when i start the script manually, all the processes would be up and running fine.
Muthukumar_5
Honored Contributor

Re: startup script get executed but process is not running

Did you try all the way, in my prev. mail there.

Try to stop the started daemon and try as,

sh -x /sbin/init.d/script start
what are you getting there.

Did you get any related informations to problem there.

Second try as,

Edit the script as,
set -x in the second line after shell preprocessor #! there.

Reboot system and see what is in the rc.log file there. Send it.

Note: If you send more informations and test results so that you will get successful suggestion from ITRC forums.

HTH.
Easy to suggest when don't know about the problem!
sofian wijaya
New Member

Re: startup script get executed but process is not running

Hi there,

I havent tried, because i dont have any physical access or remote access from my office. I will try doing this tomorrow and revert back to you :)

Thanks so much for your help