site enable and disable in apache ubuntu

$ sudo a2ensite domain.conf
$ sudo a2dissite domain.conf
$ sudo  systemctl reload apache2

Enable the site

Enable the site as follows:

sudo a2ensite

Disable the site

$ sudo a2dissite domain.conf

The output of the command is as follows:

Site installed; run /etc/init.d/apache2 reload to enable.

Run the recommended command:

sudo /etc/init.d/apache2 reload
sudo systemctl restart apache2.service

Leave a Reply