Running As Administrator
Posted in Tech
Forenoon watch, 6 bells (11:19 am)

I was forwarded an article about running a program as administrator at login that outlines a very nice way of getting around the Windows has blocked some startup programs error. Use it for good, not evil 🙂

Leave a Comment »
Intel Compiler on Ubuntu 9.04
Posted in Tech
First dog watch, 1 bell (4:38 pm)

Just in case I'm not the only one to run across this issue, you must have libstdc++5 installed (use Synaptic Package Manager). It is not installed by default, even on a development system. libstdc++6 is, but the Intel compiler won't use it. You may be able to fake it by creating a symbolic link in /usr/lib, but it's not worth the trouble. Just install the old library, it doesn't hurt anything.

Leave a Comment »
Evil Includes
Posted in Tech
Afternoon watch, 4 bells (2:22 pm)

I finally solved a terrible C++/MySQL C API include issue. Unfortunately, I'm stuck with a pretty old version of the MySQL server on one of my servers (MySQL v3.23—yes, I know how old it is!)

I finished writing a new wrapper API to access a MySQL server, and had the unfortunate luck to name my class mysql_server. I say unfortunate because my header file inclusion guard said


Little did I know, the MySQL 3.23 library actually defines this value somewhere, and it caused me to have the strangest link errors I've ever seen! Undefined references to common functions like mysql_real_query, mysql_init, etc.

In later libraries (MySQL 5.0 for sure), this value is no longer used. I can only assumed they used something more intelligent like __MYSQL_SERVER or something not normally seen in user-space.

I'm sure I'm not the first person to be burned by this, which explains why it has been changed. I may, however, be one of the last—I can't imagine there are a lot of servers out there using such an old version of MySQL…

Leave a Comment »
Cisco Firewall Issues
Posted in Tech
Afternoon watch, 3 bells (1:35 pm)

I've been working with my boss for quite a while on a router issue. We've spent hours on the phone with Cisco technicians trying to get this issue solved, and today it finally happened. The solution was deceptively simple, but I guess you need to get the right technician.

Our issue was this: a firewall was configured on a Cisco 881W router with NAT translation to pass Microsoft VPN traffic in to a VPN server on the inside of the firewall (port 1723). The problem is it never worked. The solution required GRE (which we knew), but finding a tech with the right qualifications to tell us exactly what to do was a right pain. We found if the firewall was shut off, then the VPN connection worked, so we knew there was an issue somewhere on the firewall itself.

Well, to make a long story short, here are the missing bits:

access-list 120 permit gre any any

class-map type inspect match-all GRE
   match access-group 120

policy-map type inspect NATOut-to-In
   class type inspect GRE

The number of the access list isn't important, as long as it isn't already used. The traffic has to be passed through via the policy map because it cannot be inspected. The NATOut-to-In is the rule for the firewall that handles outside to inside traffic. I don't know what yours may be named, but it should be something like that.

Leave a Comment »
That Error Checking Issue
Posted in Tech
First watch, 3 bells (9:38 pm)

I've been thinking about the error checking issue I mentioned the other day. And I've talked to several of the other people at work, and they agree that the best thing to do is to ensure that the error-causing issue doesn't come up. I think the easiest way (thanks, Jeff) is to return all the information that the query generates immediately. So I spent some time yesterday evening and today rewriting two different MySQL wrapper classes (one for work, one for a personal project).

I'm much happier with the code now. If anything, it's cleaner than it was before. Certainly easier to use, as well. I was also able to cut out a lot of excess functionality that became obsolete. So, by my calculations, more stable + faster + easier to debug + smaller codebase = WIN.

Leave a Comment »
Compute This, Wolfram!
Posted in Tech
Forenoon watch, 2 bells (9:27 am)

I've heard a lot of noise about WolframAlpha in the last two days.

Given that they haven't figured this out yet, I'm still on the fence…

WolframAlpha vs. Flying Spaghetti Monster

Leave a Comment »
Much Quieter Day
Posted in Tech
First dog watch, 1 bell (4:38 pm)

