Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: DRBD: Users

Automatic Primary

 

 

DRBD users RSS feed   Index | Next | Previous | View Threaded


jlillard at ghfllc

Aug 13, 2012, 2:34 PM

Post #1 of 4 (769 views)
Permalink
Automatic Primary

I have a three node setup all running Ubuntu 12.04 and DRBD 8.3.11. I have
the drbd service configured to not startup automatically. Instead I launch
it with post-up commands in /etc/network/interfaces via modprobe drbd
followed by drbdadm up all. This works fine. All three nodes startup and
resync after a reboot. But they are all in the secondary role as expected.
On my primary node I have another interface defined that I use as an NFS
target for my ESXi hosts. I do this so if something happened to the
primary node I could manually bring up the secondary node in its place.
The first post-up command I have is drbdadm primary all. Unfortunately
when I reboot the server something about this causes the boot process to
hang. It claims it is waiting for the network to start up. While it is
doing this I can connect into the server just fine remotely but in the end
it doesn't execute any of the post-up commands for eth1. However, I can
run each command individually from the command line and they completely
quickly and without error. So for now I have removed those post-up
commands and put them in a script I manually run when I reboot the server.
Of course this does me no good if the server is rebooted for some other
reason.

Looking through the syslog I can't seem to find any indication why the
drbdadm primary all would fail when it's run at boot time. Any suggestions?

--
J.R. Lillard
System / Network Admin
Web Programmer
Golden Heritage Foods
120 Santa Fe St.
Hillsboro, KS 67063


akos.csurai at ericsson

Aug 14, 2012, 1:43 AM

Post #2 of 4 (729 views)
Permalink
Re: Automatic Primary [In reply to]

Hi,

Just an idea:
Last time when I see such a situation, someone suggested to print out
the env ... and there
I could see that the script was running in a wrong path. NFS was
temporary unavailable and that caused
the script "hanging"

Akos

On 08/13/12 23:34, J.R. Lillard wrote:
> I have a three node setup all running Ubuntu 12.04 and DRBD 8.3.11. I
> have the drbd service configured to not startup automatically.
> Instead I launch it with post-up commands in /etc/network/interfaces
> via modprobe drbd followed by drbdadm up all. This works fine. All
> three nodes startup and resync after a reboot. But they are all in
> the secondary role as expected. On my primary node I have another
> interface defined that I use as an NFS target for my ESXi hosts. I do
> this so if something happened to the primary node I could manually
> bring up the secondary node in its place. The first post-up command I
> have is drbdadm primary all. Unfortunately when I reboot the server
> something about this causes the boot process to hang. It claims it is
> waiting for the network to start up. While it is doing this I can
> connect into the server just fine remotely but in the end it doesn't
> execute any of the post-up commands for eth1. However, I can run each
> command individually from the command line and they completely quickly
> and without error. So for now I have removed those post-up commands
> and put them in a script I manually run when I reboot the server. Of
> course this does me no good if the server is rebooted for some other
> reason.
>
> Looking through the syslog I can't seem to find any indication why the
> drbdadm primary all would fail when it's run at boot time. Any
> suggestions?
>
> --
> J.R. Lillard
> System / Network Admin
> Web Programmer
> Golden Heritage Foods
> 120 Santa Fe St.
> Hillsboro, KS 67063
>


--
This communication is confidential and intended solely for the addressee(s). Any unauthorized review, use, disclosure or distribution is prohibited. If you believe this message has been sent to you in error, please notify the sender by replying to this transmission and delete the message without disclosing it. Thank you.
E-mail including attachments is susceptible to data corruption, interception, unauthorized amendment, tampering and viruses, and we only send and receive emails on the basis that we are not liable for any such corruption, interception, amendment, tampering or viruses or any consequences thereof.

Ericsson Magyarország Kft., Székhely: 1097 Budapest, Könyves Kálmán krt. 11. B. épület. Nyilvántartó cégbíróság: Fővárosi Bíróság. Cégjegyzékszám: 01-09-070937

_______________________________________________
drbd-user mailing list
drbd-user [at] lists
http://lists.linbit.com/mailman/listinfo/drbd-user


akos.csurai at ericsson

Aug 14, 2012, 3:22 AM

Post #3 of 4 (726 views)
Permalink
Re: Automatic Primary [In reply to]

Hi,

Just an idea:
Last time when I see such a situation, someone suggested to print out
the env ... and there
I could see that the script was running in a wrong path. NFS was
temporary unavailable and that caused
the script "hanging"

Akos

