DA does not start by reboot automatically after error

@stephandek
We are having the same problem.
And did check all the settings that are mentioned above but this didn't solve the problem.

Did you find a solution ?
 
Hi JeroenM,

The problem can be solved by delaying the start of DA. (remove enabling directadmin on startup, then add it again and add it to the boot list later.) this solved my problem
 
I 'solved' it by editing /etc/systemd/system/directadmin.service

added to [Service]
Restart=on-failure

In the DA error.log i can see DA fails 3 times before a successful start.
 
I 'solved' it by editing /etc/systemd/system/directadmin.service

added to [Service]
Restart=on-failure

In the DA error.log i can see DA fails 3 times before a successful start.
Yups, I did the same. I see it trying to start 5 times.

Dec 9 18:12:34 xxx systemd[1]: directadmin.service: Scheduled restart job, restart counter is at 1.
Dec 9 18:12:35 xxx systemd[1]: directadmin.service: Scheduled restart job, restart counter is at 2.
Dec 9 18:12:35 xxx systemd[1]: directadmin.service: Scheduled restart job, restart counter is at 3.
Dec 9 18:12:35 xxx systemd[1]: directadmin.service: Scheduled restart job, restart counter is at 4.
Dec 9 18:12:36 xxx systemd[1]: directadmin.service: Scheduled restart job, restart counter is at 5.
 
I 'solved' it by editing /etc/systemd/system/directadmin.service

added to [Service]
Restart=on-failure

In the DA error.log i can see DA fails 3 times before a successful start.
I changed it to:

[Unit]
Description=DirectAdmin Web Control Panel
After=syslog.target network.target named.target

So it starts after named. This makes it start successfully the first time.
 
I changed it to:

[Unit]
Description=DirectAdmin Web Control Panel
After=syslog.target network.target named.target

So it starts after named. This makes it start successfully the first time.
So makes me think this might be a BUG? Does the setup.sh create this service file for sysd?
 
Here is what I have on Debian 10

Code:
cat /etc/systemd/system/directadmin.service
# DirectAdmin control panel
# To reload systemd daemon after changes to this file:
# systemctl --system daemon-reload
[Unit]
Description=DirectAdmin Web Control Panel
After=syslog.target network.target
Documentation=http://www.directadmin.com

[Service]
Type=forking
PIDFile=/run/directadmin.pid
ExecStart=/usr/local/directadmin/directadmin d
ExecReload=/bin/kill -HUP $MAINPID
WorkingDirectory=/usr/local/directadmin
LimitNOFILE=65535

[Install]
WantedBy=multi-user.target

So I need to add named.target
 
Here is what I have on Debian 10

Code:
cat /etc/systemd/system/directadmin.service
# DirectAdmin control panel
# To reload systemd daemon after changes to this file:
# systemctl --system daemon-reload
[Unit]
Description=DirectAdmin Web Control Panel
After=syslog.target network.target
Documentation=http://www.directadmin.com

[Service]
Type=forking
PIDFile=/run/directadmin.pid
ExecStart=/usr/local/directadmin/directadmin d
ExecReload=/bin/kill -HUP $MAINPID
WorkingDirectory=/usr/local/directadmin
LimitNOFILE=65535

[Install]
WantedBy=multi-user.target

So I need to add named.target
That's what I did. The network.target isn't very reliable since CentOS 8. I have to say that I just grep'ed the /var/log/messages file for 'Started', named was the last item, so I used that in the service file.
 
Back
Top