Koozali.org: home of the SME Server

Linux-HA (High Availability) Heartbeat

guestHH

Linux-HA (High Availability) Heartbeat
« on: January 31, 2002, 11:18:14 PM »
Hi all,

I'm trying to stup up linux-ha HEARTBEAT (http://www.linux-ha.org).

I've read the docs provided on the site and followed the links. THEN I installed the RPM provided. After configuring according to the 'Getting Started' and other available documents, I got it working.... to some degree....

Both node1(Main) and node2(seconday, failover) have a fixed IP adress on eth1 (192.168.1.0) and both have a fixed IP address on eth0 (10.0.0.x heartbeat-line). Next to that the serial heartbeat link is working fine also. linux-ha (heartbeat) is configured on both machines to use ip 192.168.1.210 as 'virtuel' floating address. This is the only adress users will know and will provide services to the users.

Now for the real issue, heartbeat fail-over and fail-back mechanisms work perfectly. It takes about 5 to 10 seconds before Node2 presents itself (Fail-over)behind the virtual 192.168.210 address with it's services (which have to be configured) after I pull the plug on Node1. Same for the backwards thing (Fail-back) Samba is working well, but http service is not..... :-(

httpd is started and I can acces the 'under construction' page if i lynx to the servers real address. If I try to lynx to 192.168.1.210 (virtual address, which is pingable all the time) I get:

1. Unable to connect to remote host
2. Can't access startfile http://192.168.1.210/

Now for my questions:
1. Is (are) there a dependencies regarding the startup of the http services which i should start first.?
2. Can it be a masquerading issue?
3. Can it be a proxy/port issue?
4. Did you ever try the above before, and would you like to share info on this ?

I'm very eager to get this done, so if you even think you have a clue/hint or tip, don't hesitate to reply immediately.

Thankfully yours,

RequestedDeletion

p.s. SMEV5.1.2 OOTB is being used.
                        ^-> out of the box :-)

Damien Curtain

Re: Linux-HA (High Availability) Heartbeat
« Reply #1 on: February 01, 2002, 12:18:11 AM »
> Now for the real issue, heartbeat fail-over and fail-back
> mechanisms work perfectly. It takes about 5 to 10 seconds
> before Node2 presents itself (Fail-over)behind the virtual
> 192.168.210 address with it's services (which have to be
> configured) after I pull the plug on Node1. Same for the
> backwards thing (Fail-back) Samba is working well, but http
> service is not..... :-(
>
> httpd is started and I can acces the 'under construction'
> page if i lynx to the servers real address. If I try to lynx
> to 192.168.1.210 (virtual address, which is pingable all the
> time) I get:
>
> 1. Unable to connect to remote host
> 2. Can't access startfile http://192.168.1.210/

Whilst youve configured linux-ha for 192.168.1.210 httpd on each machine is probably only listenining to the static 192.168.1.x address given to the internal interface.

Youll might have to edit the template fragments that set the Listen directive for SSL and non SSL connections to include a virtual ip aswell as the current config which includes the loopback ip and internal interface, and add add a virtual host for 192.168.1.210 to each machine.
--
 Damien

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #2 on: February 01, 2002, 02:11:59 AM »
Hi Damien,

I like your suggestion, so i changed the /etc/httpd/admin-config/httpd.conf by adding to Listen to 192.168.1.210, and also changed /etc/httpd/conf/httpd.conf in the same manner. (I know that this should be done through custome-templates but I just wanted to see if there was any result.)

I restarted httpd by '/etc/rc.d/init.d/httpd restart' (same as Heartbeat would do)

Tryed to access http://192.168.1.210  with 'lynx 192.168.1.210' but ended up with the same results as mentioned before.......

My question now:

1. Did I understand you correctly?
2. Did I (quickly) correctly test your suggestion?
3. Are you surprised it doesn't work ?

Thanks for your swift reply and thinking!

Regards,

guestHH

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #3 on: February 01, 2002, 02:18:59 AM »
btw,

This is how the log looks like when I start (the modified httpd):

Fail-Back procedure with modified .conf
-------------------------
heartbeat: 2002/01/31_18:16:47 debug: Starting /etc/ha.d/resource.d/IPaddr 192.168.1.210/24/eth0 status
heartbeat: 2002/01/31_18:16:47 debug: /etc/ha.d/resource.d/IPaddr 192.168.1.210/24/eth0 status done. RC=0
heartbeat: 2002/01/31_18:16:50 debug: Starting /etc/ha.d/resource.d/IPaddr 192.168.1.210/24/eth0 start
heartbeat: 2002/01/31_18:16:51 debug: /etc/ha.d/resource.d/IPaddr 192.168.1.210/24/eth0 start done. RC=0
heartbeat: 2002/01/31_18:16:51 debug: Starting /etc/rc.d/init.d/smb  start
Starting SMB services: [   OK   ]
Starting NMB services: [   OK   ]
heartbeat: 2002/01/31_18:16:51 debug: /etc/rc.d/init.d/smb  start done. RC=0
heartbeat: 2002/01/31_18:16:51 debug: Starting /etc/rc.d/init.d/httpd  start
Starting httpd: heartbeat: 2002/01/31_18:16:58 debug: Starting /etc/ha.d/resource.d/IPaddr 192.168.1.210/24/eth0 status
heartbeat: 2002/01/31_18:16:59 debug: /etc/ha.d/resource.d/IPaddr 192.168.1.210/24/eth0 status done. RC=0
[   OK   ]
heartbeat: 2002/01/31_18:17:00 debug: /etc/rc.d/init.d/httpd  start done. RC=0
---------------------------

FYI, notice the difference between result OK regarding SMB and the resultof staring HTTPD? (there's nothing more to the end......)

guestHH

guestHH

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #4 on: February 01, 2002, 02:22:52 AM »
My oooooh my..................

Give that man a cigar!!!!

It works, I had to wait until ALL Heartbeat Procedure was finished!! (too quick)

I now have to figure out which fragments to 'custom-template'...... :-)

If anybody is interested in how I did this (for what it is worth...) please reply to this thread so others can join/learn/see/'listen'   :-)

