[ClusterLabs] Suggestions for multiple NFS mounts as LSB script

Strahil Nikolov hunter86_bg at yahoo.com
Mon Jun 29 12:45:35 EDT 2020


NFS mounting ... This sounds the perrfect candidate for autofs or systemd's '.automount'. Have you thought about systemd automounting your NFS ? 
It will allow  you to automatically mount on demand and umount based  on inactivity to prevent stale NFS mounts  on network issues.

If you still wish to use  your script,  you can create a systemd service  to call it and ensure (via  pacemaker) that service  will be  always running.


Best Regards,
Strahil Nikolov

На 29 юни 2020 г. 16:15:42 GMT+03:00, Tony Stocker <akostocker at gmail.com> написа:
>Hello
>
>We have a system which has become critical in nature and that
>management wants to be made into a high-available pair of servers. We
>are building on CentOS-8 and using Pacemaker to accomplish this.
>
>Without going into too much detail as to why it's being done, and to
>avoid any comments/suggestions about changing it which I cannot do,
>the system currently uses a script (which is not LSB compliant) to
>mount 133 NFS mounts. Yes, it's a crap ton of NFS mounts. No, I cannot
>do anything to alter, change, or reduce it. I must implement a
>Pacemaker 2-node high-availability pair which mounts those 133 NFS
>mounts. This list of mounts also changes over time as some are removed
>(rarely) and others added (much too frequently) and occasionally
>changed.
>
>It seems to me that manually putting each individual NFS mount in
>using the 'pcs' command as an individual ocf:heartbeat:FileSystem
>resource would be time-consuming and ultimately futile given the
>frequency of changes.
>
>Also, the reason that we don't put all of these mounts in the
>/etc/fstab file is to speed up boot times and ensure that the systems
>can actually come up into a useable state (and not hang forever)
>during a period when the NFS mounts might not be available for
>whatever reason (e.g. archive maintenance periods.)
>
>So, I'm left with trying to turn my coworker's bare minimum bash
>script that mounts these volumes into a functional LSB script. I've
>read:
>https://www.clusterlabs.org/pacemaker/doc/en-US/Pacemaker/2.0/html/Pacemaker_Explained/_linux_standard_base.html
>and
>http://refspecs.linux-foundation.org/LSB_3.0.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html
>
>My first question is: is there any kind of script within the Pacemaker
>world that one can use to verify that one's script passes muster and
>is compliant without actually trying to run it as a resource? ~8 years
>ago there used to be a script called ocf-tester that one used to check
>OCF scripts, but I notice that that doesn't seem to be available any
>more - and really I need one for Pacemaker-compatible LSB script
>testing.
>
>Second, just what is Pacemaker expecting from the script? Does it
>'exercise' it looking for all available options? Or is it simply
>relying on it to provide the correct responses when it calls 'start',
>'stop', and 'status'?
>
>Thanks in advance for help.
>_______________________________________________
>Manage your subscription:
>https://lists.clusterlabs.org/mailman/listinfo/users
>
>ClusterLabs home: https://www.clusterlabs.org/


More information about the Users mailing list