Today was much quieter than yesterday. Despite the fact that I didn't get to sleep this morning until well after 2:30am and I was awake before 7:30am, it wasn't such a bad day. I spent a good part of the day in debriefing mode, starting with some early phone calls with our service provider. I talked to Norm again, and explained the whole thing to several people around the office.

I was disappointed at 5:30 this morning when I tried calling the office that our lines were still down, but I knew John (my IT minion) would take care of it. We ended up forwarding all calls to the VP's cell phone (I'm sure AT&T appreciated that), he averaged more than a call per minute, but it was only a half hour or so before we were back up completely.

I really tried to get a little more sleep, but it just didn't happen. I'm bad enough once I wake up, it's hard for me to just go back to sleep. When I have a big problem like this hanging over my head it's just that much worse.

But thankfully everything was quiet today. Well, except for the phones—they're ringing again!

Leave a Comment »
Long Days
Posted in Tech
First watch, 7 bells (11:59 pm)

I just got home from work—it's been a long day today. If you follow me on Twitter you already know. It started out okay, but around 2:30pm today our phone system shut down, right in the middle of all calls. After a quick sanity check that determined it didn't look like it was our problem, I called XO Communications, our service provider. At this point, it was about a quarter to three.

A trouble ticket was set up, and a technician called about 20 minutes later saying she was going to test our line. She called back just before 5pm and told me there are CRC and framing errors on our PRI. She said the only thing they could do was to set up a trouble ticket with Verizon and have their techs fix it. She also said it couldn't be done until some time after 8am tomorrow.

When I talked to my boss about it, he said it was unacceptable, which I agreed to, but didn't have much of an idea how to get it done. So I called my sales rep at XO to get some help and maybe accelerate the issue. I couldn't get through to anybody. Probably because it was just turning 5pm.

Anyway, finally I broke down and called the local XO technician's cell phone. Yes, I had it all along, but I don't abuse it. He is an awesome guy, and I really didn't want to call him unless I had exhausted my other options. He berated me for not calling him earlier! Anyway, he got the ball rolling with Verizon's support through his own channels. All I had to do was wait for their tech to call me and set up a time. Norm (our XO guy) said to call him back when the Verizon tech was going to be there so he could show up at the same time, just to make sure our problem got fixed. Like I said, he's a champ.

Anyway, an hour and a half go by without a call, and just as I'm about to call Norm back he calls me. He says "If you have a direct line to God now would be the time to use it." I was a bit worried. He said it has been one of the most difficult tickets he's ever had to work on. Finally, he pulls out the stops and calls Verizon's tech directly (just like I did by calling Norm). The Verizon tech had trouble getting his own office to release the ticket to him, so they had no idea what the hell was going on. Amazingly, this has not diminished my opinion of Verizon. But only because my opinion was already at rock-bottom.

Anyway, Norm gets the tech to stop by before his 10pm call elsewhere. He shows up just after Norm, they do their thing, and find that it's not a problem at the demarc (or d-mark, or whatever they call the place where all their lines come in to our building), but it's between the CO and us. That points them to a repeater that they've had trouble with before. Apparently it flooded and shorted out some electronics.

But before we tried to get that fixed, we thought we'd just jump on to an old T1 line that was provisioned for a company that used to be in our building. After they tracked that down from several different geographic locations, they had to give up because the line was came down from Hayden Lake where they couldn't get to 24/7. So we had to go back to plan A, fixing the flooded repeater. Verizon's emergency crew was dispatched to pump out the hole and replace the equipment.

At this point we'd done everything possible, and had to leave it in the hands of the emergency crew. They promised to get us up and running before we open the doors tomorrow morning at 6am. I really hope it works out, but in the meantime have worked out a new plan B with John, my cow-orker. We can forward our primary DID (where all our 800 numbers are routed) to a new number, such as a cell phone. By putting a voicemail message explaining the outing, we can at least let people know what's going on instead of them just getting a busy signal.

