Skip to main content

Questions tagged [keepalived]

an open source daemon that implements the VRRP standard.

Filter by
Sorted by
Tagged with
14 votes
3 answers
20k views

Prevent VRRP Master from becoming Master once it has failed

I have two machines (A and B, A is Master) running VRPP (from keepalived) for a Virtual IP. How can I prevent A from becoming Master again if it has failed and come back up (for whatever reason)? I'...
MrMahgu's user avatar
  • 283
13 votes
7 answers
142k views

HAproxy 503 Service Unavailable No server is available to handle this request

I'm new to this load balancing scenario and I'm being tasked to figure out how to make this load balancing works. My environment: Centos 6.4 64 Bit Webserver: Lighttpd All running in ESXI virtual ...
Le Dude's user avatar
  • 421
13 votes
2 answers
29k views

Keepalived for more than 20 virtual addresses

I have set up keepalived on two Debian machines for high availability, but I've run into the maximum number of virtual IP's I can assign to my vrrp_instance. How would I go about configuring and ...
cvaldemar's user avatar
  • 1,136
12 votes
9 answers
75k views

View Current State of Keepalived

Is there a way to view the current state (Master/Backup) using a command line inside a server instance? Cheers
Ben's user avatar
  • 263
11 votes
3 answers
39k views

keepalived VRRP_script not failing over

So I am running keepalived on two servers and I can't get it to failover to the other. Below I have my config for one of the servers. The only different between the two is the priority numbers master ...
Nvasion's user avatar
  • 213
10 votes
1 answer
23k views

Keepalived send gratuitous ARP periodically

Is there a way for a keepalived to send gratuitous ARP periodically? We had following situation: switch failure (VLAN setup) keepalived failovered to backup instance backup instance sent gratuitous ...
user373333's user avatar
9 votes
1 answer
29k views

Keepalived's virtual_router_id - should it be unique per node?

I have two nodes running keepalived, and two VIP, e.g. Node 1 Node 2 VIP1 VIP2 So in each node, I have two definition of vrrp_instance, so I assume the two vrrp_instance in my keepalived....
Ryan's user avatar
  • 6,101
9 votes
5 answers
13k views

keepalived doesn't detect loss of virtual IP

I'm using keepalived to switch a floating IP between two VMs. /etc/keepalived/keepalived.conf on VM 1: vrrp_instance VI_1 { state MASTER interface ens160 virtual_router_id 101 ...
Gerald Schneider's user avatar
8 votes
3 answers
14k views

Any problems with having an active/active HAProxy setup with Keepalived

Apologies if this has been asked before, but I can't seem to find much on it. We're going to be using HAProxy to load balance our MariaDB Galera Cluster. All the articles/tutorials I have seen on ...
Luke Cousins's user avatar
7 votes
6 answers
24k views

keepalived nopreempt option not working

I want to use nopreempt option with keepalived vrrp setting to run backup node as master when master goes down and again reback into network. I setup nopreempt option in both servers and set state as ...
Ben's user avatar
  • 81
6 votes
7 answers
52k views

Both servers running keepalived become master and have a same Virtual IP

