When you stop Xampp in your linux system and you may get an error, XAMPP Stopping Apache fail apachectl returned 1.

I have searched solution in few websites and blogs but did not get any way. Finally analysed the lampp script,

May be your mysql softlink has been crashed when starting the XAMPP so you need to check that link,

# /opt/lampp/lampp start

Starting XAMPP for Linux 1.8.3-5...
XAMPP: Starting Apache...already running.
XAMPP: Starting MySQL...already running.
XAMPP: Starting ProFTPD...already running.

The HTTPD, MySQL  and proFTPD does not running and tried to stop the services,
# /opt/lampp/lampp stop 

Stopping XAMPP for Linux 1.8.3-5...
XAMPP: Stopping Apache...fail.
apachectl returned 1.
XAMPP: Stopping MySQL...ok.
XAMPP: Stopping ProFTPD...kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
kill returned 1.

Soluton :

Once restared the system the Apache started but MySQL shows same error, open the lampp script file
# vim /opt/lampp/lampp
 $XAMPP_ROOT/bin/mysql.server start > /dev/null &
#  cd /opt/lampp/bin

# ls -al mysql.server
lrwxrwxrwx 1 root root 27 Jan  3 16:11 mysql.server -> ../share/mysql/mysql.server
# cd  /opt/lampp/bin

remove the softlink and create a new one
# rm -rf  mysql.server

 ln -s /opt/lampp/share/mysql/mysql.server   /opt/lampp/bin/mysql.server

Finally, restart Xampp all services and check on process status using ps command,
# ps aux | grep mysql

# ps aux | grep httpd