A Quick Post on Being Nice

There was a nice e-mail on the opennms-install list today. The install list is our “newbie” list, as the first hurdle to jump with OpenNMS is to get it installed, and a person had posted a question about a Debian install.

The question was well worded, and while I couldn’t explain the problem the person was having with importing our GPG key to apt, I was able to quickly test a workaround on my desktop and offer it to the list.

Here is the reply we received:

I wanted to thank everyone for helping me with this issue. Obviously, I am new to this and just trying to learn. I asked a question on a different listserv (for a different monitoring software package I was testing) and all I received were snarky responses and little to no help…how discouraging! That definitely was not the case here!!!

I went with Tarus’ instructions and they worked just fine. The rest of the tutorial was spot on for me and no issues. I now have a few nodes scanned and am just loving the interface and how it feels.

I have been involved in open source for a very long time now, and I have to say that his experience with “snarky responses” is all too common. We have always made the best effort to be open and friendly to new users, since they will be the old users of the future.

But I can understand how this happens. No sooner had I read the post then someone else hijacked the thread with a “it don’t work help me plz” question.

(sigh)

I tried not to be snarky when I replied, asking the user to start a new thread by sending a new message to the list. Was it too much to point them to esr’s “How to Ask Questions” document?

I also felt the need to stress that any direct replies to me would be ignored. While this doesn’t happen with most users on the list, usually the ones that need a little more help latch on to the first person to reply and start peppering them with questions to their direct e-mail address.

I never feel right answering those, since our business model is for a large part built on providing commercial support services, so in order to ask me a direct question I want you to have a support contract. Not because I’m greedy, but because I want to be fair to the people who put food on my table.

But the list is different. Since it is shared I feel like I am answering not only the question at hand but almost all future versions of that question.

It’s really hard to balance limited time with virtually unlimited needs, but if someone politely asks a well-formed question on the list, I do my best to answer it.

Who knows, perhaps one day in the future they’ll answer a question of mine.

Managing Complex Configurations with XML ENTITY

UPDATE: Alejandro discovered that this method doesn’t work if you use Scheduled Outages as the webUI will write back the file as a single one and not preserve the ENTITY imports.

While we have made some serious strides toward making the OpenNMS configuration more modular, from my own humble contribution of include files in eventconf.xml, to breaking up datacollection-config.xml and snmp-graph.properties, we still have some way to go to finish it for the rest of the application.

However, you can leverage a shortcut built into the XML standard to help manage files that can get complex. It allows you to import XML from one file to another.

It does have a limitation. Unlike the work we did with datacollection-config, etc., where we combined different parts of a configuration (generic resources, MIB object groups and system definitions) into separate files, this will only work if you can life whole sections out into other files.

One example would be the poller-configuration.xml file where you can remove entire sections. Here’s how you do it.

First, at the top of the file, you have to define the files you want to include:

<!DOCTYPE root [
  <!ENTITY pkg_Network-Connectivity SYSTEM "./etc/poller-configuration.d/pkg_Network-Connectivity.xml" >
  <!ENTITY pkg_StrafePing           SYSTEM "./etc/poller-configuration.d/pkg_strafePing.xml" >
  <!ENTITY pkg_Generic-Management   SYSTEM "./etc/poller-configuration.d/pkg_Generic-Management.xml" >
]>

This will create a reference to the particular files you want to include. Then, to use them, you simply reference them at the proper place in the file:

<poller-configuration threads="900"
                      serviceUnresponsiveEnabled="false"
                      xmlrpc="false"
                      pathOutageEnabled="true">
  <node-outage status="on" pollAllIfNoCriticalServiceDefined="true">
    <critical-service name="ICMP"/>
  </node-outage>

  <!-- Layer 3 network connectivity -->
  &pkg_Network-Connectivity;

   <!-- Layer 3 network diagnostics for jitter and latency -->
  &pkg_StrafePing;

  <!-- Monitor for management agents and remote administration -->
  &pkg_Generic-Management;

Note that the ENTITY definitions come before the start of the “normal” XML for the file, i.e. in front of the initial <poller-configuration> tag.

This can make the management of unwieldy files a little easier.

Again, this only works for code that you can lift out in its entirety. In the case of poller-configuration.xml we still put the <monitor> tags down at the bottom of the main file.

