[DRBD-user] Newbie Question

Allen Chen allen.chen at csagroupllc.com
Thu Nov 6 18:23:51 CET 2008

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


One small question, I'm trying to get a good picture before I go ahead
and reinstall the systems. You have a '/', swap, and <drbd> partition on
each disk, but the partition settings complains when I try to put two
'/' partitions on one system. Does this even matter, since as I
understand the secondary '/' and swap are only occupying blocks to be
consistent w/ the primary.


On Thu, 2008-11-06 at 15:15 +0000, Mark Watts wrote:
> On Thursday 06 November 2008 14:44:05 Allen Chen wrote:
> > Hi,
> >
> > I am new to drbd, but it seems like something I'd like to use.
> >
> > I'm not sure where I should have found info about this so I hope this is
> > the place...
> >
> > >From the tutorial:
> >
> > resource r0 {
> >   on alice {
> >     device    /dev/drbd1;
> >     disk      /dev/sda7;
> >     address   10.1.1.31:7789;
> >     meta-disk internal;
> >   }
> >
> > How do I decide what the disk is? Is this something I have to decide and
> > set during partition and install of the OS?
> 
> Yes.
> 
> > Right now I have two servers 
> > with 2 hard drives each. I would like one server to be development server
> > and one to be database server, each using one hard disk. The remaining two
> > hard disks would be the drbd 'backup' of the other, and cross the servers
> > so the backups would be on different servers. Hence one server would be
> > primary development/secondary database, while the other one is primary
> > database/secondary development. I am running Red Hat EL 5.2. While
> > partitioning I set a partition /backup for the secondary disk, with the
> > intention that /backup is where the secondary drbd image goes.
> 
> You can do this, but its a little complicated. (And performance may stink)
> 
> The way I'd probably approach it is thus: (Assuming, for example, 100GB disks)
> 
> 	Partition 1 = 10GB = /
> 	Partition 2 = 2GB = Swap
> 	Partition 3 = 88GB = <drbd>
> 
> You'd configure the exact same partition layout on *ALL* disks, even though 
> you won't be using / and swap on the secondary disk in each node.
> (This is to ensure that the actual partition you're replicating has the same 
> block-count on each disk).
> 
> If you have /dev/sda and /dev/sdb, you'd have a drbd.conf like this:
> 
> resource r0 {
> 	device	/dev/drbd0;	
> 	meta-disk internal;
> 	on server1 {
> 		disk      /dev/sda3;
> 		address   10.1.1.1:7789;
> 	}
> 	on server2 {
> 		disk      /dev/sdb3;
> 		address   10.1.1.2:7789;
> 	}
> }
> 
> resource r1
> 	device	/dev/drbd1;	
> 	meta-disk internal;
> 	on server1 {
> 		disk      /dev/sdb3;
> 		address   10.1.1.1:7790;
> 	}
> 	on server2 {
> 		disk      /dev/sda3;
> 		address   10.1.1.2:7790;
> 	}
> }
> 
> 
> One key assumption of course, is that you have two independant database 
> configurations, so that both database instances can potentially be running on 
> the same node at the same time.
> 
> Mark.
> 
> _______________________________________________
> drbd-user mailing list
> drbd-user at lists.linbit.com
> http://lists.linbit.com/mailman/listinfo/drbd-user


87
10699


More information about the drbd-user mailing list