suspend virtual servers during schedule backups

is it possible to suspend virtual servers that we want to make backup for, during schedule backups? or show a maintenance message. this prevent mysql queries during backup of important database.

What I do is use the “run command before backup” to rename the configuration file for the software packages I use to stop anything from happening, when the config file is “missing” it will show a default maintenance message.

what config file do you rename?
thanks

You could use the Virtualmin shell API to disable servers via the “run command before/after backup” feature. The command works like so:

[code]root@lyra:~# virtualmin disable-domain
No domain specified
Disables all features in the specified virtual server.

virtualmin disable-domain --domain domain.name
[–why “explanation for disable”][/code]

In the Virtualmin configuration, you can choose which features should get disabled when you make that call.

thank you Locutus but it will need to limit disable options to apache otherwise everything will be disable include mail server and dns. is there a way to add a code to main httpd conf file to redirect all traffic to a page?

As I wrote: In the Virtualmin configuration, you can choose which features should get disabled when you use the disable-domain function.