Tag Archives: Cisco

Python, PHP and a Pet Project

php-code-1242330Over the past month or so I’ve been working on a personal pet project (on my own time) to parse Cisco IOS configurations. My project goal is to provide output based on a Cisco IOS configuration to help increase my own efficiency for some troubleshooting and configuration tasks at work and also possibly help others with less experience more easily sift through some of the complexities of the configuration and understand the relationships between the various elements.

In addition to the project goal stated above, I Initially was also using this project to learn Python. Once I got the basics of Python down (I really like the language) I made some solid progress, largely thanks to the outstanding ciscoconfparse Python package. However, I eventually wanted to make this project available online via this site so others could possibly benefit from the work but I couldn’t get the ciscoconfparse package to integrate with my hosting provider system even after wasting more time than I’m willing to admit or should have trying (it works fine in my development environment, the problem has something to do with Python, security and permissions on a shared host). So I’m keeping Python and the ciscoconfparse package in my technical tool belt, but I decided to switch to PHP for this project.

Switching to PHP for this project means I don’t have a nice pre-built package to provide the base framework to parse Cisco configurations and so I’ll have to build that myself. Frankly I feel my PHP skills have become stale and so this presents a good “write erase” opportunity to refresh those and learn about and use object oriented programming.

To get up-to-speed I’ve been reading through “PHP in a Nutshell” along with some other books via my Safari Books Online account (a highly recommended resource), experimenting along the way. As far as environment goes I’m using a CentOS 6.6 virtual machine with a standard LAMP base installation as my development server and a laptop running Windows 8.1 for writing code. NuSphere PhpED had everything I was looking for and more in a PHP IDE (Integrated Development Environment) and has proven to be very helpful in my development efforts.

I’ve made some headway and at a point where I want to be able to maintain revision control. Until today I had been manually taking periodic snapshots of the project files so I could recover if I broke something that had previously been working. This was quite cumbersome so I did a little research on revision control systems and settled on Mercurial since it seemed simple and appropriate for my intents and purposes. The installation was ridiculously easy on my CentOS server.

# yum install mercurial

Once Mercurial was installed I created a basic .hgrc file in my home directory on my development VM.

username = Walter Streeter <MY@EMAIL.ADDRESS>

After that the “Lone developer with nonlinear history” section of the Mercurial guide provided instruction for usage. The basic process I used is listed below including comments.

$ cd /path/to/projects/ # cd to where I keep my project hierarchy
$ hg init projectname # in my case projectname already existed with files
$ cd projectname
$ (add files) # in my case projectname already existed with files
$ hg add # told Mercurial to track all files
$ hg commit -m "Initial code base" # committed existing files
$ (made some changes) # made changes in a code file in PhpED and uploaded
$ hg diff # noted changes
$ hg commit -m "" # saved changes
$ hg log # noted history of changes
$ hg update 0 # reverted back to original code base
$ cat changedfile # confirmed file reverted
$ hg cp # note that hg should be used to copy files or folders
$ hg mv # note that hg should be used to move files or folders

That’s it for this post. I thought some others might benefit from what I’ve found and experienced so thought I’d share it. Now back to my personal pet programming project for some weekend fun doing “nerd stuff” as my wife would say.

Cisco Live 2015

Giant Cisco Live!It’s hard to believe that the first day of Cisco Live 2015 wrapped up two weeks ago today. I’m just now recovering from all the excitement and finally able to write about my experience! Joking aside, I was as excited to go to Cisco Live as a VoIP packet is to get through an LLQ and out to its destination, and I was not disappointed.


The last time I attended a “Cisco Live” it was called Cisco Networkers. My little Networker buddies here were from a couple of those years. I think the last time I went was somewhere around twelve years ago and if I remember right, only had between 5,000 and 7,000 attendees. That seems big until you consider that there were estimated to be over 25,000 at Cisco Live this year! If you’re thinking of going next year and are hesitant about large crowds don’t let that number stop you. The Cisco event teams did a great job in most cases providing information, guidance and keeping everybody moving in the right direction.

