Script for pulling the make and signal strength of wireless cards
We are trying to continually audit our LTE cards in the Meraki Routers so we wanted to be able to monitor the stores LTE connections and see the signal strength and then determine which if any needed to be swapped out. However that data is only stored at the device level so you have to iterate through the whole Organization then by network and then by device in the network. Meraki has a polling limit for how many times you can poll the cloud per second so I put a 1 second delay in there to keep the program from overwhelming everything and causing issues for itself or for our users monitoring on the website.
The script can be found here:
How to handle common variables between programs
I have been writing a lot of python programs lately for interacting with the Meraki Platform. I was tired of copying and pasting my variables and credentials between programs, plus I wanted the ability to easily upload the programs to GitHub without having to worry about sanitizing the program of my companies or personal data. I did some searching and didn’t find a lot so what I figured I would do is put this information into a python module and then I could call that module from within my programs and then I wouldn’t have to worry about keeping all of my data secure. I decided to call my module cred.py and then I could call it from within the program with just a “import cred”. I used to copy this file into each of the directories where I was working on a program. Then I ran into a problem where I had to change an API key, I then had to go through and find all of the cred.py files I had created and then update the data in them. That proved to be more of a pain than I wanted to deal with so I decided to place it in a central directory for all of my programs. This proved much easier, but then I had to figure out how to call it from within Python without making it a module in the install path.
That is where I came up with this:
#Import the CRED module from a separate directory
With this it allows me to keep one central directory to store all of my credentials, but also commonly needed variables. I call it from within the program and can then run my programs easily. Love to hear how others are handling this or if there is a better way for me to do it.
So as attrition has struck and we have lost staff, I am now taking over Storage duties. It’s a switch right, it should work just like a network switch. That is the thinking of people above me, I think they have been away from hands on work for too long. I understand iSCSI, that’s simple. This FC stuff, I have a bit of a curve in front of me.
First order of the day…. Assess where we are and if we need a firmware update to maintain our pci compliance. Nothing like getting thrown in and going from there. Well at least I know we have Brocade Swithces so I am starting off with at least one advantage. So after finding the username and password to log into them, I then needed to find out what version we had. This website was invaluable in determing that:
If you scroll down to the comments someone has updated with the later versions, but I put the instructions here just as a quick look along with the meanings of the different Switchtypes.
Open web browser at http://hostname of switch/SwitchInfo.html
While I am surprised about the amount of information that is given away for free, I am glad that it is at least available for me to help me out.
Scroll down till you see in List of Ports: switchType: xx.x
Now at least I am off and running to the Brocade site to find out exactly how many versions I am back.
I also needed to determine the serial number so as I found out that “?” didn’t do anything for me, I then tried “help” and that listed all of the commands on the switch quite a few. I figured the command had to start with switch, chassis, or hardware. I looked through and was able to find this command:
Luckily this gives me everything I need now and can open my support case or get access to the support site to find the information for myself.