Ubuntu and the Huawei Mobile Broadband E173

I was recently in Sweden where we are doing a large project that I one day hope to tell every one of my three readers about in detail, but for now suffice it to say that they will have lots and lots of bandwidth in the coming months. However, in the apartment where I stay when I am there, there is no broadband network access, so they loaned me a mobile broadband modem.

Since Ubuntu is my distro of choice and the modem, the Hauwei E173, is fairly old, I figured it would just be “plug and play”. Jeff, who also visits the client, uses Fedora and said he had no problems.

However, when I inserted the device, nothing happened, or at least nothing appeared to happen.

I did manage to get it working, somewhat, so I thought I’d share my experience in case it helps someone else.

Now, what is supposed to happen, I believe, is that the device should show up in Network Manager as a Mobile Broadband device. I could never get this to work. During my investigation I found out that when you initially plug in the device it is mounted as a USB hard drive, and a program called “usb_modeswitch” is supposed to change it to a modem. Most of the information I found on the web was on getting that to work, but after a lot of trial and error it appears that it is working – Network Manager is just not picking up the change.

The device appears like this:

Bus 003 Device 002: ID 12d1:1446 Huawei Technologies Co., Ltd. E1552/E1800 (HSPA modem)

and dmesg shows the following output:

[ 4374.333592] usb 3-2: new high-speed USB device number 2 using xhci_hcd
[ 4374.354876] usbserial_generic 3-2:1.0: generic converter detected
[ 4374.355374] usb 3-2: generic converter now attached to ttyUSB0
[ 4374.355636] usbserial_generic 3-2:1.1: generic converter detected
[ 4374.355875] usb 3-2: generic converter now attached to ttyUSB1
[ 4374.362284] Initializing USB Mass Storage driver...
[ 4374.362498] usbcore: registered new interface driver usb-storage
[ 4374.362505] USB Mass Storage support registered.
[ 4375.436354] generic ttyUSB0: generic converter now disconnected from ttyUSB0
[ 4375.436478] usbserial_generic 3-2:1.0: device disconnected

So it looks like the device is attached as a usb-storage device and then disconnected.

How I managed to get it to work, somewhat, was to install the “wvdial” program. First, I created a file called /etc/wvdial.conf:

[Dialer defaults]
Modem = /dev/ttyUSB0

[Dialer telia]
Modem = /dev/ttyUSB0
Baud = 115200
Init2 = AT+CGDCONT=1,"IP","online.telia.se"
Phone = *99#
Username = *
Password = *
New PPPD = yes
Auto DNS = 1

[Dialer pin]
Modem = /dev/ttyUSB0
Baud = 115200
Init1 = AT+CPIN=xxxx

where “xxxx” is replaced with the PIN for the device, and now when I run “wvdial telia” I get the following output:

# wvdial telia
--> WvDial: Internet dialer version 1.61
--> Initializing modem.
--> Sending: ATZ
ATZ
OK
--> Sending: AT+CGDCONT=1,"IP","online.telia.se"
AT+CGDCONT=1,"IP","online.telia.se"
OK
--> Modem initialized.
--> Sending: ATDT*99#
--> Waiting for carrier.
ATDT*99#
CONNECT
--> Carrier detected.  Waiting for prompt.
--> Don't know what to do!  Starting pppd and hoping for the best.
--> Starting pppd at Fri May 10 07:43:25 2013
--> Pid of pppd: 887
--> Using interface ppp0
--> local  IP address 90.x.x.x
--> remote IP address 10.64.64.64
--> primary   DNS address 195.67.199.27
--> secondary DNS address 195.67.199.28

At this point, I can use Thunderbird for mail and Chrome/Firefox to browse the web. To stop the session I just hit ctrl-C in that window:

^CCaught signal 2:  Attempting to exit gracefully...
--> Terminating on signal 15
--> Connect time 42.0 minutes.
--> Disconnecting at Fri May 10 08:25:29 2013

Now certain programs, such as Empathy, that seem to check with Network Manager on whether or not there is a network connection, don’t work. But for the small amount of time I find myself in the apartment and in need of network access, it will do.

Hope this helps, and if anyone has suggestions on what I’ve done wrong with Network Manager, let me know. Note that I am running Ubuntu 12.04 LTS on my laptop – perhaps it works better with later versions.