There are many reasons one might want to consider spending the money to attend Cisco Live. My reasons include the following which I’ll briefly (hopefully) summarize.

  • Education and Learning
  • Vendor Exhibits
  • Professional Networking (and Food and Drinks)

Education and Learning

The main reason I wanted to attend was for the breakout sessions. I only managed to fit in 11 out of over 700 available sessions into the week. The eleven sessions I attended were all outstanding, although some more than others. Another thing about the sessions is they are often lead by key engineers. For instance, the “Advanced Concepts of DMVPN” session I attended was presented by the Principle Architect of the DMVPN solution, Mike Sullenberger. He also sat in on the very helpful “Troubleshooting DMVPNs” session presented by Ranjana Jwalaniah.

With that stated, in hindsight I wish I would’ve left some more time open to explore other offerings including everything available in “The Hub” which makes available 30-minute hands-on labs, meet the expert engineering sessions and several other opportunities. The next time I go I plan to schedule some time specifically to explore some of the many other available learning activities.

Next there are the keynotes, three of the four of which I found to be outstanding this year. The first one was Monday at the end of the day. This is typically the keynote where Cisco’s vision is shared. This year was extra special as it was John Chambers’ last year at Cisco Live as CEO. It was interesting to see the Cisco vision presented while at the same time seeing the baton being handed off from John Chambers to Chuck Robbins. Only time will tell the accuracy of their vision, however, I would hazard to guess that security is going to be a very important and integral part of IT and networking for a long time to come (which is why I’m already focused on a security certification track). The Peter Diamandis and Mike Rowe keynotes were also outstanding.

Much more could be said on this topic. But suffice to say, if you go for education, learning and a glimpse at Cisco’s vision you will not be disappointed.

Vendor Exhibits – World of Solutions (and Swag!)

Another highlight for me this year was the World of Solutions, the area where vendors show off their wares. There was plenty to see and experience, a glimpse of which can be seen in the photos below.20150611_114209









Most of the vendor swag was fun and the best I’ve seen in a long time, it beat NAB by a long shot! I’ve included a photo but it only includes maybe a quarter of the items I gathered. I came back with at least four decent T-shirts and the coveted Plixer/Scrutinizer NetFlow Knight action sword (it lights up and makes sword sounds). It was funny on my way home seeing all the people in the airport with them. I packed mine in my checked bag because I wasn’t sure if TSA would find them amusing and I didn’t want to risk losing it. There’s a lesson to be learned in that, pack strategically leaving room for more for the return trip!






In addition to the swag many of the vendors had drawings for various prizes throughout the week. I managed to win a prepaid $50 VISA card! Pretty sweet!

And of course there is the pure joy of stacks and racks of equipment!

Professional Networking (and Food and Drinks)

Finally, it’s nice to get around other network professionals to share network “war stories” and creative solutions…. while grabbing a bit to eat and something to drink. I don’t drink alcohol but for those that do, beer and other drinks flow pretty freely at many various events and vendor meets and parties. I enjoyed some great food, like the bajah shrimp bucket pictured below!


An then there’s the Little Italy district of San Diego where my hotel was located! You know your food is authentic Italian when the staff are speaking Italian and there’s a sign over the road that reads “Little Italy!”








I would be remiss if I didn’t mention that there was also an opportunity to help others in need by working with others at Cisco Live to make and pack meal kits for Stop Hunger Now. The original goal was to package 25,000 meals total. However, that goal got blown away in the two days this initiative ran with 100,000 meal kits packaged and boxed!



Cisco Live was a great experience and I’m thankful for having had the opportunity to attend this year. So much more could be said about it, but there isn’t time. Besides, don’t take my word for it, see for yourself and attend Cisco Live 2016!