[DRBD-user] 0.6.10, sync should be in background?

george young gry at ll.mit.edu
Mon Apr 11 18:03:30 CEST 2005

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


What happened:  One of a pair of servers (pig-app) hung (after several
months uptime), and had to be quickly rebooted.

What went wrong:  On rebooting, pig-app insisted on waiting the 1.7 hours
for the "db" partition to sync, even though pig-app does not mount "db".

The configuration: two servers, pig-app and pig-db.  Normally pig-app
mounts /home through drbd and pig-db mounts /db through drbd.  The two
file systems are mirrored on the other server, so if one dies, the other
can take over services.  The problem is that when pig-app rebooted, it
should (I think) have come up fully and synced it's copy of /db in the
background, not held up the boot process (and kept my users waiting!).

Is my configuration wrong?  Details below.

-- George

/proc/version:
   Linux version 2.4.24 (root at pig-app) (gcc version 3.3.2) #3 SMP Tue Jan 27 12:42:59 EST 2004
----------------------------------------------------------------------

/proc/drbd:
   version: 0.6.10 (api:64/proto:62)

   0: cs:Connected st:Primary/Secondary ns:38191332 nr:0 dw:1482840 dr:37059748 pe:0 ua:0
   1: cs:Connected st:Secondary/Primary ns:0 nr:2569644 dw:2569644 dr:0 pe:0 ua:0
----------------------------------------------------------------------

/var/log/messages
Apr  8 10:30:55 pig-app kernel: drbd: initialised. Version: 0.6.10 (api:64/proto:62)
Apr  8 10:30:55 pig-app drbd: drbdsetup /dev/nb0 disk /dev/rd/c0d0p5 --disk-size=36708492
Apr  8 10:30:55 pig-app drbd: drbdsetup /dev/nb0 net 10.0.0.115:7788 10.0.0.114:7788 C --sync-nice=-15 --sync-min=10M --sync-max=100M --tl-size=5000 --timeout=60 --connect-int=10 --ping-int=10 --sync-group=1
Apr  8 10:30:55 pig-app drbd: drbdsetup /dev/nb1 disk /dev/rd/c0d0p3 --disk-size=1060290k
Apr  8 10:30:55 pig-app kernel: drbd0: Connection established. size=36708492 KB / blksize=4096 B
Apr  8 10:30:55 pig-app kernel: drbd0: Synchronisation started blks=15
Apr  8 10:30:55 pig-app drbd: drbdsetup /dev/nb1 net 10.0.0.115:7789 10.0.0.114:7789 C --sync-nice=-15 --sync-min=10M --sync-max=100M --tl-size=5000 --timeout=60 --connect-int=10 --ping-int=10 --sync-group=2
Apr  8 10:30:55 pig-app drbd: drbdsetup /dev/nb0 wait_connect -t 0
Apr  8 10:30:55 pig-app kernel: drbd1: Connection established. size=1060290 KB / blksize=4
096 B
Apr  8 10:30:55 pig-app drbd: drbdsetup /dev/nb1 wait_connect -t 0
Apr  8 10:30:55 pig-app drbd: 'drbd_home' SyncingAll, but I have the good data. No need to
 wait.
Apr  8 10:30:55 pig-app drbd: WARNING: a cluster manager should not failover yet!
Apr  8 10:30:55 pig-app drbd: 'drbd_db' SyncPaused, waiting for this to finish
Apr  8 10:30:55 pig-app drbd: drbdsetup /dev/nb1 wait_sync
----------------------------------------------------------------------

/etc/drbd.conf (both machines identical):

resource drbd_home {
  protocol = C
  fsckcmd  = /bin/true
  disk {
    disk-size = 36708492
  }
  net {
     sync-nice  = -15  # if synchronization is high priority for you
    sync-min    = 10M
    sync-max    = 100M    # maximal average syncer bandwidth
    tl-size     = 5000  # transfer log size, ensures strict write ordering
    timeout     = 60    # 0.1 seconds
    connect-int = 10    # seconds
    ping-int    = 10    # seconds
    sync-group = 1
  }
  on pig-app {
    device  = /dev/nb0
    disk    = /dev/rd/c0d0p5
    address = 10.0.0.115
    port    = 7788
  }
  on pig-db {
    device  = /dev/nb0
    disk    = /dev/sdc1
    address = 10.0.0.114
    port    = 7788
  }
}
resource drbd_db {
  protocol = C
  fsckcmd  = /bin/true
  disk {
    disk-size = 1060290k
  }
  net {
     sync-nice  = -15  # if synchronization is high priority for you
    sync-min    = 10M
    sync-max    = 100M    # maximal average syncer bandwidth
    tl-size     = 5000  # transfer log size, ensures strict write ordering
    timeout     = 60    # 0.1 seconds
    connect-int = 10    # seconds
    ping-int    = 10    # seconds
    sync-group = 2
  }
  on pig-app {
    device  = /dev/nb1
    disk    = /dev/rd/c0d0p3
    address = 10.0.0.115
    port    = 7789
  }
  on pig-db {
    device  = /dev/nb1
    disk    = /dev/sdb1
    address = 10.0.0.114
    port    = 7789
  }
}

-- 
"Are the gods not just?"  "Oh no, child.
What would become of us if they were?" (CSL)



More information about the drbd-user mailing list