LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 08-04-2015, 01:24 AM   #1
chenjintao_ii
LQ Newbie
 
Registered: Dec 2011
Posts: 29

Rep: Reputation: Disabled
why nopreempt do not work in keepalived?


Server-A:
State - BACKUP
priority - 200
nopreempt
Server-B:
State - BACKUP
priority - 100

First of all, VIP is at Server-A.
Then i plug out Server-A's cable, so VIP is at Server-B.
Finally I plug in Server-A's cable, and Server-A preempt the VIP.

Questions:
1. It seems that the flag 'nopreempt' doesn't work, WHY?
2. What can I do if I want to forbid Server-A from preempting the VIP?
 
Old 08-04-2015, 03:33 AM   #2
Keruskerfuerst
Senior Member
 
Registered: Oct 2005
Location: Horgau, Germany
Distribution: Manjaro KDE, Win 10
Posts: 2,199

Rep: Reputation: 164Reputation: 164
You can change the behaviour of the kernel by recompiling this.
 
Old 08-05-2015, 02:25 AM   #3
chenjintao_ii
LQ Newbie
 
Registered: Dec 2011
Posts: 29

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Keruskerfuerst View Post
You can change the behaviour of the kernel by recompiling this.
I don't think recompling the kernel will fix this problem in keepalived
It seems the switch's prolem, when I re-plugin the cable, the IP address is set to eth0 immediately, but cannot ping it from other hosts in about 30 seconds. I have read the source code of keepalived and the RFC2338, If a host in BACKUP state, it should receive advertisement ARP from MASTER.
So in my case, when I re-plugin the cable of Server-A, Server-A runs into BACKUP state and waits for MASTER's advertisement, but at this time Server-A cannot link with LAN in 30 seconds, so Server-A itself become the MASTER, when it can link with other hosts, it sents advertisment ARP to them and preempt the VIP from the other hosts.

Above is my guess
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] what is the keepalived iptables port? Michael Barto Linux - Newbie 1 05-09-2015 02:32 AM
[SOLVED] keepalived can't ping virutal IP bluethundr Linux - Networking 1 03-23-2014 09:03 PM
Keepalived and Mysql Replication Jerim79 Linux - Networking 1 03-08-2012 11:26 AM
Need help ti monitor KEEPALIVED cluster hhvv Linux - Desktop 1 07-01-2008 01:11 PM
Help with keepalived!! vishamr2000 Linux - Networking 1 05-15-2007 11:50 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration