站長資訊網
        最全最豐富的資訊網站

        MySQL安裝常見報錯處理(總結分享)

        本篇文章給大家帶來了關于mysql的相關知識,其中主要整理了安裝常見報錯處理的相關問題,包括了無法啟動處理,錯誤1053、Winwods安裝初始化報錯、MySQL8安裝后無法登陸等等內容,下面一起來看一下,希望對大家有幫助。

        MySQL安裝常見報錯處理(總結分享)

        推薦學習:mysql視頻教程

        1.無法啟動處理,錯誤1053

        Windows 無法啟動Mysql服務 錯誤1053:服務沒有及時響應啟動或控制請求
        MySQL安裝常見報錯處理(總結分享)

        1.1 結束進程

        處理方法:
        1、在命令行中敲入tasklist查看進程
        2、根據進程名殺死進程
        taskkill /f /t /im 進程名稱

        MySQL安裝常見報錯處理(總結分享)
        MySQL安裝常見報錯處理(總結分享)

        1.2 更改網絡服務

        Server2012位置

        MySQL安裝常見報錯處理(總結分享)
        其他win7及win10操作系統

        1)、計算機->管理->本地用戶和組->組 雙擊,效果圖如下:

        MySQL安裝常見報錯處理(總結分享)
        (2)、雙擊Administrators,并點擊添加,再點擊高級

        (3)、把 NETWORK SERVICE添加到Administrators組

        MySQL安裝常見報錯處理(總結分享)

        1.3 刪除服務

        sc delete mysql57303307

        MySQL安裝常見報錯處理(總結分享)

        此處記住,重新安裝Mysql就可以,2步操作重新執行(刪除原有Mysql文件,全部重新安裝即可)
        還有個坑就是,如果還是啟動不了, 記得要開啟這個服務Windows Installer
        Windows Installer是一種通用的軟件發布方式,用于安裝軟件。
        默認情況下,該服務是手動啟動,需要進入服務管理中開啟。
        右擊開始——運行——輸入“services.msc”——Windows Installer——啟動

        MySQL安裝常見報錯處理(總結分享)
        MySQL安裝常見報錯處理(總結分享)

        2.Winwods安裝初始化報錯

        MySQL安裝常見報錯處理(總結分享)

        Beginning configuration step: Writing configuration fileSaving my.ini configuration file... Saved my.ini configuration file. Ended configuration step: Writing configuration fileBeginning configuration step: Updating Windows Firewall rules  Adding a Windows Firewall rule for MySQL80 on port 3306. Attempting to add a Windows Firewall rule with command: netsh.exe advfirewall firewall add rule name="Port 3306" protocol=TCP localport=3306 dir=in action=allow 確定。  Successfully added the Windows Firewall rule. Adding a Windows Firewall rule for MySQL80 on port 33060. Attempting to add a Windows Firewall rule with command: netsh.exe advfirewall firewall add rule name="Port 33060" protocol=TCP localport=33060 dir=in action=allow 確定。  Successfully added the Windows Firewall rule. Ended configuration step: Updating Windows Firewall rules  Beginning configuration step: Adjusting Windows serviceAttempting to grant Network Service require filesystem permissions. Granted permissions. Adding new serviceNew service added Ended configuration step: Adjusting Windows serviceBeginning configuration step: Initializing database (may take a long time)Attempting to run MySQL Server with --initialize-insecure option... Starting process for MySQL Server 8.0.24... Starting process with command: C:Program FilesMySQLMySQL Server 8.0binmysqld.exe --defaults-file="C:ProgramDataMySQLMySQL Server 8.0my.ini" --console --initialize-insecure=on --lower-case-table-names=1... Process for mysqld, with ID 2572, was run successfully and exited with code -1073741515. Failed to start process for MySQL Server 8.0.24. Database initialization failed. Ended configuration step: Initializing database (may take a long time)

        MySQL安裝常見報錯處理(總結分享)
        安裝VC_redist.x86即可執行既OK

        MySQL安裝常見報錯處理(總結分享)
        輸入gpedit.msc,打開策略管理

        MySQL安裝常見報錯處理(總結分享)
        啟用證書更新后正常

        由于部分系統鏡像構建較早,且不能進行系統更新,需要安裝系統補丁包才能完成vc++安裝

        4.Centos環境rpm初始化MySQL報錯

        Centos7 默認提供的 openssl 版本是 1.0.2 的,某些 php 擴展或者其他軟件依賴 1.1 以上版本,如果過低的話就會報錯
        libssl.so.1.1: cannot open shared object file: No such file or directory
        也有執行 openssl version 時報錯和上面一致,這是由于 openssl 庫的位置不正確或未安裝 1.1 以上版本的問題
        想要升級 openssl 版本則需要手動進行編譯,報錯解決方式很簡單,安裝正確即可,
        下面說一下我以 Centos7 為例,說一下具體的編譯安裝步驟

        –openssl版本確認
        [root@jeames ~]# openssl version
        OpenSSL 1.0.1e-fips 11 Feb 2013
        –編譯 openssl
        tar -xvf openssl-1.1.1g.tar.gz
        cd openssl-1.1.1g
        ./config shared –openssldir=/usr/local/openssl –prefix=/usr/local/openssl
        make && make install

        MySQL安裝常見報錯處理(總結分享)

        –配置
        編譯完成后,使用 openssl version,來查看一下當前 openssl 版本號時,
        你會發現還是 1.0.2,所以這里需要做一些額外的配置工作。
        [root@jeames openssl-1.1.1g]# more /etc/ld.so.conf
        include ld.so.conf.d/*.conf
        [root@jeames openssl-1.1.1g]# echo “/usr/local/lib64/” >> /etc/ld.so.conf
        [root@jeames openssl-1.1.1g]# ldconfig
        再次使用 openssl version 驗證版本就可以了,
        如果不行,可以嘗試下面的方式,
        依次執行(先備份老版本,再從新版本安裝位置創建軟連接)
        mv /usr/bin/openssl /usr/bin/openssl.old
        ln -s /usr/local/openssl/bin/openssl /usr/bin/openssl
        ln -s /usr/local/openssl/include/openssl /usr/include/openssl
        echo “/usr/local/openssl/lib” >> /etc/ld.so.conf
        ldconfig -v

        4.MySQL8安裝后無法登陸

        第一辦法:

        1.用命令編輯/etc/my.cnf配置文件,即:vim /etc/my.cnf 或者 vi /etc/my.cnf
        2.在[mysqld]下添加skip-grant-tables,然后保存并退出
        3.重啟mysql服務:service mysqld restart
        4.更改root用戶名
        重啟以后,執行mysql命令進入mysql命令行
        5.修改root用戶密碼,此處注意,有時候會報不允許修改,先flush privileges再執行即可
        update mysql.user set authentication_string=password(‘root’) where user=‘root’; –5.7版本
        flush privileges;
        6.把/etc/my.cnf中的skip-grant-tables注釋掉,然后重啟mysql,即:service mysqld restart
        好了,下面就可以用root新的密碼登錄了!

        MySQL安裝常見報錯處理(總結分享)
        第二種辦法:

        在mysql8系統下,適用如下方法(全路徑)
        G:mysql-8.0.23-winx64binmysqld –datadir=G:mysql-8.0.23-winx64data80323308 –console –skip-grant-tables –shared-memory

        MySQL安裝常見報錯處理(總結分享)

        然后再開一個窗口,執行下面命令
        cd G:mysql-8.0.23-winx64bin

        MySQL安裝常見報錯處理(總結分享)

        mysql> select user,host,authentication_string from mysql.user;
        mysql> delete from mysql.user where user=‘root’ ;
        mysql> flush privileges; –記得刷新哈,如果提示無法創建
        mysql> create user root@‘%’ identified with mysql_native_password by ‘root’;
        mysql> grant all on . to root@‘%’ with grant option;
        mysql> flush privileges;
        mysql> drop user ‘root’@‘localhost’;
        mysql> flush privileges;
        mysql> create user root@‘localhost’ identified with mysql_native_password by ‘root’;
        mysql> grant all on . to root@‘localhost’ with grant option;
        mysql> flush privileges;

        推薦學習:mysql視頻教程

        贊(0)
        分享到: 更多 (0)
        網站地圖   滬ICP備18035694號-2    滬公網安備31011702889846號
        主站蜘蛛池模板: 亚洲精品V欧洲精品V日韩精品 | 国产成人vr精品a视频| 91精品视频在线| 精品国精品无码自拍自在线| 欧美日韩专区麻豆精品在线 | 亚洲AV日韩精品久久久久久久| 精品国精品国产自在久国产应用男 | 亚洲一日韩欧美中文字幕欧美日韩在线精品一区二 | 亚洲国产精品不卡毛片a在线| 99热都是精品久久久久久| 国产精品伦一区二区三级视频 | 国产精品电影在线| 久久91精品国产91久久小草| 精品蜜臀久久久久99网站| 一本一本久久a久久精品综合麻豆| 国产精品永久免费视频| 久久精品人人做人人爽电影| 国产精品亚洲日韩欧美色窝窝色欲 | 国产系列高清精品第一页| 2023国产精品自拍| 久久精品成人国产午夜| 99RE6热在线精品视频观看| 久久精品无码午夜福利理论片| 午夜成人精品福利网站在线观看 | 精品福利资源在线| 91精品在线看| 国产精品偷伦视频观看免费| 中文成人无字幕乱码精品区| 亚洲精品国产高清不卡在线| 日韩精品无码Av一区二区| 久久亚洲中文字幕精品一区| 精品视频在线观看你懂的一区 | 日韩福利视频精品专区| 欧美精品一区二区三区免费| 免费精品国自产拍在线播放| 精品国产综合区久久久久久| 久久久99精品一区二区| 欧美日韩成人精品久久久免费看 | 日韩欧美亚洲国产精品字幕久久久| 久久精品国产WWW456C0M| 国产午夜精品理论片免费观看|