Home > Database > Mysql Tutorial > body text

Ubuntu 10.04 下关闭 MySQL 的开机启动

WBOY
Release: 2016-06-07 16:57:49
Original
1048 people have browsed it

网上什么用sysv-rc-conf配置,什么改S开头为K开头什么的方法通通的不管用,因为10.04把MySql的启动连接到了/lib/init/upstart-jo

网上什么用sysv-rc-conf配置,,什么改S开头为K开头什么的方法通通的不管用,因为10.04把MySql的启动连接到了/lib/init/upstart-job,而后者是调用了/etc/init/mysql.conf文件里面关于开机的定义,这是新的框架,所以以前的方法通通不管用了,你用sysv-rc-conf的时候甚至发现mysql更本禁止在任何runrevel上启动的,而实际情况是,它每次都很淡定地自动启动了

我们看/etc/init/mysql.conf里面的定义

start on (net-device-up
and local-filesystems
and runlevel [2345])
stop on runlevel [016]

从这里我们可以读到,runrevel为2345时,mysql是启动的,唯独016是不启动的

我比较狠,直接注释掉了启动的那行,而stop里面为0123456,哈哈

start on (net-device-up
and local-filesystems)
#      and runlevel [2345])
stop on runlevel [0123456]

linux

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template