Review: The HWg-STE Ethernet Thermometer

Soon after my review of the AKCP Sensorprobe, I was contacted by Jan Rehak of the HW Group in the Czech Republic. I was asked if I would review one of their SNMP-based sensor units. I replied “of course” as I thought it was cool that anyone would want to send me an evaluation unit of anything, and I wanted to embark on my new career as super-duper, top-notch web reviewer-guy (are you listening, Telsa Motors?).

A few days later I received an HWg-STE Ethernet SNMP Thermometer, which is their most popular unit.

The HWg-STE supports two sensors, and it comes with one for temperature. The cable is pretty long so it can be placed some distance away from the unit. The unit is very compact, and molded into the case on the top and bottom are places for mounting screws. I installed it on the wall in the server room next to the Sensorprobe2.

One of the things I liked about the description was that it said it supported Linux for installation. Like most units of this type, the main configuration is done through a built-in web server, but a lot of vendors ship a small application to aid in the initial setup. The HWg-STE shipped with a CD that was Windows only (same as the Sensorprobe2) but I was able to find a Linux version on their website.

Unfortunately, I was unable to get it to work under Ubuntu 13.04, which is my current desktop at work. The application launched but failed to find any sensors. I did install the application via the CD on a Windows 8 machine we have in the office and it located the unit with an IP Address of 192.168.1.80. I changed it to match our LAN addressing scheme and then did everything else from my desk using a web browser.

Once on the network, setup was a breeze. The webUI is very clean and easy to navigate. I was able to label the sensor which was also reflected in the data I was able to receive via SNMP.

Both the HWg SNMP MIB and a short OID description document are accessible from the “System” menu of the interface. The HWg-STE does support the ability to send e-mails when a threshold is reached, but I was a little disappointed with the lack of SNMP trap support. Also, like many devices like this, it only supports SNMPv1 – an SNMPv2 GETBULK request will fail. Like the Sensorprobe2 there is no IPv6 support.

It was pretty easy to add the device to OpenNMS for datacollection (and the configuration will be included in version 1.12):

The values returned are close to the values reported by the Sensorprobe2:

I don’t have any way to determine if one is more accurate than the other, but they both seem to be close enough for the accuracy needed to monitor a server room temperature.

Overall, I really liked the size of the HWg-STE and the look of its interface, but the missing SNMP trap support is frustrating. I would also like to see more information in the MIB, such as high and low thresholds, so that those can also be graphed. Proper SNMPv2 support as well as IPv6 support would be nice, but as much as I like IPv6 I am not seeing it as a requirement in the marketplace at the moment.

UPDATE: Jan wrote me back with some clarifications.

Of course we have other devices with SNMP Traps & more detailed MIB. But you know, product segmentation..

Our main product is the Poseidon family
Many more sensors, I/O, etc..

Yes we plan SNMP v3 + IPv6 to new generation Poseidon2.

"Sorry it's so spread out."

Today I received an e-mail with seven invoices from one of our contract employees.

“I am now using a new accounting package to generate invoices.
Unfortunately it generates a separate invoice for each project even if the work is performed for a single customer. Each invoice references a different project activity. Hence several invoices attached.”

This struck me as funny for two reasons. First of all it says to me “Sorry, but my time is worth way more than your time, so I’ve decided to use a new accounting package that makes things easier for me although it will make things harder for you.” Not exactly the message you want to send to your customers.

While this isn’t a big deal as I like the guy, I am sure he didn’t think about the message he was sending. How many interactions can you name that are kludgy or cause you extra work and the excuse is “sorry, but the software made me do it”?

The second reason I found this funny is that open source can help solve problems like this. When talking about OpenNMS to potential clients, I often say things like “OpenNMS can be made to fit your business processes – you don’t have to change them to fit the software”.

This is an extremely powerful message, and it is why we refer to OpenNMS as a “management application platform” and not just an application.

Review: Ingress by NianticLabs@Google

TL;DR

This is a review of the augmented reality game Ingress, and contains no OpenNMS content. Ingress combines a massively multi-player on-line game with geocaching, and it can be quite addicting. I’ve spent a lot of time this week going from Level 3 to Level 4, and while I enjoyed it I don’t have enough interest to spend a lot more time on it. I do find some of the civil libertarian issues it raises, such as citizen access to public spaces, interesting. Currently Android only, it is a great example of how not all cool things are invented by Apple.

