码迷,mamicode.com
首页 > 数据库 > 详细

装mysql + nginx

时间:2017-04-18 22:30:54      阅读:190      评论:0      收藏:0      [点我收藏+]

标签:11111

                 

[root@host ~]# yum -y install mysql-server mysql

..........................

[root@host ~]# rpm -q mysql-server  (查看是否安装和版本号)


[root@host ~]# yum list |grep mysql-server 

mysql-server.x86_64                    5.1.73-5.el6_6                    @abc  

[root@host ~]# service  mysqld start  

初始化 MySQL 数据库: WARNING: The host ‘host.tedu.cn‘ could not be looked up with resolveip.


[root@host ~]# service mysqld status

mysqld (pid  21119) 正在运行...

[root@host ~]# chkconfig mysqld on

[root@host ~]# chkconfig --list  mysqld 

mysqld          0:关闭 1:关闭 2:启用 3:启用 4:启用 5:启用 6:关闭


[root@host ~]# grep mysql /etc/passwd 

mysql:x:27:27:MySQL Server:/var/lib/mysql:/bin/bash


(自己连:)mysql -hlocalhost  -uroot -p (本机登也可 mysql)






wget http://nginx.org/packages/centos/6/noarch/RPMS/nginx-release-centos-6-0.el6.ngx.noarch.rpm



yum install nginx-release-centos-6-0.el6.ngx.noarch.rpm


yum install nginx

nginx 

[root@localhost ~]# netstat -anptu |grep :80 

tcp        0      0 0.0.0.0:80                  0.0.0.0:*                   LISTEN      5198/nginx     


本文出自 “12336621” 博客,请务必保留此出处http://12346621.blog.51cto.com/12336621/1917149

装mysql + nginx

标签:11111

原文地址:http://12346621.blog.51cto.com/12336621/1917149

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!