Damien, THANKS for putting me on the right track!

guestHH

Kelvin

Re: Linux-HA (High Availability) Heartbeat
« Reply #5 on: February 01, 2002, 02:56:57 AM »
RequestedDeletion,

I read with great interest your application of Linux-HA. I have previously posted in the wish list before about a failover mechanism for the SME servers. This sounds like the way to go.

Here are my questions (and bear in mind, I'm a relative Linux newbie) :-

1. Is this 'true' failover ? Let me qualify that. By 'true' failover, I mean the backup / secondary server takes over all functions of the primary server that dies including DHCP, e-mails, etc. If not, what services are taken up and which ones are not ?

2. What about file storage ? Are files mirrored across servers ?

Cheers,

Kelvin

Gavin Jackson

Re: Linux-HA (High Availability) Heartbeat
« Reply #6 on: February 01, 2002, 03:19:12 AM »
Guys,

Please keep me informed of the progress with this project as it seems to be a great asset to the already bulging list of secure and useful things that SME can do

Regards,
Gavin

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #7 on: February 01, 2002, 03:20:09 AM »
Hi Kelvin,

I'm looking at:

1. Data redundancy (users data synchronised on 2 seperate servers)
2. Fail-over (hardware failure of 1 machine, another takes over)
3. Depending on what you want, many services can be redundant like SMB, HTTP, POP3, SMTP etc. etc. (matter of configuration)
4. Give the users a 'on-line backup' (so you don't have to come to the office all the time, Allrght you gyus, iff you messed up, go here and you will find a recent copy of your file/doc. Otherwise, as in REAL life you're in BAD LUCK) and that's a truth !!!!
5. Give users AND  management the 'idea' AND REAL FACT that they have a redundant system for a fraction of the costs compared to the M$ solutions....
6. LEARN about 'how to make tecnology REALLY usefull'

I'm aiming at REDUNDANT Samba, HTTP, 'NT Domain', User Accounts, User Data and application availability.

I'm now at the pont that SMB and HTTP are covered. I'LL GO FOR THE REST AS OF NOW ON!!!!!!     :-)

If you need any suggestion from my side, Contact me, or even better, open a new thread (or continue the current) so others can profit from it.

Tommorrow I will erforma test, a client will pick out a song from my 'music directory' (MP3 blade) and listen to it. All of a sudden (:-) I will switch off the server (like pulling the plug!!!!! for real) and I hope (?) that the client will experiance 'almost' no difference (while fail-over is taking place depending on winamp buffering and fail-over time (5-10 secs).

Just to let you know  :-)

guestHH

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #8 on: February 01, 2002, 03:25:04 AM »
Hi Gavin,

It's not TOO difficult, BUT you MUST be aware of the fact that knowledge, interest, dedication, trial by error is a MUST on this....

But..... it can be done! (jUST KIDDING OR NOT?)

Contribute your efforts!!! and let us know!

That's the way I learned....and STILL learning for I don't know J... S.... if a look at may different people at these forums.

GLAD you're interested and join the club. WE will let you know!

Regards,

guestHH

BK

Re: Linux-HA (High Availability) Heartbeat
« Reply #9 on: February 01, 2002, 04:22:39 AM »
Hi HS,

Just to ask. Does your configuration of HA sync the user accounts on both servers and the configuration files?

Does your HA implement NIS to sync the accounts?

Will be great if you can create a HowTo doc for this....

Jeff C

Re: Linux-HA (High Availability) Heartbeat
« Reply #10 on: February 01, 2002, 05:25:00 PM »
Please,please,please create a HowTo on this for those of us who are not as capable as you.

TIA - jeff

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #11 on: February 01, 2002, 10:08:04 PM »
BK, Jeff,

I'm working on this one. I'm in the progress of getting a 'simpel fail-over fail-back' scenario working.

Done so far:
1. Fail-over and fail-back of 2 SMEV5 server is working.
2. FO & FB of Samba and Apache is working
AS a test I want to start a MP3 and/or AVI on Node1, power off Node1 and get no interruption while Node2 is taking over. Taking over is working, but still get interruption.


Working on:
1. Data replication between the servers (Rsync or other mechanism..??)
2. Figure out what to synchronize. (Linux AND SME specific)
3. Making it a complete 'basic' solution. (someone else has to make a RPM for i can't, for I just don't know how...)

Reagrds,

guestHH

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #12 on: February 06, 2002, 01:16:41 AM »
Hi,

Still busy on this one..... Did you achieve any results ?

guestHH

Kelvin

Re: Linux-HA (High Availability) Heartbeat
« Reply #13 on: February 06, 2002, 01:39:37 AM »
Hi HF,

Sorry, I'm currently in the middle of something and could not get into this at the moment. I'll pick up on it again when I'm done here.

Kelvin

guestHH

Re: Linux-HA (High Availability) Heartbeat
« Reply #14 on: February 06, 2002, 02:19:23 AM »
Thanks for your input Kelvin,

talk to you soon.

Regards,

guestHH