ispmanager mysql settings empty. Edit button is disabled (( - mysql

Ispmanager 5, CentOs 7
I just uninstall default Mysql with commands:
service mariadb stop
yum remove mariadb mariadb-server
Than upgraded it with mariadb 10.3:
cat > /etc/yum.repos.d/MariaDB.repo <<EOF
# MariaDB.repo
# MariaDB 10.3 CentOS repository list
# http://downloads.mariadb.org/mariadb/repositories/
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.3/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
EOF
yum -y install MariaDB-server MariaDB-client
mkdir -p /var/run/mysqld
chown -R mysql:mysql /var/run/mysqld
systemctl enable mariadb
service mariadb start
After this - all things working fine except this:
The server settings - is empty. Edit button is disabled.
PS: /etc/my.cnf is on its place, mysql --help shows than it uses /etc/my.cnf and ~/my.cnf

I edited the parameter to new path
path mysqld usr/sbin/mysqld
in /usr/local/mgr5/etc/ispmgr.conf.d/mysql.conf
Because new version of mariadb uses another path of the mysqld.
After this all things works like a charm )))

Related

Error in docker-compose's MariaDB when it is restarted [duplicate]

I configured 3 drives on my machine: 1 for data files, 1 for transaction logs files, and 1 for temporary files.
I would like to initialize MariaDB at its first run straight after yum installation. Here are my steps:
created /etc/my.cnf with the following parameters
[mysqld]
aria-log-dir-path=/tempdb/mysql/
datadir=/data/mysql/
tmpdir=/tempdb/mysql/
innodb_data_home_dir=/data/mysql/
innodb_log_group_home_dir=/tlogs/mysql/
innodb_undo_directory=/tlogs/mysql/
aria-log-dir-path=/tempdb/mysql/
install MariaDB
sudo yum -y update
sudo tee /etc/yum.repos.d/MariaDB.repo<<EOF
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.4/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
EOF
sudo yum makecache fast
sudo yum -y install MariaDB-server MariaDB-client
sudo systemctl start mariadb
I get the following exception
Can't start server : Bind on unix socket: No such file or directory
Can anyone shed some light on what I'm doing wrong? is this the right procedure to achieve my goal?
Thx
Gianluca
need to set the socket parameter
[client]
socket=/tmp/mysql.sock
...
[mysqld]
...
socket=/tmp/mysql.sock
...

Error in docker-compose's mariadb when i restart it [duplicate]

I configured 3 drives on my machine: 1 for data files, 1 for transaction logs files, and 1 for temporary files.
I would like to initialize MariaDB at its first run straight after yum installation. Here are my steps:
created /etc/my.cnf with the following parameters
[mysqld]
aria-log-dir-path=/tempdb/mysql/
datadir=/data/mysql/
tmpdir=/tempdb/mysql/
innodb_data_home_dir=/data/mysql/
innodb_log_group_home_dir=/tlogs/mysql/
innodb_undo_directory=/tlogs/mysql/
aria-log-dir-path=/tempdb/mysql/
install MariaDB
sudo yum -y update
sudo tee /etc/yum.repos.d/MariaDB.repo<<EOF
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.4/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
EOF
sudo yum makecache fast
sudo yum -y install MariaDB-server MariaDB-client
sudo systemctl start mariadb
I get the following exception
Can't start server : Bind on unix socket: No such file or directory
Can anyone shed some light on what I'm doing wrong? is this the right procedure to achieve my goal?
Thx
Gianluca
need to set the socket parameter
[client]
socket=/tmp/mysql.sock
...
[mysqld]
...
socket=/tmp/mysql.sock
...

Initialize MariaDB 10.4.12 on CentOS 7.7

I configured 3 drives on my machine: 1 for data files, 1 for transaction logs files, and 1 for temporary files.
I would like to initialize MariaDB at its first run straight after yum installation. Here are my steps:
created /etc/my.cnf with the following parameters
[mysqld]
aria-log-dir-path=/tempdb/mysql/
datadir=/data/mysql/
tmpdir=/tempdb/mysql/
innodb_data_home_dir=/data/mysql/
innodb_log_group_home_dir=/tlogs/mysql/
innodb_undo_directory=/tlogs/mysql/
aria-log-dir-path=/tempdb/mysql/
install MariaDB
sudo yum -y update
sudo tee /etc/yum.repos.d/MariaDB.repo<<EOF
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.4/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
EOF
sudo yum makecache fast
sudo yum -y install MariaDB-server MariaDB-client
sudo systemctl start mariadb
I get the following exception
Can't start server : Bind on unix socket: No such file or directory
Can anyone shed some light on what I'm doing wrong? is this the right procedure to achieve my goal?
Thx
Gianluca
need to set the socket parameter
[client]
socket=/tmp/mysql.sock
...
[mysqld]
...
socket=/tmp/mysql.sock
...

Completely remove MariaDB or MySQL from CentOS 7 or RHEL 7