Overview

The backstory is the weakest part of the game. It goes something like this: an alien race called the Shapers appear on Earth, and with them, portals. Portals are gateways to another dimension, etc. that leak something called “exotic matter” or XM. You pretty much need XM do to anything.

This event has caused the world to divide into two factions (three, if you count those that don’t give a flip). One, the Enlightenment, wants to spread the influence of XM in order to take humans to the next evolutionary level. They are the “green” team. The other, the Resistance, seeks to limit the influence of the aliens because they fear it is harmful. They are the “blue” team.

Why I think this is weak is that it really doesn’t affect game play at all. Each team uses the same items and methods for similar objectives: the creation of control fields across the land. The idea is that all of the people (mind units, or MU) under the fields are either protected from the alien influence (in the case of a blue field) or more prone to enlightenment (in the case of a green field). Estimated world totals of MU by factions are displayed in the app.

Gameplay

Okay, the key to everything are those portals. Portals are placed by Niantic and are usually associated with public places such as post offices, fire stations, and libraries. In North Carolina with have a system of historic markers, and it looks like they have imported the whole database in order to place portals. In order to interact with a portal, you have to be next to it (for the most part). Hence the geocaching aspect of the game – you physically have to visit places in order to do anything. Note that tie-ins with companies like Zipcar and Jamba Juice have added those locations as portals as well, so it isn’t limited to just government buildings but instead the only rule is that they are supposed to be publicly accessible (which is stressing the definition in some cases).

The way you interact with the world of Ingress is with your scanner – i.e. the app on your Android phone. Combining the GPS and Google Maps, when you are close to a portal it will show up on your scanner. Your position is represented by a little arrow icon, and your area of influence is represented by a circle around that icon.

XM is represented by little, blobby white dots. Once those enter your influence, they will fly toward your icon and increase your XM totals. They can be found anywhere, but tend to cluster near portals.

Portals show up as smoky/glowing/other-worldly columns. Those controlled by the Resistance show up as blue, and those owned by the Enlightenment show as green. Uncaptured portals are gray.

In order to capture an uncaptured portal, you first have to be in range. Then you place an item called a resonator on the portal and then your faction will own it.

Completing actions earns you Action Points (AP). This is similar to “experience points” in other games. The more AP you collect, the higher your access level. Most items in Ingress have a level associated with them, and the higher your player level the more items you can use. At the moment the lowest level is L1 and the highest is L8.

There are seven things you can do to a portal. First, you can “hack” it. This is the main “farming” task in Ingress. Hacking a portal will give you items most of the time (sometimes you get nothing). Once you hack a portal you can’t hack it again for 300 seconds, and there is a limit to how many times you can hack a particular portal in a given amount of time – I think it is currently four times in a 24 hour period but I’m not sure. If you try to hack a portal before you are allowed, your scanner will display a “portal running hot” message with the time you must wait until your next attempt. If you have exceeded all attempts for the day, you get a “portal overloaded” message with no time displayed.

The next thing you can do to a portal is place a resonator, assuming the portal is uncaptured or belongs to your faction. There are eight spots for resonators at the cardinal points around the portal. A single player can place up to eight L1 resonators, but only 4 L2 or L3 resonators, etc. The higher the average level of resonators, the higher the level of the portal and the more energy it can store.

If a portal is fully populated with resonators, you can link it to other portals, assuming you have an item called a Portal Key. By hacking portals (of any faction) you can collect multiple copies of these keys. If you are at one portal and you have the Portal Key for another nearby portal, and both portals are owned by your faction, you can attempt to link them. Whether or not you are successful depends on the distance between the portals and whether or not there are any other links in the way (links cannot cross). The higher the level of the portal, the longer the link can be. The Portal Key is destroyed when the link is created.

Now the big thing to do is create a control field by linking three portals in a triangle. This results in a lot of AP and on the “intel map” the underlying area will show up as being controlled by your faction.

