From 02e9ba54f9fa6e1eecee3642f01dc505d9df7d55 Mon Sep 17 00:00:00 2001 From: wangjunj <278884470@qq.com> Date: Thu, 28 Jan 2016 14:50:57 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=9C=AC=E5=9C=B0mysqld?= =?UTF-8?q?=E8=87=AA=E5=90=AF=E5=8A=A8=E6=9C=8D=E5=8A=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 添加数据库自启动服务。修复服务器重启后./server.sh start 会提示错误——“Starting jumpsever service:run_websocket.py not running” --- install/install.py | 1 + 1 file changed, 1 insertion(+) diff --git a/install/install.py b/install/install.py index 383bd5116..17dbc2d7c 100755 --- a/install/install.py +++ b/install/install.py @@ -101,6 +101,7 @@ class PreSetup(object): color_print('默认用户名: %s 默认密码: %s' % (self.db_user, self.db_pass), 'green') bash('yum -y install mysql-server') bash('service mysqld start') + bash('chkconfig mysqld on') bash('mysql -e "create database %s default charset=utf8"' % self.db) bash('mysql -e "grant all on %s.* to \'%s\'@\'%s\' identified by \'%s\'"' % (self.db, self.db_user,