Archive for the ‘computers’ Category.

MySQL Help (phpBB and aMember)

As some of you know, I do many of the “webmaster” activities for the Michigan Mountain Biking Association. As part of this, I’m trying to do some MySQL stuff, but I’m really not sure where to start since it seems to be way beyond my abilities. So, I’m going to write it up here and hope that someone can help. Please? Help?

Thank you very much in advance for any help you can provide.

I’ll put it below the fold…

Continue reading ‘MySQL Help (phpBB and aMember)’ »

Network Capture During Boot on Windows 7 (and Server 2008)


When working on network issues it’s often useful to have a network capture (or trace) illustrating the startup of the computer. As a tap, a switch with spanning ports, or wireless capture equipment is rarely available it’s nice to do this right in the OS. Thanks to some improvements in both Windows 7 and Windows Server 2008′s netsh it’s now possible to do just this. Most of the information in this post is gleaned from this article at TechNet Blogs Event Tracing for Windows and Network Monitor, but here I wish to present a simplified version of how to get and save a capture.

While there are more advanced methods available by running Microsoft Network Monitor (eg: capture filtering, remote shutdown via specially crafted packets, etc), this method will accomplish the majority of boot time network capture needs. This is also often much more useful than performing a capture via an external tap as it includes the ID and name of the process responsible for sending or receiving the given traffic.

To start a basic promiscuous mode capture listening all interfaces with a 250 MB ring buffer (the defaults) and writing the trace file to the default location, use the following command, run as Administrator:

netsh trace start capture=yes persistent=yes

The capture will then run until stopped, even through reboots. To stop the capture and write the capture file out to disk, use the following command:

netsh trace stop

Consult the output from netsh trace start help to determine the other options you may want to set. Here are what I find to be the most-useful options:

maxSize=250 MB: Maximum capture size.
overwrite=yes: If there’s an existing trace of the same name, should it be overwritten?
traceFile=%LOCALAPPDATA%\Temp\NetTraces\NetTrace.etl: The output network Event Trace Log (ETL) file.

After an .ETL is obtained it needs to be opened and filtered with Microsoft Network Monitor to remove the extra headers. To do this ensure that you’re using the Windows set of parsers (Parser ProfilesNetworkMonitor ParsersWindows), use the display filter:

NDISPacCap_MicrosoftWindowsNDISPacketCapture

From here additional filters can be used, such as the example screenshot above which uses the following filter to display all captured ARP traffic:

NDISPacCap_MicrosoftWindowsNDISPacketCapture
and
arp

While I normally prefer Wireshark for capture analysis, I’ve found a number of cases where Network Monitor is more useful. The PID and Process Name capture, the IntelliSense-like autocompletion in the Display Filter, and the seemingly better decoding of a few protocols (SMB in particular) are great, even if the default layout is a bit crap and there aren’t as many built-in analysis tools. While obtuse to many It’s also quite a bit easier to get apprehensive customers to install a single Microsoft-provided tool on their devices than something they view as simply “a freeware tool from online”.

Time Machine Works!


After roughly twenty four hours of working and waiting on Danielle’s computer I have the hard drive uncorrupted and Time Machine working! It turns out that despite my previous thought that the corrupt drive was preventing backups from happening it was actually something else: the entries for the shared drive on the AirPort in the System Keychain somehow weren’t working right. Deleting them and allowing them to be recreated fixed things.

Since I have syslog on the AirPorts logging to pfSense (on the alix2d1). By using that along with logs on the Mac I could see that everything was pointing to an authentication issue. The user account could access the drive just fine, but Time Machine sets the shared drive’s password in the System Keychain during setup, so I then looked there. Seeing a number of entries for Core, the name of the AP, I removed them all and set things up again. Suddenly Time Machine created its .sparsebundle, mounted it, and set off backing things up. While I don’t know exactly what was wrong (conflicting Keychain entries? wrong one getting read? defective Keychain?) at least I know what got things working again.

I’ve plugged the machine into a wired connection to hurry things along, but hopefully the remaining ~107GB of data will be backed up before Danielle gets here. Then hopefully it’ll keep working…

Broken Time Machine


This is not good.

Danielle’s computer has been failing to back up properly to an AirPort-connected Time Machine volume, so with her volunteering at the 3-Day this weekend I figured I’d spend some time getting to the bottom of why.

First I thought the issue might be the questionable USB enclosure that the backup hard drive was in, so I swapped to another. No luck. Then I figured maybe the backup volume was corrupt, so I wiped that, but that didn’t help either; the backup still wouldn’t run. Next I thought that perhaps the local drive might be having issues, so I ran the Verify Disk function in Disk Utility, which promptly informed me that the volume was so damaged that I’d have to boot some install media and do an offline test. I did this, started the check, and received the message shown above informing me that the volume is so corrupt that it cannot be repaired. It will now not boot, sitting only at the Apple logo / spinning progress indicator screen.

This is not good.

Now I will have to back up all the accessible data by hand, and hopefully I’ll be able to get all of her music, documents, and photos along with config files needed to restore them. I’m hoping that this can be accomplished by hanging an FireWire disk off of the machine, installing OS X there, using Migration Assistant to pull data over, wipe (and test) the main drive, reinstall the OS there, then again migrate all data from the FW drive.

