Eponymous
   



About
The things about which I feel the need to write... The web-based journal of M. Forde, computer nerd and endurance athlete


contact

Sections

  • main
  • musings
  • running
  • DeLorean
  • code
  • unix
  • album
  • Archives

  • 2011
  • 2010
  • 2009
  • 2008
  • 2007
  • Links

  • olix0r.net
  • netmeister.org
  • Giraffes
  • Been There, Run That
  • Eat. Run. Sleep.

  •        
    01 Dec 2010

    FreeBSD 6.4 EoL
    As of yesterday, FreeBSD 6.4, and with it the entire 6.x branch, has reached its End-of-Life. It's time to upgrade (or maybe upgrayedd, for a double dose of something-or-other).

    So herein lies the problems. Months (years?) ago, I attempted to upgrade tak to FreeBSD 7.2. I plugged in a SATA disk into my workstation, installed the OS, reconfigured all the daemons, services, and functionalities tak has running, copied over a snapshot of all the data, and then edited the fstab to match the device names as they'd exist on tak.

    I removed the IDE root disk and installed the new SATA disk and tak and watched the kernel fail to find the root disk. Or the other SATA disk in tak.

    Based on the bug reports in the FreeBSD Gnats system, and various conversations in the mailing list, it seems Asus, who made the motherboard in tak, used a slightly non-standard SATA implementation on this particular board. Between the 6.x and 7.x line, some work had been done on the SATA drivers in FreeBSD and mad them more standards-compliant (a good thing). This, however, broke SATA on this Asus board.

    Tak is about 6 years old now, and other than some over heating issues, serves its purpose well. So do upgrade to FreeBSD 8.x on an IDE disk and replace the other SATA disk with another ATA disk, or do I build a new, lower-power, higher-performance system?

    If anyone actually reads this, feel free to use the new comments feature to give me feedback. I think it's working.

    [/unix] [comment] [permanent link]

    18 Nov 2009

    SATA Weirdness update
    A BIOS update from Intel corrected this issue.

    [/unix] [comment] [permanent link]

    02 Oct 2009

    Gmail and mutt
    I like mutt. Of all the mail clients I've used over the years, it sucks the least. It works well with my mail server.

    Despite having my own domain and mail server, I still use gmail for certain things; things I don't mind being retained for 3 years after I delete them, or more specifically, things I want retained for 3 years after I delete them.

    I don't like the gmail web interface. I find checking my gmail to be annoying because of this. I remembered gmail offering POP and IMAP. I figured I could use that to get my gmail. Shouldn't be too hard right?

    A quick search of Mr. Yahoo and Mr. Google gave me two good starting points: Lifehacker.com and MattCutts.com.

    I read the sites and the getmail man page and figured out what I needed to do. First I enabled IMAP for my gmail account. Next, I created the .getmail directory in my home directory then created a getmailrc file there. I want all gmail mail to be delivered to a specific mbox file without going through my normal mail delivery channels. The contents of the getmailrc file are quite simple:

    [retriever]
    type = SimpleIMAPSSLRetriever
    server = imap.gmail.com
    username = username@gmail.com
    password = usernamespasswordgoeshere
    mailboxes = ("inbox",)
    
    [destination]
    type = Mboxrd
    path = /usr/home/mforde/Mail/GMAIL
    
    The retriever section defines how getmail will retrieve the mail. In this case it uses IMAP over SSL to connect to imap.gmail.com. The mailboxes setting can be used to specify only certain gmail labels to retrieve, but I want anything in the inbox.

    The destination section tells getmail what to do with the mail once it has grabbed it from gmail. This configuration dumps it into an mbox file I've named GMAIL.

    I chose IMAP over POP because of the slightly-less-than-documented "feature" of gmail only allowing 99 messages at a time over POP.

    So to get the initial batch of 7000+ emails, I ran
    > getmail -vvv -l 
    
    to get verbose output and to leave messages on the gmail server. When that was done I pointed mutt at the GMAIL mbox and like magic, there was my gmail, organized nicely in my terminal.

    Now, I want to check to get the latest mail fairly often, and I don't want to download messages already copied over. To accomplish this, I added a crontab to run every 10 minutes and invoke
    getmail -l -n -q
    
    This tells getmail to leave copies on the server, only get new messages it hasn't already retrieved, and be quiet about it.

    This has worked out well for me. If you're interested in setting up something like this, I highly recommend reading the article at matcutts.com. That article also links to several sample getmailrc files.

    [/unix] [comment] [permanent link]

    25 Aug 2009

    FreeBSD 8 Beta 3 Available
    FreeBSD 8.0 Beta 3 is now available for download. The final release is expected in about a month.

    [/unix] [comment] [permanent link]

    27 Oct 2008

    BSD v. GPL
    Jason Dixon gave a talk at this year's NYCBSDCon entitled "BSD v. GPL (a.k.a. not the sequel to "BSD is Dying")." It's a humorous look at the differences between the licenses and their supporters. Despite the humor, he made some good points.

    You can find a copy of the presentation at The Dixon Group website.

    [/unix] [comment] [permanent link]

    17 Sep 2008

    Mailman
    The other night I installed mailman on my server. I integrated it into the apache configuration and restarted that. The mailman web interface became available as expected.

    I used the web interface to subscribe to the one list I had set up and I received an email asking me to confirm my subscription. I went to the included link, and all seemed to be good.

    Another person joined the list successfully, then sent an email to the list. This email never arrived in her inbox. She told me about it, and I checked only to find I did not have a copy either. I sent a mail to the list and promptly received a message saying that [listname] was not a valid recipient at the domain.

    That's when I realized I had forgotten to tell the mail server (postfix) about mailman. I had told apache about mailman, and mailman about postfix, but not postfix about mailman.

    I used mailman to create an alias database for its single list, then updated postfix's configuration to use that as one of its alias maps. All seems to be working now.

    In conclusion, I learned two things. One is always test your configuration before telling people it's ready. The other is, "I'm an idiot."

    [/unix] [comment] [permanent link]

    18 Aug 2008

    FreeBSD 7 SATA Weirdness
    Over the weekend I installed the x86-64 build of FreeBSD 7 on my workstation, dib. I haven't had time yet to configure everything to my liking yet, but almost everything works.

    The one really annoying issue centers around a SATA DVD burner. When this device is attached to the primary SATA controller (ICH7), the system refuses to boot from the hard drive. It reports that no system disk has been found. I've tried all of the SATA settings options in the BIOS and none work.

    If I connect the SATA burner to the secondary Marvell "RAID" controller the system boots from the hard drive without issue. In Windows, this requires another driver (which for some reason installed a copy of apache along with it). Under FreeBSD 7; however, this second controller seems to be currently unsupported, leaving me with only the IDE burner available.

    I may spend the $20 and get another IDE burner and just forget about the SATA issue, but I really would like to know what the problem is. If any one has any idea why the system would fail to boot from a SATA hard drive when a SATA optical drive is attached, please email me and give me some insight into this issue. Maybe the Unix category wasn't the best for this. I spent more time discussing the hardware/BIOS weirdness than the installation or configuration of FreeBSD7. In fact, FreeBSD 7 isn't a very good title for this either. I'm going to change that.

    [/unix] [comment] [permanent link]

    13 Dec 2007

    chdir(2)
    So today at work another developer many years my senior, with many more years experience than I, came to me with a Unixy problem.
    "When I have a program, how can I have it so the current working directory for all processes it starts isn't the one that it started in?"
    "chdir."
    "No, I want so that if this process starts something like ls, when ls stats 'dot' I want 'dot' to be the directory that process wants it to be, not the directory that process was started from."
    After about 15 minutes of me suggesting chdir while he said that's not what he wanted but then describing chdir, I finally wrote something along the lines of the following

    #include <stdio.h>
    #include <stdlib.h>
    #include <unistd.h>
    
    int
    main (int argc, char *argv[])
    {
      system("/bin/pwd");
      system("/bin/ls");
      chdir("/tmp");
      system("/bin/pwd");
      system("/bin/ls");
      chdir("/etc");
      system("/bin/pwd");
      system("/bin/ls");
      chdir("/");
      system("/bin/pwd");
      system("/bin/ls");
      return 0;
    }
    

    I compiled that, ran it, showed him the output. He said, "Yeah, that's what I want to do."
    I showed him the code.
    "chdir does that?"

    [/unix] [comment] [permanent link]

    08 Dec 2007

    Alpha
    Due to the power failure, there was the loss of several hours of work. Last night I installed FreeBSD 6.2-RELEASE on an old DEC AlphaStation 200 I have. I had started building a new, smaller kernel for it around 23:30 last night. It had not completed by the time of the power outage. I have restarted that build.
    Any one reading this would reasonably ask, "Why are you not as confused/angry/annoyed with a compile that was not finished in 7 hours as you were about one that took 3 hours?"
    The answer is simple. This AlphaStation is powered by a 100MHz DEC Alpha EV4 CPU and has 64MB of RAM. To the best of my knowledge, DEC made this machine around 1994 or 1995. I expected the build to take a long time; the machine is around a dozen years old.

    [/unix] [comment] [permanent link]

    06 Dec 2007

    How long does it take to build a linux kernel?
    It has been a number of years since I built a linux kernel. Slackware 9.1 was the last GNU/Linux distro I used before switching back to BSD. Tonight I put together a machine from some old parts (1.2GHz celeron with 256KB cache, 256MB RAM, 20GB hard drive) and installed Slackware 12. I customized a kernel configuration and attempted to build it. I don't remember the 2.4 kernel taking as long to build as this 2.6 kernel. It took nearly two hours. Granted, this machine is fairly old, but 2 hours? After I complete the tasks for which I needed this setup, I'm going to install an older Slackware with the 2.4 kernel and build that. I may also install FreeBSD and NetBSD and build their kernels. I'd like to get an idea how long it takes to compile other kernels on this rig.

    [/unix] [comment] [permanent link]