Tuesday, December 21, 2010

APC Network Management Card AP9630/AP9631 Installation Manual is Wrong!

I'm sure I'm not the only one that has suffered through this.

The manual says that "by default, the Network Managemnt Card ignores DHCP offers that do not encapsulate the APC cookie in DHCP option 43" and then proceeds to explain how to disable that requirement in the web interface. Then it gives several examples of alternate ways to configure an IP without the web interface.

I tried them all but they didn't work. Yeah, so, turns out they didn't work because the system had grabbed a DHCP no problem, without the cookie.

So, the APC NIC does NOT actually require option 43 to be set on your DHCP server.

You're welcome!

Friday, November 12, 2010

LTO Barcodes, for free!

Seriously, $100 for *barcode labels*?

Instead, pick up some sheets of 8"x11" Avery label stock, and print your own.

This site generates an appropriate PDF to print right on label stock:
http://tapelabels.librelogiciel.com/

Monday, October 11, 2010

Automated reboot of Netgear FVG318

I'm having trouble with some Netgear FVG318 wireless VPN routers. They can't seem to release their DHCP leases without a reboot, and there's no way to schedule a reboot on them.

Other than that, these are really great, reasonably priced little devices.

Hopefully my contacts with Netgear Support will yield a fix so that they don't run out of DHCP leases *for no reason*, but until then I need a workaround.

So, I used some wget magic to script logging in, saving the necessary cookies, and executing the reboot function.

Just replace your.fvg318.ip with your FVG318's IP, replace youradminpassword with your admin password. I doubt the line breaks will come out proper in blogspot, so I'll tell you that there is only one line of command between each comment line -- if it line wraps on here, you will need to make sure your copy that you run does not wrap those lines.

Then just set this up in a cron job to run every night at midnight and voila! No more unhappy uesrs, no more manual reboots.

#!/bin/sh

# Load login page
/usr/bin/wget --no-check-certificate -q -O - --save-cookies /tmp/netgear-cookies.txt --keep-session-cookies 'https://your.fvg318.ip/' > /dev/null

# Log in
/usr/bin/wget --no-check-certificate -q -O - --save-cookies /tmp/netgear-cookies.txt --load-cookies /tmp/netgear-cookies.txt --keep-session-cookies --referer='https://your.fvg318.ip/platform.cgi' --post-data='web0x120010=admin&web0x120011=youradminpassword&umi.loginAuth=Login' 'https://your.fvg318.ip/platform.cgi' > /dev/null

# Reboot
/usr/bin/wget --no-check-certificate -q -O - --save-cookies /tmp/netgear-cookies.txt --load-cookies /tmp/netgear-cookies.txt --keep-session-cookies --referer='https://your.fvg318.ip/diagnostics.htm' --post-data='umi.restartWrap.x=69&umi.restartWrap.y=14' 'https://your.fvg318.ip/platform.cgi' > /dev/null