While it’s difficult to say what caused this, I strongly suspect it’s related to an alarm clock application that she’s been using for a while. This application will wake a Mac from sleep and sound an alarm. As her machine is a Macbook, which is not designed to run while closed (since they dissipate heat through the keyboard area), a program waking the machine from sleep while the machine is closed results in the machine immediately putting itself back to sleep. This would repeat over and over until the alarm was canceled or timed out. With this app in use for the last year or so, odds are good that this super-fast wake/sleep cycle has happened hundreds or thousands of times.

Due to the extremely complex things that happen when a machine is sleeping and waking, I strongly suspect that some things didn’t get read from or written to disk quite properly during the wake/sleep cycle and the disk became quite corrupt. Then, the software designed to repair this corruption couldn’t deal with how bad things were, left the disk in a less-usable state, and the machine is then left where it now is: failing to boot.

UPDATE: This corrupt disk problem was fixed as I hoped it would be above, with the external FW disk. Unfortunately Time Machine still isn’t working. Time to keep digging…

Working Car!


This broken bolt is the reason for Sunday’s car failure. When it broke the serpentine belt tensioner came free, likely becoming lodged somewhere, and causing the car to cease working. Because the bolt broke off flush with the engine block and was in a particularly hard to reach place, the engine had to be lowered 2″, the bolt drilled, and then the bolt removed with an easy out / screw extractor.

As a result there was $187.54 in labor to fix the problem, with the bolt, new serpentine belt, and other misc parts only being $78.01. With the $100 for towing, this failure cost just under $400, which I guess isn’t too bad. It’s a bit frustrating that this comes only two weeks after paying my car off (early), but timing on this is really very random.

The guy at the shop (Shelby Tire) said they spent a while trying to figure out the cause of the broken bolt, but the AC compressor, power steering pump, and all other devices connected to the serpentine belt seemed fine, including the tensioner. The only cause he could figure was that the bolt was weak (or failing) and the AC kicked on just as the power steering kicked in, and the extra load on the belt snapped things. As I was turning a corner out of a parking lot having just turned the AC on when the problem happened, this makes sense. Hopefully it won’t happen again.

(This is also the first RAW photo that I’ve processed in the newly released / installed Adobe Photoshop Lightroom 3. One of its new features is markedly improved sharpening, and I must agree that it’s much better. After all, just check out those knurls on the screw head.)

“100% New Compatible Toner Cartridge” for Xerox Phaser 6130 (Black)


After roughly 1.5 years of use the black toner cartridge in my Xerox Phaser 6130 finally ran out. Since the Xerox-branded cartridges cost somewhere around US$80 I decided to try this “compatible” cartridge from the venerable MonoPrice.com. While I’ve only used it for a few pages, it seems great so far. It fit nicely in the printer, the printer immediately recognized that K (black) was full, and the couple jobs sent to it have all processed smoothly.

PC Engines alix2d13 and Netgate Enclosure


This week I received a PC Engines alix2d13 board and Netgate NET-CASE1C2REDU-ANT enclosure which will replace the venerable Trashwall. While Trashwall served its purpose for a while, I was getting tired of its noise (a slight but present hard disk whine) and power consumption and the need to manually set up utilization graphs and such.

After giving pfSense, a FreeBSD / pf-based firewall distribution which works nicely on embedded devices, a try I decided to move to it. I’ve now got pfSense v1.2.3 embedded (current stable release) installed on a 4GB SanDisk Ultra II compact flash card which the ALIX board boots to run the OS. Console output (when needed) is via serial port, but after the initial configuration, practically everything can be done via the web.

I’m running into a couple quirky problems with port forwards, but it’s otherwise doing a fine job of running my home network. DHCP with reservations, DNS, DynamicDNS (for DHCP clients to be resolvable), and NTP are all working as they should. Once I get the port forward issue sorted I’ll likely backup the config and give one of the pfSense v2.0 beta snapshots a go. If whatever beta snapshot happens to fail or doesn’t work out I can then just reimage the CF card back to v1.2.3 and reload the exported config. pfSense configs are simply XML files that can be backed up and restored at will, which is particularly convenient.

If you’d like to see more photos of my PC Engines alix2d13 setup, click here.

If you’d like to buy one, check out Netgate. The specific items I purchased for this are as follows, for a total of US$183.85:

· ALIX.2D3+B System Board: (3/1/256/LX800) with battery [ALIX.2D3+Battery]: US$140
· LIX.2D3 3 LAN Indoor Enclosure Red with USB & ANT [case1c2redu-ant]: US$24
· AC/DC 15V 1.25A 18W Switching Adapter only [PS-15V-1.25A-18W]: US$9.95
· SMA Dust Cap / Rubber Antenna Hole Plug [SMA Dust Cap Plug]: US$0.14/ea (2x)
· Postage via FedEx: US$9.62

Snow Storm Ride


