≡ Menu

Justin’s Portable Internet and an Apt-Get Problem

This is a possible reason and solution for the problem where apt-get update stalls out while fetching headers, told in somewhat story-like form.

Everytime I leave town, I try to prep my laptop for travel. This normally includes the normal basic clean up routine (deleting files that aren’t needed, backing up the entire machine to my desktop, defragmenting, running scandisk, uninstalling all that demo software I try out on a weekly basis). I had considered going to the step of reformatting this time around, but alas, that would take more work and I needed my computer this morning for meeting.

In any case, I freeded up about 25Gb, which was more than enough room than I needed for something I always bring with me on trips like this one: My portable webserver.

I have a copy of Microsoft Virtual PC 2007 (available here for free) running Ubuntu 6.06 (available here for free). The drive image I have setup I have been using on and off for over a year now. It resides on my desktop when I am at home, and get’s moved to my laptop whenever I need it. It’s configured almost exactly the same as all my other web servers, which allows me to download a copy of whatever site I want to work on, and load it up into it and work on that site on the road. I then just have to resync the sites when I get in internet range.

All in all it works pretty well.

Well… As I prepped my virtual machine to bring with the sites I wanted, I realized that a few things weren’t installed. Namely: Samba and Tidy. Both of which are fairly easy to install. So I went to run apt-get update and ran into all sorts of problems. Some of which had more to do with the fact that I hadn’t updated the sources list in awhile.

In any case: I ran into a very weird problem where the following symptoms occurred:

  • The Internet Worked
  • Apt-get update stalled at “fetching headers”
  • Pinging the apt-get servers worked
  • Changing sources.list had no effect
  • apt-get upgrade had no effect

It was really rather frustrating, and I gave up trying to get it to work after 15 minutes.

A little later, I ran into a problem where wget failed at the “awaiting response” while trying to download a sourceforge. It was then that I figured out the two problems might be related. The only thing they had in common was that they shared the same network connection (that and it’s possible that apt-get was using wget to get the files it wanted). In any case, this lead me to look into internet connection sharing which was how I was connecting to the internet through my laptops internet connection.

As it turns out: If you have the firewall turned on, not all traffic will make it back in (even if it was requested by the laptop). This is a problem in my mind of the windows firewall, but one I can live with. Simply shutting off the windows firewall all together seems to have solved the problem for me… This isn’t a permanent fix, but it will at least let me get the files I need before I leave.

It’s late… I felt like sharing… It’s boring I know. That said, I’m going to bed…

Oh and I’m excited. Sunfox 2.0 is shaping up nice for the year 2008 (I’ve decided that I’m going to spend time yearly just going through the code and making adjustments to it based on the year before). So far the list of things that have been cleaned up/added is as follows:

  • Base table structure has gone from 14 tables to 10 (sunfox_groups, sunfox_group_membership, sunfox_app_blog, sunfox_app_events, and sunfox_advanced performance have been removed, a new table, sunfox_error_log has been added)
  • A custom error handler has been added that features:
    • More secure error messages
    • More useful error logging
    • Pretty errors
    • The ability to capture errors and do something with them
  • Cleaned up a dozen or so bugs in the admin panel
  • Cleaned up a bug or 2 in virtual addresses
  • Cleaned up the mysql authentication system (made it much simpler by removing the never used groups)
  • Updated FCKEditor
  • Removed the localization crap that was never used.
  • Updated FCKEditor
  • Updated mysql_tabula_library

And that’s just the start… My goals are as always to make it simpler, faster, and more useful for the stuff I do everyday. The higher level error reporting is going to save hours of debugging, and help me to write cleaner code (when set at the highest level, the software is harsh). I’ll post here with anymore updates, and probably upload the latest version to sunfox.net when the time comes.

Ok, sleep time for Justin… he has met his goals for the night.