DRBDADM(8)

NAME
drbdadm - Administration tool for DRBD

SYNOPSIS
drbdadm [ -d ] [ -c file ] [ -s cmd ] [ -m cmd ] command [ all | resource ... ]

DESCRIPTION

Drbdadm is the high level tool of the DRBD program suite. Drbdadm is to drbdsetup and drbdmeta what ifup/ifdown is to ifconfig. Drbdadm reads its configuration file and performs the specified commands by calling the drbdsetup and/or the drbdmeta program.

OPTIONS

-d, --dry-run
    Just prints the calls of drbdsetup to stdout, but does not run the commands.

-c, --config-file file
    Specifies the configuration file drbdadm will use. If this parameter is not specified, drbdadm will look for /etc/drbd-08.conf and /etc/drbd.conf.

-s, --drbdsetup file
    Specifies the full path to the drbdsetup program. If this option is omitted, drbdadm will look for /sbin/drbdsetup and ./drbdsetup.

-m, --drbdmeta file
    Specifies the full path to the drbdmeta program. If this option is omitted, drbdadm will look for /sbin/drbdmeta and ./drbdmeta.

COMMANDS

attach
    Attaches a local backing block device to the DRBD resource's device.

detach
    Removes the backing storage device from a DRBD resource's device.

connect
    Sets up the network configuration of the resource's device. If the peer device is already configured, the two DRBD devices will connect.

disconnect
    Removes the network configuration from the resource. The device will then go into StandAlone state.

syncer
    Loads the resynchronization parameters into the device.

up  Is a shortcut for attach and connect.

down
    Is a shortcut for disconnect and detach.

primary
    Switch the resource's device into primary state. You need to do this before any access to the device, such as creating or mounting a file system.

secondary
    Brings the device back into secondary role. This is needed since in a connected DRBD device pair, only one of the two peers may have primary role (except if allow-two-primaries is explicitly set in the configuration file).

invalidate
    Forces DRBD to consider the data on the local backing storage device as out-of-sync. Therefore DRBD will copy each and every block over from its peer, to bring the local storage device back in sync.

invalidate-remote
    This command is similar to the invalidate command, however, the peer's backing storage is invalidated and hence rewritten with the data of the local node.

resize
    Causes DRBD to re-examine all sizing constraints, and resize the resource's device accordingly. For example in case you increased the size of your backing storage devices (on both nodes of course), then DRBD will adopt to the new size after you called this command on one of your nodes. Since new storage space must be synchronised this command only works if there is at least one primary node present.

create-md
    Initializes the meta data storage. This needs to be done before a DRBD resource can be taken online for the first time.

get-gi
    Shows a short textual representation of the data generation identifiers.

show-gi
    Prints a textual representation of the data generation identifiers including explanatory information.

dump-md
    Dumps the whole contents of the meta data storage, including the stored bit-map and activity-log, in a textual representation.

outdate
    Sets the outdated flag in the meta data.

adjust
    Synchronizes the configuration of the device with your configuration file. You should always examine the output of the dry-run mode before actually executing this command.

wait-connect
    Waits until the device is connected to its peer device.

state
    Shows the current states of the devices (local/peer). E.g. Primary/Secondary

cstate
    Shows the current connection state of the devices.

dump
    Just parse the configuration file and dump it to stdout. May be used to check the configuration file for syntactical correctness.

outdate
    Used to mark the node's data as outdated. Usually used by the peer's outdate-peer handler.

pause-sync
    Temporarily suspend an ongoing resynchronization by setting the local pause flag. Resync only progresses if neither the local nor the remote pause flag is set. It might be desirable to postpone DRBD's resynchronization until after any resynchronization of the backing storage's RAID setup.

resume-sync
    Unset the local sync pause flag.

dstate
    Show the current state of the backing storage devices. (local/peer)

hidden-commands
    Shows all commands undocumented on purpose.

VERSION

This document was revised for version 8.0.14 of the DRBD distribution.

AUTHOR

Written by Philipp Reisner <philipp.reisner@linbit.com> and Lars Ellenberg <lars.ellenberg@linbit.com>

REPORTING BUGS

Report bugs to <drbd-user@lists.linbit.com>.

COPYRIGHT

Copyright 2001-2008 LINBIT Information Technologies, Philipp Reisner, Lars Ellenberg. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

SEE ALSO

drbd.conf(5), drbd(8), drbddisk(8) drbdsetup(8) drbdmeta(8) DRBD project web site <URL:http://www.drbd.org/>