How can I get a list of routers in NFA that do not have any active interfaces in a specific period of time?
search cancel

How can I get a list of routers in NFA that do not have any active interfaces in a specific period of time?

book

Article ID: 44127

calendar_today

Updated On:

Products

CA Network Flow Analysis (NetQos / NFA)

Issue/Introduction

How can I get a list of routers in NFA that do not have any active interfaces in a specific period of time?

 

 

Environment

NFA 10.x and up

Resolution

Below are the steps to generate a list of routers that do not have any interfaces that have any flow data in the last week.  You can change 604800 to any amount of seconds to adjust this to any time frame you are looking for:

 

  1. Open a command prompt on the NFA Console server.
  2. Run the command below:

mysql -P3308 -D reporter -unetqos -pnetqos -t -e "select distinct inet6_ntoa(routerAddress), devicename, id from routers where id not in (select routerid from interfaces where lastflow >= (unix_timestamp() -604800)); " > RoutersWithoutFlow1week.txt

  1.  This will create a text file in the directory where you run the command.