Both two servers started keepalived, and the BACKUP server transited to MASTER STATE immediately. both two became MASTER now. Both two nodes are sending VRRP advertisement msg. on master server: [...
riverhuang82's user avatar
6 votes
1 answer
7k views

Keepalived not sending mutlicast advertisments

I have two systems, both VMs. The are configured to use Bridged networking. I am trying to get keepalived to manage ownership of a VIP - 10.190.1.230. I have tried two versions of keepalived-1.2.2 and ...
The_Viper's user avatar
  • 163
6 votes
2 answers
5k views

UCARP: prevent the original master from taking over the VIP when it comes back after failure?

Keepalived can do this by combining the nopreempt option and the BACKUP state on the both nodes: Prevent VRRP Master from becoming Master once it has failed Prevent master to fall back to master ...
quanta's user avatar
  • 52k
6 votes
1 answer
23k views

Logging Verbosity in Keepalived.conf?

My keepalived VIP on one of my routers stopped responding. I still saw it on the primary router and not the secondary router as I would expect, and I could ping the regular IPs. As soon as I restarted ...
Kyle Brandt's user avatar
  • 84.6k
6 votes
2 answers
3k views

keepalived issues on xen domU

I cannot manage to run keepalived correctly on xen domU. I am following this link for configuration, and it works great on some local VM (running with KVM). If I set up the exact same configuration, ...
David Cournapeau's user avatar
6 votes
2 answers
4k views

keepalived master cannot reclaim virtual IP after recovered

Steps Start both master and slave Keep pinging virtual ip (i.e 192.168.10.100) Shutdown master Slave enters MASTER state Restart master Slave enters BACKUP state and Master enters MASTER state Ping ...
Franz Wong's user avatar
5 votes
2 answers
5k views

Start keepalived without IP on interface?

I want to use keepalived on an interface that will get an IP at some point but will not have one initially, can I set this up somehow in the config? If I try to start it now keepalived errors out as ...
Paul's user avatar
  • 253
5 votes
1 answer
3k views

haproxy and keepalived on Amazon EC2

The new Amazon Opsworks service uses haproxy rather than Amazon's own very limited elastic load-balancer so I started investigating haproxy as a better option for load-balancing our web app servers, ...
Marc Mangus's user avatar
5 votes
1 answer
2k views

connection sync suggestions with HAproxy and keepalived

I managed to get HAproxy working in a failover configuration as suggested on the architecture.txt document using keepalived. I used CentOS 5.5, HAproxy rpm (haproxy-1.3.25-1.el5) from epel repo, and ...
golemwashere's user avatar
5 votes
1 answer
4k views

Meaning of virtual_ipaddress_excluded in keepalived configuration

I had some problems with my keepalived configuration and found the answer in this post: Keepalived for more than 20 virtual addresses But I am not sure about the difference between virtual_ipaddress ...
chris911's user avatar
5 votes
1 answer
2k views

keepalived config is not working correctly with virtualbox vms

my keepalived configuration is not working correctly. I have two virtual testing machines (virtualbox) to try some things out with keepalived/vrrp. Bot can ping each other flawlessly (internal ...
carrot's user avatar
  • 97
4 votes
1 answer
8k views

How to configure Failover IPs for High Availability with Hetzner Online

I have a cluster of 3 Ubuntu nodes running in VMs in the lab and want to take it now to production. Hetzner Online hetzner.de offers some good value dedicated servers, so I rented 3 machines, ...
merlin's user avatar
  • 2,192
4 votes
2 answers
8k views

Per-packet round-robin load balancing for UDP

I need to load-balance UDP traffic between a number of "realservers" and do it in a truly round-robin fashion. I've started with keepalived, but unexpectedly discovered, that LVS treats UDP traffic as ...
shylent's user avatar
  • 812
4 votes
1 answer
8k views

How to use Docker with HAProxy+Keepalived?

I want to practise in creation of high-available web-application using multiple Docker containers on one machine. I launch several web-servers within Docker containers. Say, three servers rest1, ...
Charlie's user avatar
  • 141
4 votes
1 answer
10k views

How to set up tcp check with keepalived?

Trying to set up HA bastion servers. Failover, load balancing is not needed. Two servers running debian. bastion01 and bastion02. 192.168.0.10 and 192.168.0.11. Floating IP is 192.168.0.12. I started ...
cat pants's user avatar
  • 2,313
4 votes
1 answer
2k views

keepalived: what are the `fo` and `mh` lvs scheduling algorithms?

The parameter virtual_server.lvs_sched in keepalived.conf supports two options for which I can't find an explanation: fo and md. Does anyone know their meaning?
Younes's user avatar
  • 243
4 votes
1 answer
4k views

keepalived - Virtual is not routing my requests to real servers

I'm playing around with keepalived and running that setup on my master node: vrrp_instance VI_1 { state MASTER interface eth0 virtual_router_id 51 priority 150 advert_int 1 ...
Tom's user avatar
  • 41
4 votes
1 answer
7k views

Centos 7 - Keepalived Linux Virtual Server is not working

Environment: Centos 7 Keepalived Machine I enp0s3 --> 192.168.1.38 (connects to the outside world) en0s8 --> 192.168.100.101 (connects to internal network) Machine II enp0s3 --> 192.168.100....
Chayemor's user avatar
  • 151
4 votes
1 answer
9k views

keepalived: 2nd VRRP_Script never seems to run

I'm trying to implement keepalived on 3 mongodb boxes, the idea is that if mongod on one of the boxes goes down or we need to move the primary node to another system for some reason our application ...
grahamjgreen's user avatar
4 votes
1 answer
5k views

keepalived - no connect and doesn't listen on ports?

Following servers: ....:100::10 mysql1 master ....:100::20 mysql2 master ....:100::30 loadbalancer (keepalived) with virtual ip ...:100::40 Config: vrrp_instance V1 { state MASTER interface ...
da_didi's user avatar
  • 255
3 votes
2 answers
4k views

Keepalived over GRE tunnel for failover on VPS environment

I'm running an application on Linode. Their network does not support multicasting. Many tools used for failover (keepalived, spread/wackamole, hearbeat) require multicast to work (as far as I know). I'...
andrew's user avatar
  • 299
3 votes
1 answer
12k views

Keepalived router on virtual ip is not reachable

I've setup keepalived to manage a virtual ip between two hosts. My setup is the following Server #1: Hostname folmer, ip 192.168.0.1/22 dev p2p1 Server #2: Hostname flemming, ip 192.168.0.2/22 dev ...
Daniel's user avatar
  • 218
3 votes
2 answers
9k views

VIP not dropping from backup keepalived

I may not be understanding how this is supposed to work, but I can't figure out why the BACKUP system with this basic vrrp_instance is transitioning to master right away and never seems to honor the ...
Utegrad's user avatar
  • 145
3 votes
2 answers
2k views

When a server IP changes, do exising TCP (e.g. http/mysql) connections remain running

We have some PHP-FPM servers and when they need a database connection, they connect to an HAProxy server which selects them a database server to use and the connection opens. When we then want to ...
Luke Cousins's user avatar
3 votes
3 answers
5k views

keepalived shutdown - does not run "notify" hook on daemon shutdown

I'm running keepalived under Debian (Lenny, Squeeze) in a fairly simple setup, I'm just (ab)using it as a VRRP daemon to decide the mastership between two equal machines for some virtual IPs. All the ...
Michuelnik's user avatar
  • 3,510
3 votes
1 answer
10k views

HAProxy + keepalived + multiple backend farms / virtual IP addresses

we have several backend farms (HTTP, FTP, etc), basically one farm for each customer, and I am about to rebuild our load balancing infrastructure, moving from Piranha to HAProxy. Since we are using ...
moshpitcodes's user avatar
3 votes
1 answer
11k views

keepalived track_script doesn't seem to run

I'm hoping someone can see what I'm doing wrong and offer help to get a keepalived track_script to run. I have the priority set to 101 on the vrrp_instance of the primary keepalived box and 100 on ...
Utegrad's user avatar
  • 145
3 votes
2 answers
5k views

Adding IPs to Keepalived

What is the proper way to add IP addresses to a keepalived vrrp_instance without have the IPs flop around or drop for a second?
Kyle Brandt's user avatar
  • 84.6k
3 votes
2 answers
8k views

Why is keepalived running two MASTER nodes in my Sticky VIP configuration?

I have keepalived setup (floating VIP) in front of haproxy on each of my three-node galera cluster nodes. When I restart keepalived on any given node, sometimes I end up with two nodes running in ...
Server Fault's user avatar
  • 3,804
3 votes
2 answers
5k views

Prevent master to fall back to master after failure

I'm using keepalived to setup a virtual ip that points to a master server. When a failover happens it should point the virtual ip to the backup, and the IP should stay there until I manually enable (...
Chrille's user avatar
  • 483
3 votes
1 answer
689 views

Virtual IP Failover when machine is overloaded

We have been using keepalived in combination with a virtual IP address for two years now. In the rare case that a machine crashes this works very well. But when there are issues on the box itself we ...
Marco's user avatar
  • 31
3 votes
2 answers
2k views

keepalived questions (requirements, abilities, limitations)

1) What are keepalived's (physical/network) requirements? Does the two (or more) keepalived' nodes need to be connected to the same switch? (something related to broadcasting maybe). 2) Can ...
Poni's user avatar
  • 315
3 votes
1 answer
1k views

Trying to use keepalived for failover and forwarding but getting "Keepalived_healthcheckers[1706]: TCP socket bind failed. Rescheduling."

The goal is to get two different CentOS 7 VMs with keepalived installed to perform failover with VIP 192.168.1.11 and also forward the http (to become https shortly after this works) traffic to a ...
user64's user avatar
  • 31
2 votes
2 answers
9k views

KeepAlived on different subnets

I am trying to setup keepalived on ESXi based setup where 2 physical box have ESXi installed and each one having a node which works as load-balancer using HAProxy. Now in order to achieve high ...
deej's user avatar
  • 148
2 votes
3 answers
5k views

keepalived wont start

I have compiled and configured keepalived but it won't start. This is my very basic config; vrrp_sync_group PUBLIC_WEB_IPS { group { public_http_ip_lan ...
Baldrick's user avatar
  • 4,272
2 votes
1 answer
2k views

Keepalived with apache unable to bind interface on Backup server

I have two debian 6 servers running keepalived 1.1.20 with one server acting as a Master and the other as a Backup. Both servers host apache 2.4 that have a global Listener on all interfaces on port ...
davideagle's user avatar
2 votes
1 answer
3k views

Something like VRRP/keepalived without MAC address impact? (RHEL 8) [closed]

I am looking to set up a cluster (of two systems) with a VIP, just what keepalived would do. In a different context, I already have keepalived working well. However, our network team told me not to ...
Kevin Keane's user avatar
2 votes
1 answer
2k views

How would you set up multiple SSL terminating Haproxy instances, which are themselves load balanced?

I've been doing a great deal of research and experimentation on this, and I'm really running into a wall: I'm trying to set up HAProxy as the reverse proxy for a high-availability environment. All ...
Decker's user avatar
  • 123
2 votes
2 answers
3k views

Keepalived load balancing MySQL. Backup server time-out

Dear beloved people at ServerFault. I'm trying (and failing) to setup a load balanced MySQL server array. Please enlighten me, show me the error in my ways. Current setup: two MySQL servers with ...
TuxM's user avatar
  • 21
2 votes
1 answer
8k views

Keepalived: multicast vs unicast

I'm planning to deploy a several keepalived routers to maintain floating IPs for different database clusters. The plan is to deploy a separate VRRP instance on each cluster locally according to this ...
HTF's user avatar
  • 3,208

1
2 3 4 5