[DRBD-user] Notify admin for online verification

Jeffrey Froman drbd.tcijf at olympus.net
Thu Apr 3 01:17:38 CEST 2008

Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.


[message unwrapped]

On Wednesday 26 March 2008 12:39:58 am Florian Haas wrote:
>  In drbd.conf's "handlers" section, there is an "out-of-sync"
> handler command for that purpose.

Thanks for the tip. I have tried to enable this handler,
but I can't seem to trigger it. Online device verification
runs, but the handler script is not executed when
out-of-sync blocks are found.

I have verified that the handler script runs without error
when invoked manually. My configuration and log output are
below. Please let me know if I am missing something, or if
I am specifying my handler incorrectly.

Thank you,
Jeffrey


My configuration is as follows:
---------------------------------------------------
resource spare {
    protocol C;
    syncer {
        rate 100M;
        verify-alg sha1;
    }
    net {
        cram-hmac-alg sha1;
        shared-secret "foo";
    }
    handlers {
        out-of-sync "/opt/drbd/handlers/out-of-sync.sh $DRBD_RESOURCE";
    }
    disk {
        size 1703936K;
        on-io-error pass_on;
    }
    on host1 {
        device     /dev/drbd0;
        disk       /dev/VolGroup00/LogVol09;
        address    172.21.103.1:7788;
        meta-disk  internal;
    }
    on host2 {
      device     /dev/drbd0;
      disk       /dev/VolGroup00/LogVol07;
      address    172.21.103.2:7788;
      meta-disk  internal;
    }
}
-------------------------------------------------------------------

Running the command "drbdadm verify spare" on host1 produces
this output in /var/log/messages:

drbd0: conn( Connected -> VerifyS )
drbd0: Out of sync: start=0, size=16 (sectors)
drbd0: Out of sync: start=840, size=24 (sectors)
drbd0: Out of sync: start=4952, size=8 (sectors)
drbd0: Out of sync: start=5000, size=96 (sectors)
drbd0: Out of sync: start=70616, size=8 (sectors)
drbd0: Online verify  done (total 39 sec; paused 0 sec; 43688 K/sec)
drbd0: Online verify found 19 4k block out of sync!
drbd0: helper command: /sbin/drbdadm out-of-sync
drbd0: Writing the whole bitmap.
drbd0: writing of bitmap took 2 jiffies
drbd0: 76 KB (19 bits) marked out-of-sync by on disk bit-map.
drbd0: conn( VerifyS -> Connected )



More information about the drbd-user mailing list