So, that’s three things (hack, place a resonator and link). The fourth is the ability recharge a portal. Portals hold Energy proportional to their level, but that energy is constantly draining, especially in the presence of links and fields. In order to keep the portal from decaying totally and becoming uncaptured, it has to be recharged. You can recharge it from your XM reserves if you are next to it (and it belongs to your faction) or remotely if you have a Portal Key.

The fifth is that you can upgrade the deployed resonators to ones of a higher level.

The sixth is that you can “target” a portal. All this does is show the distance and direction to the portal on the scanner.

All of these, except hacking and targeting, assume your faction owns the portal or it is uncaptured. The final thing you can do is attack a portal. To do this you need an item called an XMP burster. These are farmed through hacking and are single use. The higher level bursters do more damage, of course, and are used first in an attack. The more Energy a portal has, the longer it will take to destroy. A user for the faction that controls a portal can recharge it during an attack assuming they have XM and are either nearby or in possession of a Portal Key.

Position when using XMP busters is important. Like Phasers, they do more damage close in, so you will want to position yourself next to the resonator when using them. Once all the resonators on an enemy portal are destroyed, it becomes uncaptured and you can then deploy resonators to claim it. Note that hacking and attacking enemy portals are frowned upon by the portals themselves, and they will zap you with an XM draining bolt. When your XM gets too low, you won’t be able to hack, and when it gets even lower the scanner will stop operating until you find more. Being drained of XM does not appear to kill your character.

There are some other aspects of the game. On the Niantic website they drop clues to figuring out passcodes that can be entered into the scanner to receive XM, AP and items. There are power cubes of XM that you can find. But basically the idea is to capture unclaimed portals, destroy enemy portals, create links and control fields.

My Experience

I was first exposed to Ingress through Michael Shuler on G+. I didn’t really understand it more than it was a geolocation game. I strain to call it augmented reality, since you don’t actually see these portals through a camera but instead on a map, but since it was (and still is) a closed beta I didn’t pay too much attention to it.

Then at the OpenNMS Users Conference I saw how interested Alex Finger was in the game, and I decided to apply for an account. He was on the green team so I was determined to be blue just to be contrary, but he pointed out that most of the area where I live is blue, so I should be green just to have something to do. It was a great piece of advice, since you can’t change factions and I later learned that my friend Donnie Springfield was also on the green team and he’s local.

A few days later I got an account and started playing with it, but it didn’t really take off until Eric Evans came to the main OpenNMS office for the week and really showed me how to play it. He is on the blue team, so we made a bunch of jokes about “smurfs” and “frogs” but as I mentioned before the backstory really doesn’t matter – it’s still capture the flag.

The week I spent with Eric and for the weeks after I started playing more. I found myself going out of my way to visit portals. I attacked and captured my first one. I visited portals while traveling for OpenNMS. As I started closing in on Level 4, Donnie showed me how to look for uncaptured portals on the Ingress Intel map. You have to zoom in real close so it can be tedious, but when I discovered a cluster of seven(!) uncaptured portals nearby, I headed out into the country in the early morning rain to start farming AP to level.

When I found myself in a light sprinkle, knee deep in a cow pasture straining to get a data signal so I could fling a resonator out to that remote portal – I knew I had a problem.

I hit Level 4 this morning and I’m going to back way off for awhile. First of all, I’m too busy for such games. Second, even though being at a higher level is fun, nothing in the game play really changes. It takes 70K AP to reach L4, and 1.2M to reach L8. No matter how long a link you create, you get 313 AP. A link that creates a field gets you 1250 more. Hacking an enemy portal gets you 100 AP. That’s a lot of play to reach 1.2M (see the Wikipedia article for more complete info)

When I drive I do find myself hitting the brakes when I see a historic marker or a flag.

I think the game play could be improved by increasing the AP for longer links/bigger fields, or better yet, put the “multi” back in multi-player and have groups of people get more abilities when they work together (I’ll form the head).

I am curious as to the bandwidth requirements of this game, especially if they make it a truly augmented reality app. As I fly by at 60 mph in my car with Ingress running, I can’t imagine the amount of data that would have to flow to keep up. Multiply that by thousands if not millions of others and you have a cool engineering challenge.

Dangers

