//you have to stop the Apache2 and MySQL. $sudo /etc/init.d/apache2 stop $sudo /etc/init.d/mysql stop //And then restart Xampp server $sudo /opt/lampp/lampp restart