# On Ubuntu
## Start command ##
systemctl start apache2.service
## Stop command ##
systemctl stop apache2.service
## Restart command ##
systemctl restart apache2.service
systemctl restart httpd.service
systemctl start httpd.service
systemctl stop httpd.service
sudo service apache2 start
sudo service apache2 restart
sudo service apache2 stop
OR
sudo /etc/init.d/apache2 start
sudo /etc/init.d/apache2 restart
sudo /etc/init.d/apache2 stop
sudo service apache2 stop
sudo systemctl stop apache2
Stop apache2 server
sudo /Applications/XAMPP/xamppfiles/bin/apachectl start