I installed MariaDB on CentOS 7 but I had some problems with some configuration, now it is completely misconfigured.
Thus, I wanted to remove the MariaDB with “yum remove mariadb mariadb-server”, after that I reinstalled it with “yum install mariadb mariadb-server”.
Unfortunately, the configuration remains. It seems as if yum remove don’t delete all MariaDB Config-Files.
How can I remove MariaDB completely from CentOS 7?
These steps are working on CentOS 6.5 so they should work on CentOS 7 too:
(EDIT - exactly the same steps work for MariaDB 10.3 on CentOS 8)
yum remove mariadb mariadb-server
rm -rf /var/lib/mysql If your datadir in /etc/my.cnf points to a different directory, remove that directory instead of /var/lib/mysql
rm /etc/my.cnf the file might have already been deleted at step 1
Optional step: rm ~/.my.cnf
yum install mariadb mariadb-server
[EDIT] - Update for MariaDB 10.1 on CentOS 7
The steps above worked for CentOS 6.5 and MariaDB 10.
I've just installed MariaDB 10.1 on CentOS 7 and some of the steps are slightly different.
Step 1 would become:
yum remove MariaDB-server MariaDB-client
Step 5 would become:
yum install MariaDB-server MariaDB-client
The other steps remain the same.
To update and answer the question without breaking mail servers. Later versions of CentOS 7 have MariaDB included as the base along with PostFix which relies on MariaDB. Removing using yum will also remove postfix and perl-DBD-MySQL. To get around this and keep postfix in place, first make a copy of /usr/lib64/libmysqlclient.so.18 (which is what postfix depends on) and then use:
rpm -qa | grep mariadb
then remove the mariadb packages using (changing to your versions):
rpm -e --nodeps "mariadb-libs-5.5.56-2.el7.x86_64"
rpm -e --nodeps "mariadb-server-5.5.56-2.el7.x86_64"
rpm -e --nodeps "mariadb-5.5.56-2.el7.x86_64"
Delete left over files and folders (which also removes any databases):
rm -f /var/log/mariadb
rm -f /var/log/mariadb/mariadb.log.rpmsave
rm -rf /var/lib/mysql
rm -rf /usr/lib64/mysql
rm -rf /usr/share/mysql
Put back the copy of /usr/lib64/libmysqlclient.so.18 you made at the start and you can restart postfix.
There is more detail at https://code.trev.id.au/centos-7-remove-mariadb-replace-mysql/ which describes how to replace mariaDB with MySQL
systemd
sudo systemctl stop mysqld.service && sudo yum remove -y mariadb mariadb-server && sudo rm -rf /var/lib/mysql /etc/my.cnf
sysvinit
sudo service mysql stop && sudo apt-get remove mariadb mariadb-server && sudo rm -rf /var/lib/mysql /etc/my.cnf

Install MySQL 5.5 in Ubuntu 11.10

I have been downloaded the DEB package of mysql 5.5.23.
Install MySQL by the command as follows:
sudo dpkg -i mysql-5.5.23-debian6.0-x86_64.deb
The result said that installed successfully.
But when I type the command:
sudo service mysql start
Or
mysql
It shows me that "mysql: unrecognized service" or "mysql: command not found".
Besides, I can't find MySQL files in "/usr/include" or "/usr/bin"
Please help me. Thx.
Because MySQL 5.5.x is not packaged, in repositories only exist 5.1.x
This worked for me:
http://www.rebojo.com/debian-installing-mysql/
Why not a simple command :
sudo apt-get install mysql-server
MySQL Download URL
https://dev.mysql.com/get/Downloads/MySQL-5.5/mysql-5.5.56-linux-glibc2.5-x86_64.tar.gz
Open the terminal and follow along:
Uninstall any existing version of MySQL
sudo rm /var/lib/mysql/ -R
Delete the MySQL profile
sudo rm /etc/mysql/ -R
Automatically uninstall mysql
sudo apt-get autoremove mysql* --purge
sudo apt-get remove apparmor
Download version 5.5.51 from MySQL site
wget https://dev.mysql.com/get/Downloads/MySQL-5.5/mysql-5.5.56-linux-glibc2.5-x86_64.tar.gz
Add mysql user group
sudo groupadd mysql
Add mysql (not the current user) to mysql user group
sudo useradd -g mysql mysql
Extract it
sudo tar -xvf mysql-5.5.56-linux-glibc2.5-x86_64.tar.gz
Move it to /usr/local
sudo mv mysql-5.5.56-linux-glibc2.5-x86_64 /usr/local/
Create mysql folder in /usr/local by moving the untarred folder
cd /usr/local
sudo mv mysql-5.5.49-linux2.6-x86_64 mysql
set MySql directory owner and user group
cd mysql
sudo chown -R mysql:mysql *
Install the required lib package (works with 5.6 as well)
sudo apt-get install libaio1
Execute mysql installation script
sudo scripts/mysql_install_db --user=mysql
Set mysql directory owner from outside the mysql directory
sudo chown -R root .
Set data directory owner from inside mysql directory
sudo chown -R mysql data
Copy the mysql configuration file
sudo cp support-files/my-medium.cnf /etc/my.cnf
Start mysql
sudo bin/mysqld_safe --user=mysql &
sudo cp support-files/mysql.server /etc/init.d/mysql.server
Set root user password
sudo bin/mysqladmin -u root password '[your new password]'
Add mysql path to the system
sudo ln -s /usr/local/mysql/bin/mysql /usr/local/bin/mysql
Reboot!
Start mysql server
sudo /etc/init.d/mysql.server start
Stop mysql server
sudo /etc/init.d/mysql.server stop
Check status of mysql
sudo /etc/init.d/mysql.server status
Enable myql on startup
sudo update-rc.d -f mysql.server defaults
*Disable mysql on startup (Optional)
`sudo update-rc.d -f mysql.server remove`
REBOOT!
Now login using below command, start mysql server if it's not running already
mysql -u root -p