Forum Discussion

mwsmith87's avatar
mwsmith87
Icon for Nimbostratus rankNimbostratus
Oct 12, 2018

Ansible bigip_command to check connections on Node

I am trying to evaluate how many active connections are on a Node using the bigip_command module but it is failing. My playbook contains the following task:

   - name: Check connections
     bigip_command:
       commands:
         - show sys connection ss-server-addr 192.168.20.10 ss-server-port 80
       wait_for:
         - result[0] contains 0
       chdir: TESTING
       validate_certs: "false"
     register: result

When ran with the -vvv option it shows that one or more conditions have not been satisfied, but the node shows 0 connections from the cli. Any ideas what I have wrong here or any other ideas on how to accomplish this task? The bigger goal of this particular playbook is to force a node offline and ensure that all of the connections have "bled" off before performing maintenance on the server.

No RepliesBe the first to reply