Currently, I am trying to run KEEPALIVED with NGINX on my machine. My use-case includes monitoring the failover behavior for NGINX server because any one instance can go down and I need to have other instance alive to serve the incoming request.
Below is my keepalived.conf
file,
vrrp_instance VI_1 {
state MASTER
interface eth0
virtual_router_id 51
priority 100
track_script {
chk_http_port
}
virtual_ipaddress {
10.100.160.143
}
}
vrrp_script chk_http_port {
script "pidof nginx"
interval 2
}
below is the error I am getting at location /var/logs/messages
Keepalived_vrrp[33045]: Cant find interface eth0 for vrrp_instance VI_1 !!!
Keepalived_vrrp[33045]: chk_http_port no match, ignoring...
Keepalived_vrrp[33045]: Default interface eth0 does not exist and no interface specified. Skipping static address 10.100.160.143.
Keepalived_vrrp[33045]: WARNING - default user 'keepalived_script' for script execution does not exist - please create.
Keepalived_vrrp[33045]: VRRP_Instance(VI_1) Unknown interface !
Keepalived_vrrp[33045]: Stopped
Keepalived[33042]: Keepalived_vrrp exited with permanent error CONFIG. Terminating
Keepalived[33042]: Stopping
Keepalived_healthcheckers[33044]: Stopped
Keepalived[33042]: Stopped Keepalived v1.3.5 (03/19,2017), git commit v1.3.5-6-g6fa32f2