I was in San Francisco a few weekends ago and was meeting Geoff Davis for dinner near 24th and Mission. It’s not a bad neighborhood but it isn’t exactly great. I got there early so decided to spend the time hacking the numerous portals in the area. At one point I looked up and found myself in an alley, narrow walls surrounded by some pretty amazing graffiti, but not exactly the safest place to be in the evening carrying around a couple of grand in electronics.

Trust me – in many places wandering around in circles while constantly looking at your phone is not considered normal. Since many if not most portals are near public buildings, in this post-9/11 world expect to be questioned if not threatened.

As I was attacking the fire department portal this week, I had to wander around back to get close to that last resonator. When it died I let out a little “whoop” and turned to see three rather large firemen looking at me all unfriendly-like, and one asked “May we help you, sir?”.

I laughed, told them I was playing a computer game, and showed it to them on my phone. They thought it was pretty cool.

Compared to actual geocaching, Ingress doesn’t require anything to be left on the property or anything to be dug up, etc.

I got a different experience last evening when I was attacking the post office portal. The postmaster, a tall, somewhat severe lady, was taking out some trash so I made sure to say “hi” and let her know what I was doing. She wasn’t happy and suggested that it was illegal for me to be outside of the “public” areas of the post office building. Now, I was under the impression that any area outside of a post office was public, and since I wasn’t interfering with business nor destroying property that I had every right to be there. I spent some time last night doing research and I think I am correct. First off, the idea of “trespassing” is predicated on there being “no trespassing” signs clearly posted. There is an “Authorized Vehicles” sign but nothing about “Authorized Personnel”.

It started to piss me off, and indicates one problem I have with this country. People at all levels of government seem to have forgotten that they serve at the will of the people, and especially at the lower levels, from TSA employees to rural postmasters, seem to want to claim more authority than they really have.

Now I’m not saying she shouldn’t have asked about a weird guy acting strangely next to a government building, but once explained I was hoping she’d have the cool and friendly reaction of the firemen. Instead, she decided to fluff up her feathers and imply it was verboten. Part of me wants to force the issue but the lazy part of me wants to pick a different battle.

Which brings me to the name “Ingress”. I think it is brilliant. Not only does it refer to “signal leakage“, such as the portals “leaking XM” into our world, but also property law, as in the rights of a person to enter a property.

If you are into this sort of thing, and you have an Android phone, I encourage you to check it out. In any case, I think Google has a hit on their hands.

OpenNMS at VMWare World

Just a quick post to encourage any of my three readers who are also VMWare users to vote for my presentation that I submitted during the Call for Papers.

Entitled “5390 Monitoring VMWare with OpenNMS” my goal is to show off all of the cool stuff coming in 1.12 for integrating with vSphere and getting all that crunchy VMWare goodness into OpenNMS.

Vote early and often, and I approved this message.

UPDATE:

Thank you for your interest in speaking at VMworld 2013. Our Content Committee took great care in reviewing each and every session proposal. Unfortunately, we are not able to accept your session proposal

Thanks everyone who voted.

MC Frontalot to Perform at Southeast Linuxfest

Hot on the heels of last year’s amazing Ohio Linuxfest, we at The OpenNMS Group are excited to be able to bring the musical stylings of MC Frontalot to this year’s Southeast Linuxfest to be held 7-9 June in Charlotte, North Carolina.

Front has been confirmed to perform Saturday night, and I want to stress that this will be his only Carolinas appearance on June 8th. So if you are jonesing to see the man who coined the term “nerdcore rap” up close and personal, be sure to save the date and register for the conference. I repeat, there will only be one place to see MC Frontalot on June 8th, and that will be at SELF.

Hope to see you there, and bring some ducats for the merch table so he can buy food.

Google Summer of Code 2013

Once again I am very humbled to see that the OpenNMS Project has been accepted into the Google Summer of Code.

OpenNMS has been a project in every GSoC since 2008, thus this is our 6th year. Wow.

For those of you who are unaware of the GSoC, this is a program where Google sponsors work on open source projects by matching programming students with mentors within the project’s organization. Furthermore, Google pays those students a stipend of US$5000.

When I was a student, I spent my summers making string trimmer casings in a plastics plant.

Considering that there are 177 projects involving over 1200+ students, this represents an investment by Google of over US$6.6M (the mentoring organizations receive $500 each per student).

Hats off to Google for giving back to the community in a big way.