CategoryHorrible Rant

Cellular backup (again) via Google’s Project Fi, a Cisco 3825 and an HWIC-3G-GSM

I get really poor signal with TMo and Sprint in my area, but I am using Project Fi for my cellular service. I figured I’d grab one of their free SIMs and put my HWIC-3G-GSM back in service. Unfortunately.. I get really poor signal. Like -102dB RSSI! I’m going to have to see if I can get a cheap TNC antenna with a cord long enough to put it outside; for some reason I can get good signal according to my Nexus 5X — even getting LTE just by stepping outside.

For now I figured I’d get the basic configuration done. Even with little to go by it was fairly easy to setup — especially as most cell carriers don’t have PAP/CHAP authentication.


router(config)#
chat-script gsm "" "ATDT*99#" TIMEOUT 30 CONNECT
!
interface Cellular0/0/0
 description Project Fi - TMobile
 ip address negotiated
 ip nat outside
 ip virtual-reassembly in
 encapsulation ppp
 dialer in-band
 dialer idle-timeout 360 either
 dialer string GSM
 dialer-group 1
 async mode interactive
 ppp chap hostname h2g2
 ppp chap password 0 ""
 ppp ipcp dns request
!
ip nat inside source list 1 interface Cellular0/0/0 overload
ip route 0.0.0.0 0.0.0.0 Cellular0/0/0
!
access-list 1 permit any
dialer-list 1 protocol ip list 1
!
line 0/0/0
 script dialer GSM
 modem InOut
 no exec
 rxspeed 3600000
 txspeed 384000
!
^Z


router#cellular 0/0/0 gsm profile create 1 h2g2 

Note that you can also pass authentication information in the GSM profile creation; however that isn’t needed for Project Fi.

This was a basic test just to see if I could get connectivity, I’m going to use it as an alternate route to the big cloud that is the internet in the event that I really need access and Time Warner Cable has let me down by abusing maintenance windows daily — as seems to be the case lately!

So far I’ve run into issues; I’d disconnect from the network and not be able to reconnect. Sometimes a modem power-cycle fixes this. I decided to upgrade the crusty old firmware to something slightly less crusty (note: I hate Sierra Wireless modems) — Cisco says “not for use in the US,” however it IS listed for the MC8775 modem on my HWIC and I know people have used it for the same modem in ThinkPads (trusty T61/T61p!) in the US. I couldn’t get it through Cisco as you need a support contract for Sierra Wireless firmware, oddly enough. I was able to find it online, you’d be looking for version 2.0.8.19 — generally named 8775_h2_0_8_19.tar. This of course will depend on the modem in your HWIC as they didn’t all come with MC8775s.

Check your hardware! It’s easy enough to see what modem is on your HWIC even if you don’t want to physically pull it to check it:

cell.wan#sh controllers cellular 0/0/0
Interface Cellular0/0/0
HSDPA/UMTS/EDGE/GPRS-850/900/1800/1900/2100MHz unit 0, 
HWIC cellular modem configuration:
---------------------------
Modem is recognized as valid for this HWIC
manufacture id: 0x00001199 product id: 0x00006812
Sierra Wireless MC8775 UMTS modem.
GPS State: GPS disabled

Pre-upgrade:

cell.wan#sh cell 0/0/0 hardware
Modem Firmware Version = H1_1_8_3MCAP C:/WS/F
Modem Firmware built = 03/08/07
Hardware Version = 1.0
International Mobile Subscriber Identity (IMSI) = NUMBERSHERE
International Mobile Equipment Identity (IMEI) = NUMBERSHERE
Integrated Circuit Card ID (ICCID) = NUMBERSHERE
Mobile Subscriber International Subscriber
IDentity Number (MSISDN) = NUMBERSHERE
Factory Serial Number (FSN) = NUMBERSHERE
Modem Status = Low Power Mode
Current Modem Temperature = 23 deg C, State = Normal
PRI SKU ID = 0, SKU Rev. = 20.0

Upgrade process:

cell.wan#microcode reload cellular 0 0 gsm modem-provision
Reload microcode? [confirm]
Log status of firmware download in router flash?[confirm]
Firmware download status will be logged in flash:fwlogfile
Microcode Reload Process launched for hwic slot=0; hw type=0x51E
cell.wan#
*****************************************************
 The interface will be Shut Down for Firmware Upgrade 
 This will terminate any active data connections.
 Do not make any config changes related to the interface.
*****************************************************
Modem radio has been turned off
*****************************************************
 Modem will be upgraded!
 Upgrade process will take up to 15 minutes. During 
 this time the modem will be unusable.
 Please do not remove power or reload the router during 
 the upgrade process.
