04.16.2010   |   0comment

A friend of ours sent us an email with some information about a cool event coming up called hackUTOS – A Code Festival. It looks pretty cool and it will be interesting to see what kind of things can be hacked and created at this event.

For more information:

Event Website
Facebook Event Page


Mac,on the topic of  Linux, PHP, Tools, Web Development
03.18.2010   |   0comment

I just spent about an hour banging my head on a brick wall with the apparently well known “Unable to create selectable TCP socket” problem, which manifests itself most notably with failing imap_open() calls from PHP. It is related to fd_setsize and a frequent limit of 1024 open files (or at least selectable open files). It is quite well documented that it is some kind of bug/shortcoming in the c-client libraries that underlie a lot of email-related stuff, particularly the UW suite of tools like uw-imap, pine, alpine, etc. as well as the IMAP extension in PHP. I love being able to go Google for answers and find a ton of related content. It is really annoying though when people have been talking about this bug for years, since at least early 2007, with very very few workable solutions posted, or even workarounds.

So, I’m going to do my part: I found a workaround that I think might work very well for a lot of people who run into this problem. It’s biggest advantage is that it is very very easy to try, and has almost no downside, even if it doesn’t work for your particular situation. In my case, I found that Apache did indeed have a lot of files open, including log files for all my VirtualHosts, all the libraries that httpd depends on, files from sites that are hosted there (though it seems to open and close those just fine), and a large buildup of hundreds of entries for /tmp that were open and apparently never got closed properly. In my case, the server in question has an uptime of over 2 years, and while “apachectl restart” runs at least daily for log rotation, it seems that doesn’t really close unused file descriptors. The workaround I discovered was running “apachectl stop” followed by “apachectl start” which fixed the problem completely for me, at least for the next year or two I hope. From over 1600 open files, after restarting Apache fully that way, it only reopened about 325 files. And the imap_open() calls started succeeding as they should.

One last thought before I hop off my soapbox: when you find an answer to a problem, and that answer was hard to find or was not well documented, do your part to remedy that for the next guy or girl to hit that problem, and post your solution somewhere that Google will find it. It makes the internet a better place for all of us, and makes us all more productive. Who knows, maybe down the road you’ll run into the same problem again yourself, and not remember how to solve it until you find your own post from years before, and it will be your own time you’ll save. I fully recognize that a lot of what I accomplish each day is based on work done by others that I have found and emulated, as they say, standing on the shoulders of giants. Each contribution to the body of human knowledge lets us reach that much higher, so when you can, add your bit and as we all do that, it adds up.


Mac,on the topic of  Fun, Linux, News
09.16.2009   |   0comment

UTOSC 2009 Speaker

I’m getting excited for the upcoming Utah Open Source Conference 2009, Thursday October 8 through Saturday October 10. It’s hard to believe another year has gone by already. There are a ton of great speakers and events that I anxiously await. Not to make light of the conference presentations, some of my favorite parts are the social events, like the Boardgame Bash at the end of the conference. For a bunch of geeks, we seem to be a pretty fun crowd, I think. I also love that the UTOS folks take family seriously, and have family events on Saturday that are fun for the wife, kids, and other non-geek family members. There’s a healthy focus on bringing new people, and less technical people, into the Open Source fold, which I think is great.

This year, as soon as submission of abstracts opened, I tossed in a presentation for the first idea that came to mind, which happened to be about one of my favorite open source platforms, FreeBSD. Lo and behold, after the voting and committee meetings were over, I was one left standing, so now I’ll be presenting “Why FreeBSD is the Best Linux Distro*” at the conference. Of course, when I decided to run the risk of making a joke in a room full of highly technical purists, I knew I better use the asterisk and let them in on the joke: “* Yes, FreeBSD isn’t really a Linux Distro. It’s a different Operating System that has emulation for and binary compatibility with Linux and can run almost all the same programs.” Even though it isn’t really a Linux distribution, for me it serves the same purpose and I think it does a better job than the various Linux distributions I’ve experienced.

Anyway, early-bird discounts end on Saturday the 19th, and there are some 50% off coupon codes drifting around if you’re interested. There are codes you can get from speakers, any local Linux User Group (LUG), or other groups like UPHPU.