[ClusterLabs] resource agent OCF_HEARTBEAT_GALERA issue/broken - ?

Reid Wahl nwahl at redhat.com
Tue Jul 26 15:56:55 EDT 2022


On Tue, Jul 26, 2022 at 4:21 AM lejeczek via Users
<users at clusterlabs.org> wrote:
>
> Hi guys
>
> I set up a clone of a new instance of mariadb galera - which otherwise,
> outside of pcs works - but I see something weird.
>
> Firstly cluster claims it's all good:
>
> -> $ pcs status --full
> ...
>
>    * Clone Set: mariadb-apps-clone [mariadb-apps] (promotable):
>      * mariadb-apps    (ocf::heartbeat:galera):     Master
> sucker.internal.ccn
>      * mariadb-apps    (ocf::heartbeat:galera):     Master
> drunk.internal.ccn

Clearly the problem is that your server is drunk.

>
> but that mariadb is _not_ started actually.
>
> In clone's attr I set:
>
> config=/apps/etc/mariadb-server.cnf
>
> I also for peace of mind set:
>
> datadir=/apps/mysql/data
>
> even tough '/apps/etc/mariadb-server.cnf' declares that & other bits -
> again, works outside of pcs.
>
> Then I see in pacemaker logs:
>
> notice: mariadb-apps_start_0 at drunk.internal.ccn output [ 220726 11:56:13
> mysqld_safe Logging to '/tmp/tmp.On5VnzOyaF'.\n220726 11:56:13
> mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql\n ]
>
> .. and I think what the F?
>
> resource-agents-4.9.0-22.el8.x86_64
>
> All thoughts share are much appreciated.
>
> many thanks, L.
>

How do you start mariadb outside of pacemaker's control?

It seems that *something* is running, based on the "Starting" message
and the fact that the resources are still in Started state...

The logic to start and promote the galera resource is contained within
/usr/lib/ocf/resource.d/heartbeat/galera and
/usr/lib/ocf/lib/heartbeat/mysql-common.sh. I encourage you to inspect
those for any relevant differences between your own startup method and
that of the resource agent.

As one example, note that the resource agent uses mysqld_safe by
default. This is configurable via the `binary` option for the
resource. Be sure that you've looked at all the available options
(`pcs resource describe ocf:heartbeat:galera`) and configured any of
them that you need. You've definitely at least started that process
with config and datadir.
>
> _______________________________________________
> Manage your subscription:
> https://lists.clusterlabs.org/mailman/listinfo/users
>
> ClusterLabs home: https://www.clusterlabs.org/



-- 
Regards,

Reid Wahl (He/Him)
Senior Software Engineer, Red Hat
RHEL High Availability - Pacemaker



More information about the Users mailing list