AutoRun McMyAdmin at reboot/start (Linux/Ubuntu)

1. Login as root, create a file as
vim /etc/init.d/McMyAdmin.sh
2. Copy and paste the following content into it

Pleae note that you need to adjust the USERNAME and MCAPATH.
3. :wq to save and quit
4. Change the mode of the file
chmod +x /etc/init.d/McMyAdmin.sh
5. create soft link to startup
update-rc.d McMyAdmin.sh defaults 99
Note that you can remove it by
update-rc.d -f McMyAdmin.sh remove
6. reboot to test.
7. If it is not work, try to run as root, with the following command
/etc/init.d/McMyAdmin start

发表评论