Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Can pfsense run a php command when VIP failover ?

    Scheduled Pinned Locked Moved HA/CARP/VIPs
    3 Posts 2 Posters 321 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • I
      ibysmalls
      last edited by ibysmalls

      Hi,

      Setup:
      Datacentre with 2 hypervisors, pfsense VM on each with their own Public IPs.
      VIP is on Main hypervisor, when vip fails over it doesn't work in terms of routing becasue datacentre is routing the vip to hypervisor 1 (and not 2)

      Solution is to manually go into their portal and assign the VIP IP to Hypervisor 2, when the vip goes back, manually go in and assign the ip back to hypervisor 1.

      Question:

      When VIP fails over to secondary server, can It run a php script before or after moving the vip? Datacentre provides an API and through the API I can move the ip address over.

      Thanks

      1 Reply Last reply Reply Quote 0
      • I
        ibysmalls
        last edited by

        Anyone ? :)

        1 Reply Last reply Reply Quote 0
        • jimpJ
          jimp Rebel Alliance Developer Netgate
          last edited by

          Look at /etc/rc.carpbackup and /etc/rc.carpmaster which get run when a VIP transitions to the state matching the name of the script.

          Remember: Upvote with the 👍 button for any user/post you find to be helpful, informative, or deserving of recognition!

          Need help fast? Netgate Global Support!

          Do not Chat/PM for help!

          1 Reply Last reply Reply Quote 1
          • First post
            Last post
          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.