On 08/13/12 23:34, J.R. Lillard wrote:
> I have a three node setup all running Ubuntu 12.04 and DRBD 8.3.11. I
> have the drbd service configured to not startup automatically.
> Instead I launch it with post-up commands in /etc/network/interfaces
> via modprobe drbd followed by drbdadm up all. This works fine. All
> three nodes startup and resync after a reboot. But they are all in
> the secondary role as expected. On my primary node I have another
> interface defined that I use as an NFS target for my ESXi hosts. I do
> this so if something happened to the primary node I could manually
> bring up the secondary node in its place. The first post-up command I
> have is drbdadm primary all. Unfortunately when I reboot the server
> something about this causes the boot process to hang. It claims it is
> waiting for the network to start up. While it is doing this I can
> connect into the server just fine remotely but in the end it doesn't
> execute any of the post-up commands for eth1. However, I can run each
> command individually from the command line and they completely quickly
> and without error. So for now I have removed those post-up commands
> and put them in a script I manually run when I reboot the server. Of
> course this does me no good if the server is rebooted for some other
> reason.
>
> Looking through the syslog I can't seem to find any indication why the
> drbdadm primary all would fail when it's run at boot time. Any
> suggestions?
>
> --
> J.R. Lillard
> System / Network Admin
> Web Programmer
> Golden Heritage Foods
> 120 Santa Fe St.
> Hillsboro, KS 67063
>


--
This communication is confidential and intended solely for the addressee(s). Any unauthorized review, use, disclosure or distribution is prohibited. If you believe this message has been sent to you in error, please notify the sender by replying to this transmission and delete the message without disclosing it. Thank you.
E-mail including attachments is susceptible to data corruption, interception, unauthorized amendment, tampering and viruses, and we only send and receive emails on the basis that we are not liable for any such corruption, interception, amendment, tampering or viruses or any consequences thereof.

Ericsson Magyarország Kft., Székhely: 1097 Budapest, Könyves Kálmán krt. 11. B. épület. Nyilvántartó cégbíróság: Fővárosi Bíróság. Cégjegyzékszám: 01-09-070937

_______________________________________________
drbd-user mailing list
drbd-user [at] lists
http://lists.linbit.com/mailman/listinfo/drbd-user


jlillard at ghfllc

Aug 14, 2012, 7:58 AM

Post #4 of 4 (722 views)
Permalink
Re: Automatic Primary [In reply to]

The only difference between the machine booting normally and hanging while
starting the network is this line in /etc/network/interfaces.

post-up drbdadm primary all

So for some reason attempting to become the primary so quickly results in a
delay of some sort. I also tried adding become-primary-on to my resource
config but it seemed to ignore that as well.

On Tue, Aug 14, 2012 at 3:43 AM, Csurai Akos <akos.csurai [at] ericsson>wrote:

> Hi,
>
> Just an idea:
> Last time when I see such a situation, someone suggested to print out the
> env ... and there
> I could see that the script was running in a wrong path. NFS was temporary
> unavailable and that caused
> the script "hanging"
>
> Akos
>
>
> On 08/13/12 23:34, J.R. Lillard wrote:
>
>> I have a three node setup all running Ubuntu 12.04 and DRBD 8.3.11. I
>> have the drbd service configured to not startup automatically. Instead I
>> launch it with post-up commands in /etc/network/interfaces via modprobe
>> drbd followed by drbdadm up all. This works fine. All three nodes startup
>> and resync after a reboot. But they are all in the secondary role as
>> expected. On my primary node I have another interface defined that I use
>> as an NFS target for my ESXi hosts. I do this so if something happened to
>> the primary node I could manually bring up the secondary node in its place.
>> The first post-up command I have is drbdadm primary all. Unfortunately
>> when I reboot the server something about this causes the boot process to
>> hang. It claims it is waiting for the network to start up. While it is
>> doing this I can connect into the server just fine remotely but in the end
>> it doesn't execute any of the post-up commands for eth1. However, I can
>> run each command individually from the command line and they completely
>> quickly and without error. So for now I have removed those post-up
>> commands and put them in a script I manually run when I reboot the server.
>> Of course this does me no good if the server is rebooted for some other
>> reason.
>>
>> Looking through the syslog I can't seem to find any indication why the
>> drbdadm primary all would fail when it's run at boot time. Any suggestions?
>>
>> --
>> J.R. Lillard
>> System / Network Admin
>> Web Programmer
>> Golden Heritage Foods
>> 120 Santa Fe St.
>> Hillsboro, KS 67063
>>
>>
>
> --
> This communication is confidential and intended solely for the
> addressee(s). Any unauthorized review, use, disclosure or distribution is
> prohibited. If you believe this message has been sent to you in error,
> please notify the sender by replying to this transmission and delete the
> message without disclosing it. Thank you.
> E-mail including attachments is susceptible to data corruption,
> interception, unauthorized amendment, tampering and viruses, and we only
> send and receive emails on the basis that we are not liable for any such
> corruption, interception, amendment, tampering or viruses or any
> consequences thereof.
>
> Ericsson Magyarország Kft., Székhely: 1097 Budapest, Könyves Kálmán krt.
> 11. B. épület. Nyilvántartó cégbíróság: Fővárosi Bíróság. Cégjegyzékszám:
> 01-09-070937
>
>


--
J.R. Lillard
System / Network Admin
Web Programmer
Golden Heritage Foods
120 Santa Fe St.
Hillsboro, KS 67063

DRBD users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.