linux安装mysql错误点

[root@VM-16-4-centos mysql]# cd bin
[root@VM-16-4-centos bin]# ./mysqld --initialize --user=mysql --basedir=/usr/local/mysql--datadir=/usr/local/mysql/data
2022-01-10T02:25:53.689767Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2022-01-10T02:25:53.689896Z 0 [ERROR] Can't find error-message file '/usr/local/mysql--datadir=/usr/local/mysql/data/share/errmsg.sys'. Check error-message file location and 'lc-messages-dir' configuration directive.
2022-01-10T02:25:53.691151Z 0 [ERROR]
2022-01-10T02:25:53.691171Z 0 [ERROR] Aborting

[root@VM-16-4-centos bin]# [root@VM-16-4-centos bin]# ./mysqld --initialize --user=mysql --basedir=/usr/local/mysql--datadir=/usr/local/mysql/data
-bash: [root@VM-16-4-centos: command not found
[root@VM-16-4-centos bin]# 2022-01-10T02:25:53.689767Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
-bash: syntax error near unexpected token `('
[root@VM-16-4-centos bin]# 2022-01-10T02:25:53.689896Z 0 [ERROR] Can't find error-message file '/usr/local/mysql--datadir=/usr/local/mysql/data/share/errmsg.sys'. Check error-message file location and 'lc-messages-dir' configuration directive.
> 2022-01-10T02:25:53.691151Z 0 [ERROR]
> 2022-01-10T02:25:53.691171Z 0 [ERROR] Aborting
>
> ^C
[root@VM-16-4-centos bin]# cd /etc
[root@VM-16-4-centos etc]# ls
abrt environment ld.so.conf pkcs11 shadow
acpi ethertypes ld.so.conf.d pki shadow-
adjtime exports ld.so.preload plymouth shells
aliases favicon.png libaudit.conf pm skel
aliases.db filesystems libibverbs.d polkit-1 sos.conf
alternatives firewalld libnl popt.d srp_daemon.conf
anacrontab fonts libreport postfix ssh
asound.conf fstab libuser.conf ppp ssl
at.deny gcrypt locale.conf prelink.conf.d statetab
audisp gdbinit localtime printcap statetab.d
audit gdbinit.d login.defs profile subgid
bash_completion.d GeoIP.conf logrotate.conf profile.d subgid-
bashrc glvnd logrotate.d protocols subuid
binfmt.d gnupg lsm python subuid-
centos-release GREP_COLORS lvm qcloudzone sudo.conf
centos-release-upstream groff machine-id qemu-ga sudoers
chkconfig.d group machine-info rc0.d sudoers.d
chrony.conf group- magic rc1.d sudo-ldap.conf
chrony.conf.dist grub2.cfg mail.rc rc2.d sysconfig
chrony.keys grub.d makedumpfile.conf.sample rc3.d sysctl.conf
cifs-utils gshadow man_db.conf rc4.d sysctl.d
cloud gshadow- mft rc5.d systemd
cron.d gss mke2fs.conf rc6.d system-release
cron.daily host.conf modprobe.d rc.d system-release-cpe
cron.deny hostname modules-load.d rc.local terminfo
cron.hourly hosts motd rdma tmpfiles.d
cron.monthly hosts.allow mtab redhat-release trusted-key.key
crontab hosts.deny my.cnf resolv.conf tuned
cron.weekly ibutils2 nanorc rpc udev
crypttab img_version netconfig rpm updatedb.conf
csh.cshrc infiniband NetworkManager rshim.conf usb_modeswitch.conf
csh.login infiniband-diags networks rsyncd.conf uuid
dat.conf init.d nsswitch.conf rsyslog.conf vconsole.conf
dbus-1 inittab nsswitch.conf.bak rsyslog.d vimrc
default inputrc nsswitch.conf.rpmnew rwtab virc
depmod.d iproute2 ntp rwtab.d wgetrc
dhcp iscsi ntp.conf sasl2 wpa_supplicant
DIR_COLORS issue openldap scl X11
DIR_COLORS.256color issue.net opensm securetty xdg
DIR_COLORS.lightbgcolor kdump.conf opt security xinetd.d
dracut.conf kernel os-release selinux yum
dracut.conf.d krb5.conf pam.d services yum.conf
e2fsck.conf krb5.conf.d passwd sestatus.conf yum.repos.d
egl ld.so.cache passwd- setuptool.d
[root@VM-16-4-centos etc]# find my.cnf
my.cnf
[root@VM-16-4-centos etc]# vim my.cnf
[root@VM-16-4-centos etc]# cd /usr/local/mysql/bin/
[root@VM-16-4-centos bin]# ./mysqld --initialize --user=mysql --basedir=/usr/local/mysql--datadir=/usr/local/mysql/data
mysqld: Can't create directory '/usr/local/mysql--datadir=/usr/local/mysql/data/data/' (Errcode: 2 - No such file or directory)
2022-01-10T02:32:17.614255Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2022-01-10T02:32:17.614377Z 0 [ERROR] Can't find error-message file '/usr/local/mysql--datadir=/usr/local/mysql/data/share/errmsg.sys'. Check error-message file location and 'lc-messages-dir' configuration directive.
2022-01-10T02:32:17.615053Z 0 [ERROR] Aborting

[root@VM-16-4-centos bin]# ./mysqld --initialize --user=mysql --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data
2022-01-10T02:32:52.483016Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details).
2022-01-10T02:32:52.873561Z 0 [Warning] InnoDB: New log files created, LSN=45790
2022-01-10T02:32:52.979055Z 0 [Warning] InnoDB: Creating foreign key constraint system tables.
2022-01-10T02:32:53.101012Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: 9c8ee1b6-71bd-11ec-a8ec-525400829a9d.
2022-01-10T02:32:53.110817Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened.
2022-01-10T02:32:53.892518Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher.
2022-01-10T02:32:53.892536Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher.
2022-01-10T02:32:53.893155Z 0 [Warning] CA certificate ca.pem is self signed.
2022-01-10T02:32:53.966145Z 1 [Note] A temporary password is generated for root@localhost: 9aw:i1>.5vaC
[root@VM-16-4-centos bin]#

posted @ 2022-01-10 10:35  এএ᭄念卿এএ᭄  阅读(527)  评论(0)    收藏  举报