Directadmin: Cannot find the script

I was having some problems on different servers when i tried to reload a service.

It was displaying “Cannot find the script” for all services

This probably started when we upgraded to CB 2.0….

Anyhow you can fix this by editing the “/usr/local/directadmin/conf/directadmin.conf” and change/add the following value to: systemd=1

Reload DirectAdmin afterwords and you should be able to restart services from directadmin again.

 

Reset per e-mail account usage limit in DirectAdmin

Since DirectAdmin works with ‘per e-mail account send limits’ some things can work out pretty annoying.

In this case the customer sent 1000 e-mails (not SPAM) and want to send e-mail number 1001. But, changing the limit to 2000 will result in a

Please set a limit between 1 and 1000

Despite the fact of the “Zero is unlimited”, if you enter 0 it will give:

You cannot set an unlimited send limit

So I ended up to search in the files and remove the usage by hand:

rm -f /etc/virtual/domain.com/usage/info

Now the usage is removed and the customer is able to send another 1000 e-mails. Which still is not solved but for now it’s done.

DirectAdmin SQL back-ups via commandline

This is how to make a SQL only back-up via commandline in DirectAdmin. The first line puts the command in the task.queue. The second line runs the task queue and will show the output. The d400 means debug level 400.

echo "action=backup&append%5Fto%5Fpath=nothing&database%5Fdata%5Faware=yes&email%5Fdata%5Faware=yes&local%5Fpath=%2Fhome%2Fadmin%2Fmysql%5Fbackups&option%30=database&option%31=database%5Fdata&owner=admin&type=admin&value=multiple&what=select&when=now&where=local&who=all" >> /usr/local/directadmin/data/task.queue
/usr/local/directadmin/dataskq d400

When the back-up is completed you will receive an e-mail via the normal DirectAdmin message system.

The back-ups will be stored in /home/admin/mysql_backups