how does directadmin monitor services?

mta

Verified User
Joined
Apr 17, 2008
Messages
33
Location
Georgia, US
I'm not sure I'm posting this to the correct forum, but here goes.

How does directadmin check for running services?

I'm guessing that maybe it looks for a pid file, extracts the process id, and then checks to see if it's running. Is this accurate?

If so, are these pid file paths hardcoded into the directadmin binary? ( I'm assuming so ) - and may they be specified in directadmin.conf?

Thanks!
 
I don't quite understand...

Is it supposed to be using the 'status' argument of the init scripts?

The status argument gives me an error this is the status, ie job control command, not some previously defined function.

What exactly does the directadmin binary expect to get back from the script?

Certain return value or a specific string?

Thanks!
 
Since I've set exim's pid file back to /var/run/exim.pid ( I suppose where directadmin expects it to be ), it has stopped trying to restart the service.

It is still trying to restart apache, however, despite the pid file being present at /var/run/httpd.pid. I'm guessing this may be because the process name is apache2, not httpd.

Any ideas on how to circumvent this?

Thanks!
 
I'm using OS supplied binaries for all daemons, and so far this is the only issue I've run into.

I understand that this method of installation is unsupported, but I still figure it can't hurt to ask for tips in the forum here and there. I also figure I can't be the only one who's tried this.

My goal is to achieve a fully automated installation process using all OS supplied software with the exception of the two precompiled directadmin binaries.
 
I hated to do it, but it was easy enough. Created a symlink from /usr/sbin/apache2 to /usr/sbin/httpd and changed /usr/sbin/apache2 to /usr/sbin/httpd in the apache2ctl script.

Looks like that resolved the issue.
 
Hello,

DirectAdmin uses the output from /proc to see what programs are running. The name of the running program is what matters.

you can change the name's of the programs DA checks by editing:
/usr/local/directadmin/data/admin/services.status

but for restarts, etc DA will still be calling "httpd", so you'd have to link the boot script.

John
 
Back
Top