当前位置:网站首页>华为云服务器安装mysqlb for mysqld.service failed because the control process exited with error code.See “sys
华为云服务器安装mysqlb for mysqld.service failed because the control process exited with error code.See “sys
2022-07-02 12:32:00 【请告诉他】
最近租了个华为云服务器,就是因为是贪图新用户折扣大,不贵,但是不太好用
一、
找到所有关于linux系统中关于mysql的文件
# find / -name '*mysql'

通过下面这个一个一个删除掉
rm -rf /usr/local/mysql
# 因为华为云上有可能默认用的是 maradb 先卸载服务器上的 mariadb 依赖
yum remove mariadb-libs
安装mysql的时候是从下面这两个地方去获得安装包
下载页面:https://downloads.mysql.com/archives/community/
下载地址:https://downloads.mysql.com/archives/get/p/23/file/mysql-5.7.36-1.el7.x86_64.rpm-bundle.tar
然后下载下来

解压
tar -xvf mysql-5.7.36-1.el7.x86_64.rpm-bundle.tar得到

执行如下
# 2.依次安装mysql rpm
rpm -ivh mysql-community-common-5.7.36-1.el7.x86_64.rpm;
rpm -ivh mysql-community-libs-5.7.36-1.el7.x86_64.rpm;
rpm -ivh mysql-community-client-5.7.36-1.el7.x86_64.rpm;
rpm -ivh mysql-community-server-5.7.36-1.el7.x86_64.rpm --force --nodeps;
启动 systemctl start mysqld
报错
Job for mysqld.service failed because the control process exited with error code.
See "systemctl status mysqld.service" and "journalctl -xe" for details.
[[email protected] system]# systemctl status mysqld.service
● mysqld.service - MySQL Server
Loaded: loaded (/usr/lib/systemd/system/mysqld.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Tue 2022-06-28 15:12:01 CST; 18s ago
Docs: man:mysqld(8)
http://dev.mysql.com/doc/refman/en/using-systemd.html
Process: 21786 ExecStart=/usr/sbin/mysqld --daemonize --pid-file=/var/run/mysqld/mysqld.pid $MYSQLD_OPTS (code=exited, status=127)
Process: 21763 ExecStartPre=/usr/bin/mysqld_pre_systemd (code=exited, status=0/SUCCESS)
更多错误信息

处理办法
vi /etc/my.cnf
将datadir = /var/lib/mysql 改成
之后,还需要在/var/lib/mysql下执行mkdir data 如果该目录存在data文件夹则删除重新创建即可
边栏推荐
- HMS core machine learning service helps zaful users to shop conveniently
- Use ffmpeg command line to push UDP and RTP streams (H264 and TS), and ffplay receives
- matlab中wavedec2,说说wavedec2函数[通俗易懂]
- 6090. Minimax games
- 6091. Divide the array so that the maximum difference is K
- Boot 连接 Impala数据库
- 可视化技术在 Nebula Graph 中的应用
- 如何實現十億級離線 CSV 導入 Nebula Graph
- /bin/ld: 找不到 -lcrypto
- Moveit 避障路径规划 demo
猜你喜欢

动态规划入门一,队列的bfs(70.121.279.200)

如何实现十亿级离线 CSV 导入 Nebula Graph

Tree binary search tree

树-二叉搜索树

使用 percona 工具给 MySQL 表加字段中断后该如何操作

Soul torture, what is AQS???
![[leetcode] 417 - Pacific Atlantic current problem](/img/30/c541bc1e81eb4e348ca11116a05e84.png)
[leetcode] 417 - Pacific Atlantic current problem

Comment réaliser un graphique Nebula d'importation CSV hors ligne de niveau milliard

Finally, I understand the event loop, synchronous / asynchronous, micro task / macro task, and operation mechanism in JS (with test questions attached)

Why does the system convert the temp environment variable to a short file name?
随机推荐
Boot 连接 Impala数据库
Why does the system convert the temp environment variable to a short file name?
2279. Maximum number of backpacks filled with stones
智联招聘的基于 Nebula Graph 的推荐实践分享
QVariant与Json的各种纠葛——Qt
(万字精华知识总结)Shell脚本编程基础知识
数组和链表的区别浅析
【idea】推荐一个idea翻译插件:Translation「建议收藏」
[leetcode] 877 stone game
Review materials for the special topic of analog electronics with all essence: basic amplification circuit knowledge points
Flink real-time data warehouse (IX): incremental synchronization of data in MySQL
6096. Success logarithm of spells and potions
基于 Nebula Graph 构建百亿关系知识图谱实践
Comment réaliser un graphique Nebula d'importation CSV hors ligne de niveau milliard
【题解】Educational Codeforces Round 82
Fiddler实现手机抓包——入门
Pattern matching extraction of specific subgraphs in graphx graph Computing Practice
[leetcode] 1140 stone game II
Fastjson list to jsonarray and jsonarray to list "suggested collections"
Ant group's large-scale map computing system tugraph passed the national evaluation