To autostart services in Centos or Redhat OS, you can use builtin chkconfig utility. It is located in /sbin directory. If you are a regular user (non-root), then /sbin may not be in your path. Therefore, you may have to use the full path to access the chkconfig utility.
To auto start a new service:
- Find out the name of service’s script from /etc/init.d/ directory e.g. mysqld or httpd
- Add it to chkconfig
sudo /sbin/chkconfig --add mysqld
- Make sure it is in the chkconfig.
sudo /sbin/chkconfig --list mysqld
- Set it to autostart
sudo /sbin/chkconfig mysqld on
To stop a service from auto starting on boot
- sudo /sbin/chkconfig mysqld off
This page has been readed 3485 times
If you find that the post was helpful, pay me a beer!!!
Related Articles
Task: List the contents of a tar file Use the following command: $ tar -tvf file.tar Task: List the contents of a tar.gz file Use the following command: $ tar...
Put this code in your plugin function your_css_and_js() { wp_register_style('your_css_and_js', plugins_url('style.css',__FILE__ )); wp_enqueue_style('your_css_and_js'); wp_register_script( 'your_css_and_js', plugins_url('your_script.js',__FILE__ )); wp_enqueue_script('your_css_and_js'); } add_action( 'admin_init','your_css_and_js'); if you need to add it to theme, then...
This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License As the world’s most high-profile and most powerful virtualization solution (virtual machine), VMware Workstation 11 has been officially...