*****************************************************
backing up NV data..Could take up to 3 minutes
*Aug 23 10:18:06.423: %LINK-5-CHANGED: Interface Cellular0/0/0, changed state to administratively down++++++++++++++++++++++++++++++
Prepare modem for downloading boot image.
Begin boot image download
Firmware [size:234279 bytes] will be downloaded in 228 segments
Sync indication Successful
Sync indication Successful
***** Boot File Upgrade OK *****
******************************************
The firmware file will be copied in blocks 
from Compact Flash. Please DO NOT remove 
Compact Flash during Upgrade Process. Doing 
so will cause download failure and leave 
modem in unusable state
*******************************************
Begin application image download
Firmware [size:13393280 bytes] will be downloaded in 13129 segments
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Sync indication Successful
Sync indication Successful
***** Application Firmware Upgrade OK *****
Modem Upgrade OK
*Aug 23 10:25:30.179: %CELLWAN-2-MODEM_DOWN: Modem in HWIC slot 0/0 is DOWN
*Aug 23 10:25:46.963: %CELLWAN-2-MODEM_UP: Modem in HWIC slot 0/0 is now UP
*Aug 23 10:25:46.963: %CELLWAN-2-MODEM_DOWN: Modem in HWIC slot 0/0 is DOWN
*Aug 23 10:26:00.191: %CELLWAN-2-MODEM_UP: Modem in HWIC slot 0/0 is now UP
Modem radio has been turned on
*Aug 23 10:26:44.587: %LINK-3-UPDOWN: Interface Cellular0/0/0, changed state to down

Post-upgrade:

cell.wan#sh cellular 0/0/0 hardware
Modem Firmware Version = H2_0_8_19MCAP G:/WS/
Modem Firmware built = 08/29/08
Hardware Version = 1.0
International Mobile Subscriber Identity (IMSI) = NUMBERSHERE
International Mobile Equipment Identity (IMEI) = NUMBERSHERE
Integrated Circuit Card ID (ICCID) = NUMBERSHERE
Mobile Subscriber International Subscriber
IDentity Number (MSISDN) = NUMBERSHERE
Factory Serial Number (FSN) = NUMBERSHERE
Modem Status = Online
Current Modem Temperature = 27 deg C, State = Normal
PRI SKU ID = 9991803, SKU Rev. = 1.3

The 2.0.8 line increases the HSDPA downlink speed from 3.6mbit/s to 7.2mbit/s (assuming your signal is acceptable, of course). I’m just hoping it stabilizes my connection and I don’t have to do any actual debugging! After installing the firmware update I had no problems bringing a connection up. So far it seems “more stable,” but only time will tell if it randomly drops. It also gives more information from “show cellular 0/0/0” ..

Once I get an antenna and (hopefully) better signal so I can maintain “usable,” speeds for basic browsing I’ll throw it in the routing table. For now, it can sit to the side as a novelty.

4K Is AWESOME!!

I mean this in the terms of a developer/network engineer. As far as media I’m sure it WILL be great once we can get fed >100mbit HVEC streams. For the time being with no content test footage is not really knocking my socks off.

But with a pair of 24″ 4K monitors there is SO much I can fit on the screen and check at a glance that I was unable to do before. I’ve had some pretty good monitor setups for a while (4x1080p + 1440p in the center), so while I haven’t really gained that many pixels I HAVE made it easier to see them. Ironically some people may find that to not be the case if they have vision problems, and I’m sure in another 10 or 15 years 24″ 4k will aggravate me for that same reason. There have been a multitude of posts from developers about the awesomeness of 4k, so I won’t go into too much detail. But it really increases my work efficiency — if only I had something like this at my job!

Even when working with network lab setups it’s great having that many console windows actually open and visible, with a browser up where I can actually read the content.. and graphs chugging along in the NMS while I can watch syslog messages through Graylog2 in another pane. This simply wouldn’t be possible with less than 16.5 million pixels on a screen smaller than 39″. I know because I ran ~8MP worth of 1080p + 3.7MP in a 1440p. I could do almost as much, but I was constantly either craning my neck around due to the sheer area involved (a 27″ monitor flanked 21″ 1080 monitors is really not all that easy to work practically with) or opening and closing windows as needed.

And yet, despite all that awesomeness I do hate my UP2414Q, MST (Multi-Stream Transport) is annoying. The monitor will occasionally do all kinds of crappy things (like only use the right half of the image and stretch it across the whole screen, or decide to only apply color calibration on the right pane). I can’t wait for ~28″ IPS SSTs to arrive. I’d really like the pixel density to stay high, but I could settle for 3840×2160 @ 28″ (4320×2430 would be preferred). MST works by splitting the monitor into two 1920×2160 panels, wreaking all kinds of havoc at the worst times. It’s really disappointing spending that much on a piece of equipment and dealing with this much buginess — that is what you get for being an early adopter, though. And despite that and all the annoyances and hate, I still wouldn’t trade it in for a monitor with less pixels.

As for gaming.. it just makes my GTX 670 FTWs wish I never bought them, I hit the 2GB VRAM limit with ease in most games. Even when I’m under the VRAM limit it can barely drive most games even in 3-way SLI. There’s just so many pixels. Keep in mind SLI scaling is better than with a 1080p monitor since it can make more efficient use of each GPU, but there really just needs to be more graphics rendering hardware. I’m definitely going to need atleast a pair of high-end next-generation GPUs in SLI to properly drive this thing at reasonable framerates. Hopefully GM200 8GB cards come out soon.. but I’m sure they won’t be ‘affordable’ (sub-$1000 per card) for a couple years.

