galera_new_cluster: command not found

591 views
Skip to first unread message

Sharad Reddy

unread,
Jul 9, 2019, 1:54:59 AM7/9/19
to codership
 I am following instructions to install MariDB Galera cluster on Centos 7.6 But, I just cannot get the cluster to start. I can get the mariadb service started on both nodes. Here is my server.cnf

 [galera]
# Mandatory settings
wsrep_cluster_name="galera_cluster"
wsrep_on=ON
wsrep_provider=/usr/lib64/galera/libgalera_smm.so
wsrep_cluster_address=gcomm://172.18.35.XXX,172.18.35.XXX
binlog_format=row
default_storage_engine=InnoDB
innodb_autoinc_lock_mode=2

I am stumped, there is nothing in the maria db logs. What else should I be looking at?

Manuel Domínguez Dorado

unread,
Jul 9, 2019, 6:07:10 AM7/9/19
to Sharad Reddy, codership
You have to bootstrap your fisrt node:

service mysql start --wsrep-new-cluster

Then, you can start the other nodes as usual (without --wsrep-new-cluster)

Best regards.


--
You received this message because you are subscribed to the Google Groups "codership" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codership-tea...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/codership-team/d475ce5b-ffad-4cb2-aac0-4602a8ccb0e9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
---
Manuel Domínguez Dorado
Software engineer (Ph.D, M.Sc., B.Sc.)
Certified Project Management Professional (PMP)

inge...@manoloDominguez.com
http://www.ManoloDominguez.com
(+34) 607 418 760

saurabh tandon

unread,
Jul 9, 2019, 6:18:06 AM7/9/19
to codership
Don't start the service on all the nodes at once.

First, start your primary node with systemctl start my...@bootstrap.service .

Then start your mysql service one by one on all other nodes.

Sharad Reddy

unread,
Jul 9, 2019, 9:38:26 AM7/9/19
to codership
The instructions am using - https://ahmermansoor.blogspot.com/2019/02/install-mariadb-galera-cluster-on-centos-7.html

Ask that I use this command to start the cluster

root@test-db1:~$ galera_new_cluster

-bash: galera_new_cluster: command not found


There is no mention of bootstrapping.


On Tuesday, July 9, 2019 at 6:07:10 AM UTC-4, Manuel Domínguez Dorado wrote:
You have to bootstrap your fisrt node:

service mysql start --wsrep-new-cluster

Then, you can start the other nodes as usual (without --wsrep-new-cluster)

Best regards.


El mar., 9 jul. 2019 a las 7:55, Sharad Reddy (<shar...@gmail.com>) escribió:
 I am following instructions to install MariDB Galera cluster on Centos 7.6 But, I just cannot get the cluster to start. I can get the mariadb service started on both nodes. Here is my server.cnf

 [galera]
# Mandatory settings
wsrep_cluster_name="galera_cluster"
wsrep_on=ON
wsrep_provider=/usr/lib64/galera/libgalera_smm.so
wsrep_cluster_address=gcomm://172.18.35.XXX,172.18.35.XXX
binlog_format=row
default_storage_engine=InnoDB
innodb_autoinc_lock_mode=2

I am stumped, there is nothing in the maria db logs. What else should I be looking at?

--
You received this message because you are subscribed to the Google Groups "codership" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codersh...@googlegroups.com.

Manuel Domínguez Dorado

unread,
Jul 9, 2019, 10:14:34 AM7/9/19
to Sharad Reddy, codership
Hi,

This is from mariadb cluster setting up and configuration.


Wich version are you using?

To unsubscribe from this group and stop receiving emails from it, send an email to codership-tea...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/codership-team/6fb9da55-a4ef-40ee-8e38-906deadff257%40googlegroups.com.

Sharad Reddy

unread,
Jul 9, 2019, 11:39:11 AM7/9/19
to codership
This is CentOS 7.6 and 5.5.60-MariaDB MariaDB Server

The documentation says -

On operating systems that use systemd, a node can be bootstrapped in the following way:

$ galera_new_cluster

This wrapper uses systemd to run mysqld with the --wsrep-new-cluster option.

Sharad Reddy

unread,
Jul 9, 2019, 3:17:17 PM7/9/19
to codership
Never mind , I was able to get past that step, but the cluster will not start.
I do not get any errors when I run 

root@db-mmr101:/var/lib/mysql$  /usr/bin/mysqld_safe --wsrep-new-cluster
190709 15:01:24 mysqld_safe Logging to '/var/lib/mysql/db-mmr101.err'.
190709 15:01:25 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql


Or start the mariadb service. Nothing in the error logs as well?


90709 15:01:30 mysqld_safe mysqld from pid file /var/lib/mysql/db-mmr101.pid ended
190709 15:01:38 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
190709 15:01:38 [Note] /usr/libexec/mysqld (mysqld 5.5.60-MariaDB) starting as process 19920 ...
190709 15:01:38 InnoDB: The InnoDB memory heap is disabled
190709 15:01:38 InnoDB: Mutexes and rw_locks use GCC atomic builtins
190709 15:01:38 InnoDB: Compressed tables use zlib 1.2.7
190709 15:01:38 InnoDB: Using Linux native AIO
190709 15:01:38 InnoDB: Initializing buffer pool, size = 128.0M
190709 15:01:38 InnoDB: Completed initialization of buffer pool
190709 15:01:38 InnoDB: highest supported file format is Barracuda.
190709 15:01:38  InnoDB: Waiting for the background threads to start
190709 15:01:39 Percona XtraDB (http://www.percona.com) 5.5.59-MariaDB-38.11 started; log sequence number 1597945
190709 15:01:39 [Note] Plugin 'FEEDBACK' is disabled.
190709 15:01:39 [Note] Server socket created on IP: '0.0.0.0'.
190709 15:01:39 [Note] Event Scheduler: Loaded 0 events
190709 15:01:39 [Note] /usr/libexec/mysqld: ready for connections.
Version: '5.5.60-MariaDB'  socket: '/var/lib/mysql/mysql.sock'  port: 3306  MariaDB Server

Sharad Reddy

unread,
Jul 11, 2019, 2:05:35 PM7/11/19
to codership
0I realized that yum install was not installing MariaDB 10+ on Centos7.6, since there is no build in the repo for that. Had to use rpm to download/build MariaDB 10.4. yum will install the default MariaDB 5.5 which comes with Centos 7.6. 5.5 is a really old version, which does not have the galera_new_cluster command. Here is a good guide to get MariaDB installed on RHEL 7+ using rpm-qahttps://medium.com/@thomashysselinckx/installing-mariadb-with-rpm-on-centos7-bce648cce75I spent a lot of time, trying to get it working with yum and eventually gave up and went the rpm route. Glad to help anyone stuck in a similar rut!
Reply all
Reply to author
Forward
0 new messages