Centos6.4下安裝5.6.42 MySQL Community Server (GPL)
環境:centos
一:首先配置一個靜態ip地址:
這裡採用的是:NAT模式下的靜態IP
1)虛擬機器聯網方式修改成NAT模式
2)進入虛擬機器的 /etc/sysconfig/network-scripts目錄
cd /etc/sysconfig/network-scripts
3)編輯檔案 vi ifcfg-ens33修改:
BOOTPROTO=staticONBOOT=yes
3.2 查詢理主機的VM8的網段 cmd 下:ipconfig
vmnet8: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
ether 00:50:56:c0:00:08
inet 192.168.19.1 netmask 0xffffff00 broadcast 192.168.19.255則我的物理主機的VM8的網段:192.168.19
3.3則ifcfg-ens33檔案中新增內容:最後新增以下內容
注意:網段跟物理主機的VM8的網段一致
IPADDR=192.168.19.26 //我們配置的靜態ip
NETMASK=255.255.255.0
GATEWAY=192.168.19.2 // 最後一位都為2
DNS1=192.168.19.2 // 跟GATEWAY一致即可。4.重啟閘道器 service network restart
5.ip addr
或者 ifconfig檢視ip是否變成我們配置的靜態ip地址6.ping www.baidu.com 檢視能否聯網。
二、Linux下安裝5.6.42 MySQL Community Server (GPL)
首先進入要安裝的位置:我的是/opt/install
cd /opt
mkdir install
cd install
1) wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm
如不能執行wget則,yum -y install wget
2) rpm -ivh mysql-community-release-el7-5.noarch.rpm
3) yum -y install mysql-server
[[email protected] install]# service mysqld restart //重啟mysql 或者/etc/rc.d/init.d/mysqld start
Redirecting to /bin/systemctl restart mysqld.service
[[email protected] install]# mysql --version
mysql Ver 14.14 Distrib 5.6.42, for Linux (x86_64) using EditLine wrapper
[[email protected] install]# mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.6.42 MySQL Community Server (GPL)
Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> use mysql;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> grant all privileges on *.* to 'root'@'%' identified by 'admin'; //修改密碼為admin
Query OK, 0 rows affected (0.00 sec)
mysql> flush privileges; //記住一定要重新整理
Query OK, 0 rows affected (0.00 sec)
mysql> select user,host,password from mysql.user; //檢視許可權
+------+-----------+-------------------------------------------+
| user | host | password |
+------+-----------+-------------------------------------------+
| root | localhost | |
| root | 127.0.0.1 | |
| root | ::1 | |
| | localhost | |
| root | % | *4ACFE3202A5FF5CF467898FC58AAB1D615029441 |
+------+-----------+-------------------------------------------+
5 rows in set (0.00 sec)
mysql> quit
Bye
[[email protected] install]# service mysqld restart
Redirecting to /bin/systemctl restart mysqld.service
[[email protected] install]# mysql -uroot -padmin -h192.168.19.60
Warning: Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 5
Server version: 5.6.42 MySQL Community Server (GPL)
Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> quit; //退出
Bye
如果mysql的客戶端連線不上則開放防火牆的埠
[[email protected] install]# firewall-cmd --permanent --add-port=3306/tcp
success
[[email protected] install]# firewall-cmd --permanent --add-port=22/tcp
success
[[email protected] install]# firewall-cmd --permanent --add-port=8066/tcp
success
[[email protected] install]# firewall-cmd --permanent --add-port=8080/tcp
success
[[email protected] install]# firewall-cmd --permanent --add-port=8090/tcp
success
[[email protected] install]# firewall-cmd --reload //記住一定要reload
success
其他設定:
檢視mysql開機自啟動設定情況
chkconfig mysqld on
(mysqld 0:off 1:off 2:on 3:on 4:on 5:on 6:off) ← 如果2--5為on的狀態就OK
停止mysql: service mysqld stop
相關推薦
Centos6.4下安裝5.6.42 MySQL Community Server (GPL)
環境:centos 一:首先配置一個靜態ip地址: 這裡採用的是:NAT模式下的靜態IP 1)虛擬機器聯網方式修改成NAT模式 2)進入虛擬機器的 /etc/sysconfig/network-scripts目錄 cd /etc/syscon
centos6.4下安裝python3.6.1
編譯 www logs strong file config pro 6.4 tps 1、安裝編譯環境所需包 #yum install zlib-devel bzip2-devel openssl-devel ncurese-devel gcc zli
Linux Redhat 4.4.7 安裝 8.0.13 MySQL Community Server
1.剛開始安裝mysql參考這個: https://blog.csdn.net/a116475939/article/details/74625377 2.修改密碼 mysql> use mysql; #先把密碼置為空字串;(不讓後面修改密碼會報錯) mysql> u
windows 安裝 5.7.23 MySQL Community Server的正確步驟,避免踩坑
1、從官網上下載,解壓 2、在根目錄下建立my.ini 檔案 相關屬性可自行配置 [mysql] # 設定mysql客戶端預設字符集 default-character-set=utf8 [mysqld] #設定3306埠 port = 3306 # 設定mysq
centos6.4下安裝Mycat-5.6.29-mycat-1.6-RELEASE-20161028204710
Mycat下載可以到官網下載也可以到github上下載 下載路徑: Mycat安裝 MyCat安裝,需要安裝jdk 上傳並解壓 把MyCat的壓縮包上傳到linux伺服器,並且解壓 安裝步驟 我的安裝在/usr/local 首先把你的進入你MyCat壓
Windows下手動搭建Apache 2.4.25+PHP 5.6.30+MySQL執行環境
雖然 Windows 平臺下有許多免費並且很優秀的PHP執行環境一鍵安裝包(例如:WAMP、AppServ、XAMPP、phpStudy),但是對於 PHP 新手來說,還是很有必要學會手動搭建PHP執行環境的。由於我當前的系統環境為 Windows 10 64位,所以我
centos6.7下安裝mysql5.6.22同時解決中文亂碼問題
系統服務 iptable nod -- 1.7 亂碼問題 dport 5.6 復制 1.下載 http://dev.mysql.com/downloads/mysql/ 或者使用wget下載: wget http://dev.mysql.com/get/Do
centos6.4下安裝mysql5.7.18
https chmod stat groupadd grep 內容 nload inf c-c 1、安裝前工作 在安裝前需要確定現在這個系統有沒有 mysql,如果有那麽必須卸載(在 centos7 自帶的是 mariaDb 數據庫,所以第一步是卸載數據庫)。 卸載系統自帶
linux-CentOS6.4下安裝oracle11g詳解
目錄: 1.前言 2.安裝環境 3.基本要求 4.修改linux核心配置(可省略) 5.安裝步驟 6.建立資料庫 7.建立監聽
centos6.4下安裝Tomcat7.0的問題
總結一下網上的原因: (1)防火牆是否關閉,參考http://blog.csdn.net/kergp/article/details/9136607 (2)沒有新增阿里雲安全組規則(碰到問題的哥們用的是阿里雲),參考http://bbs.csdn.net/topics/39
Linux下安裝mysql5.6.42報錯處理解決辦法
linux下安裝mysql的教程炒雞多,我就不寫了,自行百度。 說一下我今天安裝遇到的問題: 1、執行 ./scripts/mysql_install_db --user=mysql 後 報 FATAL
centos6.4版本安裝MySQL5.6版本
1.檢查是否安裝MySQL:rpm -qa|grep mysql 2.有強制解除安裝:rpm -e mysql-libs-5.1.73-8.el6_8.x86_64 --nodeps 3.建立使用者組和使用者 使用者組:groupadd mysql 使用者:use
Centos 5.7.21 MySQL Community Server set error list
5.7.21 MySQL Community Server 登陸mysql提示ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: YES)#vim /etc/my.cnf
CentOS7.4下使用通用二進制文件安裝MySQL Community Server 5.6.41
prevent 服務 password security 添加mysql用戶 用戶組 tmp 下使用 .cn 1、卸載自帶MySQL rpm -qa | grep mysqlrpm -e --nodeps mysql* 2、添加mysql用戶和用戶組 groupadd my
Centos7.4下安裝mysql-5.6.41
mys 但是 啟動mysql ann node 連接 rpm owin pack Centos7.4下安裝mysql-5.6.41二進制包 1、下載mkdir /data/sqlcd /data/sql wget https://cdn.mysql.com//Downloa
centOS6.4 原始碼安裝Mysql 5.6.39
1、關閉防火牆 service iptables stop chkconfig iptables off setenforce 0 vi /etc/selinux/config SELINUX=permissive 2、配置sysctl.c
CentOS6.4下Mysql數據庫的安裝與配置
商業 storage 不同的 pool use 速度 man aries ora 原文連接:http://www.cnblogs.com/xiaoluo501395377/archive/2013/04/07/3003278.html 說到數據庫,我們大多想到的是關系型數據
CentOS6.10下安裝mysql-5.7.24
odi mys 離線 命令 內容 ODB undle ida 限制 卸載原有mysql 因為mysql數據庫在Linux上實在是太流行了 所以目前下載的主流Linux系統版本基本上都集成了mysql數據庫在裏面 我們可以通過如下命令來查看我們的操作系統上是否已經安裝了mys
在CentOS6.4下使用Eclipse編譯執行MapReduce程式Hadoop2.6.5
本文是本人按照廈門大學林子雨老師的教程然後自己在使用Eclipse編譯執行MapReduce程式的時候所做的一個部落格教程,意在幫助更多的人。廈門大學林子雨老師的教程地址:http://dblab.xmu.edu.cn/blog/hadoop-build-project-using-ecli
CentOS6.5 下安裝Python3.6
CentOS 6.5上預設安裝的python版本是2.6.6,系統自帶的舊版本python被系統很多其他軟體環境依賴,不能解除安裝原Python,選擇Python3.6進行全新安裝。 1、首先先下載Python3.6的linux安裝包 2、root許可權登入Centos6