Basic apache2 command’s

--

Starting Apache- sudo systemctl start apache2 -

Instead of manually starting the Apache service-sudo systemctl enable apache2 -

Stopping Apache quickly shut down — sudo service apache2 stop —
sudo systemctl stop apache2

Restart apache2 — sudo systemctl restart apache2
sudo service apache2 restart

To reload Apache,— sudo systemctl reload apache2
sudo service apache2 reload

Test the Apache configuration — sudo apachectl -

To check the status of the Apache — sudo systemctl status apache2

Check Apache Version-sudo apache2 -v

sudo apache2 -V — The -V (uppercase) option shows the Apache version along with the configure option.

--

--