Wanting to get some exercise and ride a bit I set out on my bike at about 8:30pm. While originally intending to ride around the neighborhood and just see how well the Nokian Hakka WXC300 tires perform in real snow, I found they worked well and instead headed towards River Bends. Taking the usual routes I logged 11.39 miles over 1:17:39, for an average of 8.8 MPH. That’s slow, but considering the super-studded tires and riding through 3″ of powder over packed snow and ice, I don’t think it’s too bad. (In case you don’t know we’re actually in the middle of a snow storm; one which is potent enough that riding a bike is almost easier than driving.)

The tires work out really well, and their large knobs do a very good job of sticking in snow. When riding on somewhat-packed residential roads they felt a bit squirrly, but that’s to be expected as there wasn’t much for them to bite into, but it was too deep for the studs to be of any use. While on the paths/sidewalks and on the trails where the surface was snow/ice they were outstanding and I’m really glad I purchased them. While they are of obvious limited utility being for one particular season, it would be much more difficult to ride now without them.

One of the other interesting events of the night was getting made fun of. It’s been a while since I was last shouted at by people in cars, but maybe the snow brings out odd people. While riding along, just as I was crossing some train tracks on the path, someone in a black Chevy Avalanche driving slowly past yelled something out the window. Later on when heading back home it passed again, the driver honked at me. Further on still while waiting for a it passed another time, slowing so the passenger could yell “nice light, yo yo”. This whole time I was 20′ – 30′ from the road, on an adjoining path.

I get made fun of in the strangest places. Flipped off from the road which I’m 40′ above on a pedestrian bridge… Yelled at from people below me on a highway while I’m in a bridge… People are strange.

Anyway, here’s some photos from tonight. Any cloudy bits (such as seen above) are condensed breath and sweat from my arms hanging in the air, as it wasn’t windy enough to carry it away:

· My Specialized hard tail, in River Bends, while riding in the middle of a snow storm which had already dropped 2-3″.
· After a bit of riding I stopped in the park pavilion to eat a gel. Riding in 3″ of snow is hard work.
· My bike after getting home snowing snow packed into the rims and other bits.
· Rear triangle showing snow packed into the cassette, chainrings, etc.
· Another view of the rear triangle, this time from a higher angle. Lots of snow is packed into the bike. Note how clean the tires from riding in snow.
· Detail of the bottom bracket / front derailleur area showing packed snow.
· The fork, front wheel, and brakes showing how much snow is packed into this end of the bike.

Google Maps Fails Again!


Here’s yet another failure of Google Maps in my area. Not only is my address not found (it worked just fine in the past but now has the street name listed incorrectly), my ZIP+4 alone doesn’t work, and now 22 Mile Rd. shows up improperly in Street View as 20 2 Mile Rd..

I just submitted the following bug report to Google about this:

Google Maps lists 22 Mile here properly, as the name '22 Mile Road'. When in Street View this is listed as '20 2 Mile', which is wrong.

We’ll see how far it goes. My last few bug reports, while acknowledged as correct and noted as being fixed in future releases, have resulted in only one fix that I can validate myself; more appropriate naming of roads on the GM Tech Center campus. It’s now been months since I reported my address as not working and it’s still not right. There are also problems where a local highway and surface road with similar names are sufficiently confused to make businesses appear along the wrong road. As can be seen here a bunch of locations are incorrectly placed roughly one mile east of their actual location. This too has been reported, and not fixed.

I currently use (and rather like) a T-Mobile G1 Android-based phone and I like it enough that I’m seriously considering buying a Nexus One when it launches. However, terribly inaccurate local data including not having my home address available limits some of the major selling points of the phone.

Blue Light Special


Here’s a photo of my desk from a few minutes ago, after fitting a light behind the iMac. Taking a cue from home theater stuff where placing a dim light behind a TV provides nice ambient light and increases apparent contrast in the display, I fitted a 9W daylight colored compact fluorescent light behind the display on a cheap clip-on light. This makes a nice glow behind the monitor and on the white ceiling which provides enough light for computer and peripherial use, but is dim enough to make for comfortable evening working. This light will eventually be switched using an X10 appliance switch, just as the normal desk lamp is, but these devices haven’t been received yet. Thanks to eBay they were cheap and should be here in a week or so.

Beneath the iMac you may notice the Millet Hybrid Maxed headphone amp which I built last year. It is connected to the AMB γ1 DAC which sits nicely on the Twelve South BackPack. Audio output for non-system sounds are switched from the main speakers to the DAC (and thus the headphones) as needed using Rogue Amoeba’s SoundSource. This works out well for when Danielle and I are both at our desks with audio playing, as respective use of headphones keeps us from driving each other insane. A few new cables are needed to sort out the connections without a rat’s nest, but these are on back order and likely won’t be here until the beginning of next year.

All in all, this is shaping up to be a nice workspace. The iMac is doing everything asked of it with gusto, the display is excellent, and the overall sound level in my office is down to profanely low levels. This is very nice.

The lamp is a cheap Home Depot 5000K lamp with a rather poor CRI. It is not appropriate for photographic or color-critical work, but it’s just fine for room illumination, particularly indirect illumination bouncing off of a blue-painted wall.