六狼论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博账号登陆

只需一步,快速开始

搜索
查看: 117|回复: 0

linux下启动MYSQL服务器以及配置自启动命令

[复制链接]

升级  42.67%

30

主题

30

主题

30

主题

秀才

Rank: 2

积分
114
 楼主| 发表于 2013-2-7 20:31:20 | 显示全部楼层 |阅读模式
/usr/local/mysql/bin/mysqld_safe --user=mysql&
注意MYSQL安装目录

配置自启动

通过vi /etc/rc.local
常见命令

#!/bin/sh
#
# This script will be executed *after* all the other init scripts.
# You can put your own initialization stuff in here if you don't
# want to do the full Sys V style init stuff.

touch /var/lock/subsys/local
/usr/local/apache/bin/apachectl start
/usr/local/mysql/bin/mysqld_safe --user=mysql &
mount -t nfs 192.168.0.85:/var/www/html/cache /var/www/html/cache

本博所有文章均为原创,欢迎转载,转载请注明出处。
作者:robin@飞鸟智能手机软件
链接:http://www.17ppc.com
您需要登录后才可以回帖 登录 | 立即注册 新浪微博账号登陆

本版积分规则

快速回复 返回顶部 返回列表