[DRBD-user] drbdmanage modify-config in a shell script

Roland Kammerer roland.kammerer at linbit.com
Mon Jul 16 09:30:04 CEST 2018


On Sun, Jul 15, 2018 at 12:38:46PM +0300, Eli Shemer wrote:
> hey
> 
> what is the correct way to configure drbd via a shell script?
> 
> drbdmanage modify-config prompts up a VI window, and the whole command does
> not seem to accept inputs through pipes.
> 
> I was thinking to use "drbdmanage export-config" to automate the process
> but I don't see any corresponding "drbdmanage import-config"
> 
> I would appreciate any clarifications you could provide over the best
> practices with the drbdmanage suite.

DRBDManage is EoL and only gets bug fixes, so don't expect any new
commands (like import-config).

Usually there is no need, okay this pops up every 9 months or so, but if
it is something you want to set for all (including new resources), you
can use the "--common" flag. If you need to script, "modify-config"
honors the EDITOR env variable, and "$1" is the name of a temporary file
you can then modify, guess you get the idea.

Regards, rck


More information about the drbd-user mailing list