Leave a Comment »
Details About Telnet Options
Posted in Tech
First watch, 8 bells (12:13 am)

I found a great page today with all the telnet options in order and referencing the RFC that explains each one. Probably useless to 99.9999% of the population, but I find it quite interesting considering I've been writing a MUD/telnet driver for years now.

1 Comment »
Telnet Negotiation
Posted in Tech
Forenoon watch, 5 bells (10:55 am)

So here's what PuTTY sends in a telnet session when you leave it in active negotiation mode, in order as it sends to my MUD driver:

  1. IAC,WILL,TELOPT_NAWS (window size)
  2. IAC,WILL,TELOPT_TSPEED (terminal speed)
  3. IAC,WILL,TELOPT_TTYPE (terminal type)
  4. IAC,WILL,TELOPT_NEW_ENVIRON (environment variables)
  5. IAC,DO,TELOPT_ECHO (self explanatory)
  6. IAC,WILL,TELOPT_SGA (suppress go-ahead)

These options are defined in arpa/telnet.h.

Leave a Comment »
Finally! A Use!
Posted in Tech
First watch, 3 bells (9:47 pm)

I have finally got a project that can use a std::deque. Up to this point, I have never bothered with them. I was just looking around for a vector-like object in the STL that has fast pop/push on the front and back of the array, and I didn't want to use a linked-list. I give you: std::deque!

For the MUD I've been writing, I plan on having a set of "overlay" maps, ASCII text files the same size as the main map that show changing states such as weather, sunlight, etc. An overlay with a sine wave line through it can represent the border between day and night (as well as dusk, dawn, and other relative values). By shifting this map progressively in one direction, you can simulate the rotation of the planet. The cool thing is by using a sine wave you can leave very high and very low latitudes with full-time daylight or night!

The problem becomes more complicated with weather such as clouds, rain, etc., because you don't want to shift everything across the entire world in the same direction. Well, you could, but it's cheesy. Anyway, I'm excited about coming up with an actual reason to use a std::deque.

Leave a Comment »
Rescued By Linux..Again
Posted in Tech
Afternoon watch, 6 bells (3:04 pm)

I was able to save some files from a laptop that was going south today by running OpenSuSE Live 11.1 and mounting the hard drive then copying the files to a USB drive. Windows repair had already failed fixing the problem, the system just would not boot.

The next, final resort would have been removing the hard drive and connecting it to another computer, but thankfully SuSE saved me and I was able to copy everything off without a hitch.

Leave a Comment »
Me, Boring-er
Posted in Tech
Afternoon watch, 5 bells (2:30 pm)

I (finally) got signed up for a Twitter account. I added a link on this page, but you have to look around. If you're interested in the even more boring bits of my life than make it to this blog, you can follow me here.

Leave a Comment »
vsftpd and errno 10061
Posted in Tech
Afternoon watch, 4 bells (2:26 pm)

I have been annoyed for a long time with an error message I get when connecting to my *NIX desktop via FTP. I run vsftpd. My *NIX box is on two networks, a local and an external network. When I connect locally I see the problem, if I go outside to the public network, everything is fine. I thought I didn't have a firewall exception for the ftp-data (tcp/udp port 20). Turns out that wasn't the right solution. It was my vsftpd.conf file. At one point in the past I added commands for the pasv_min_port and pasv_max_port (my firewall has an exception for these ports), as well as specifying the pasv_address. That was my problem—by specifying the IP address, I was allowing PASV mode to work only when it was connecting via that specific address. By commenting out the pasv_address line (and leaving the min/max range alone), I fixed the problem.

Leave a Comment »
Uptime Reset
Posted in Tech
Afternoon watch, 5 bells (2:33 pm)

Today I rebooted my work machine for the first time in over 313 days. I had to add a hard drive. Believe me, I tried to get the hot-swap functionality of SATA to bring the drive online, but it just wouldn't work. I was missing the device /dev/sdd, and even creating it with the right mknod arguments (at least I think they were right) didn't seem to work.

But I'm back up and running now, with some extra hard drive space.

Leave a Comment »