In an earlier post, we had shown how to install XAMPP on Mint.
Once installed, XAMPP needs to be started manually after every PC restart with the long command sudo /opt/lampp/lampp start.
But there is a way to avoid this so that XAMPP can be started automatically every time system is restarted. To do this, we can simply add the command that is entered every time to start XAMPP in an initialization script which makes sure that it is run every time system is restarted.
Here is how :
1. Navigate to the following path : /etc and locate the file rc.local
2. Right click it and select Open as administrator ( or open any text editor like vi with root privileges) which will bring up the below window for it to be edited using gedit :
3. Add the line /opt/lampp/lampp start as shown and save the file.
4. Restart Mint and once logged on, open a browser and type http://localhost which should now show the XAMPP home page directly.
There you go, no more typing of the long command to get XAMPP working every time Mint is rebooted.