[Email protected]:/opt# MKDIR/MYDATA/DATA-PV
[Email protected]:/opt# groupadd-r MySQL
[Email protected]:/opt# useradd-g mysql-r-s/sbin/nologin-m-d/mydata/data MySQL
-R,--system create a System account
-S,--shell Shell login shell for new account
-M, --no-create-home does not create a user's home directory
-D,--home-dir home_dir the home directory of the new account
-G, the name or ID of the--gid group's new account owner
[Email protected]:/# chown-r Mysql:mysql/mydata/data
[Email protected]:/# tar xf/root/mariadb-10.0.28-linux-glibc_214-x86_64.tar.gz-c/usr/local
[Email protected]:/# cd/usr/local
[Email protected]:/usr/local# ln-sv mariadb-10.0.28-linux-x86_64 MySQL
[Email protected]:/usr/local/mysql# cd MySQL
[Email protected]:/usr/local/mysql# chown-r mysql:mysql.
[Email protected]:/usr/local/mysql# apt-get Install Libaio-dev after installation to initialize the success of the error is missing it
[Email protected]:/usr/local/mysql# scripts/mysql_install_db--user=mysql--datadir=/mydata/data
[Email protected]:/usr/local/mysql# chown-r root.
[Email protected]:/usr/local/mysql# CP support-files/my-large.cnf/etc/my.cnf
and modify the value of thread_concurrency in this file to multiply your number of CPUs by 2, for example using the following line:
Thread_concurrency = 2
Also add the following line to specify where the MySQL data file will be stored:
DataDir =/mydata/data
[Email protected]:/usr/local/mysql# CP support-files/mysql.server/etc/init.d/mysqld
[Email protected]:/usr/local/mysql# chmod +x/etc/init.d/mysqld
[Email protected]:/usr/local/mysql#/lib/systemd/systemd-sysv-install Enable mysqld
[Email protected]:/usr/local/mysql# systemctl start mysqld
enable a service at boot time:systemctl enable postfix.service
Disable a service at boot time:systemctl disable postfix.service
To see if the service is booting up:systemctl is-enabled postfix.service
to view a list of services that have been started:systemctl list-unit-files|grep enabled
to view a list of services that failed to start:systemctl --failed
Ubuntu Install binary mariadb