PHP, Screen Scraping & SevOne Deferred Data — or a Network Operator/Engineer That Can Do More Than Networks! (Possible Rant)

This post is semi work related, but I do have SevOne running at home as my NMS for graphing, trending and alerting. There are some statistics that I insert via their ‘deferred data,’ which is done through a (fairly horrible) SOAP API. Before Cablevision I hadn’t written a line of PHP, or used SOAP in any language — but all of the SevOne examples were written in PHP. I picked it up to write some scripts that insert data from CMTS (Cable Modem Termination Systems) that were not available  through SNMP which was really helpful in our monitoring and alerting.  As I do have some kind of programming background it wasn’t difficult to pickup the ‘beginners,’ scripting language. Eventually I wrote a class to encapsulate a bunch of stuff that I do to interface with SevOne as we could really spike the CPU usage if we did things by way of their example scripts.

The entire CMTS script involved me writing a telnet wrapper that uses socket calls and is entirely written in PHP. This was probably a naive approach and a stream to telnet would’ve been much better (as we will be moving to SSH anyway), although it did allow me to flex some critical thought muscles I forgot I had and haven’t been used in some time. After some tuning it’s actually pretty fast and doesn’t present a bottleneck or resource drain. Eventually even the telnet functions got expanded on considerably into a couple of classes for accessing data on IOS and Arris C4. The IOS functions got expanded on to parse data for some critical things for CMTS-specific stuff, then for other pieces of equipment (ie 7600/6500). The base telnet class was later extended to IOS-XR for ASR9K devices. Then NX-OS. A flexible SNMP wrapper was created primarily for polling STB (Set Top Boxes). I got pretty good at writing PHP in a time-efficient manner to parse all kinds of stuff. As a “network operator,” this was great! I could get all kinds of statistics that would normally be “impossible,” or really “time-intensive. The SevOne stuff expanded and got refined as I dug more into my programming background.  Even as I was using a fairly clumsy language without formal training I had a good idea of how to write EFFECTIVE PHP (in my mind anyway). Parts of it might be ugly, but it gets the job done. I became adept at writing regular expressions, I even dynamically generated it based on the output so it would be extremely easy to update in the future and could even deal with a good deal of changes without being updated. I wrote SevOne wrappers to generate (or update) hundreds of threshold alarms at a time that would otherwise take a LOT of man hours to manually input. I wrote scripts to poll SevOne for information so we could figure out how to most effectively utilize our servers, or just to look at devices for certain criteria.. things that we wouldn’t be able to do an effective manner otherwise.

That’s a lot of background, but the end result: I created a great SevOne Deferred Data wrapper that caches a lot of information to cut back on CPU hits to the SevOne servers. It connects to peers dynamically as required to cut back on CPU. It takes a lot of work away from SevOne that might otherwise be (naively) processed on SevOne’s side. I know because I did it. And we pegged CPU cores on our SevOne boxes. We ran into so many issues. Because of that we were unable to do what we needed to do without some of these (admittedly somewhat minor) innovations. For Cablevision it’s amazing. For me, it allows a great amount of work in small amounts of time. All of the SevOne nitty-gritty is abstracted away and done automagically. Things are created on the fly, SOAP calls that might generate an exception (and this happens often) are automatically retried depending on the error. There’s little need for error checking in a script that screen scrapes to collect data. In my mind that’s an example of a great piece of code, it doesn’t make you think about what you’re doing with something. It does what you expect of it (for the most part). When upper management asks for something I look good because I can get it to them extremely quickly. When SevOne says it will take months for their Professional Services division to create something or cost some obscene amount of money, I’m there offering a quick solution which is cheap for them. Maybe that’s not great, but I like doing my job well.

I’m not the best programmer ever. I’m not a scripting pro. I don’t know that many scripting languages, but I can pick them up fairly quickly. I’ve never touched Python. I can whip things up in Ruby (ON RAILS EVEN!) but I’m not a Ruby guru. I can write shell scripts but I’m not extremely proficient in BASH, nevermind TCSH, KSH or any of the others. I’m not really a network engineer. But combining my general purpose background has allowed me to do things that might not otherwise be possible. Certainly your regular CCNP or CCIE carrying network guy is not going to have quite the scripting background to get the data required into an NMS — and your regular programmer is not going to have enough of an idea about network devices or the network in general to have a good understanding of what might need to be collected into the NMS.  At home I want to monitor some things on my VM server that aren’t available through SNMP. I could write scripts and custom OIDs to access them through SNMP but that requires configuration on the SevOne side. It’s much faster for me to use my wrapper to insert the data I need (a good example — CPU wattage).

I realize this post is more of a rant than usual, but feel free to check the wrappers out at SevOne PHP Wrappers

 

 

© 2017 Musings

Theme by Anders NorenUp ↑