Archive for the ‘OS X Server’ Category

I’ve suddenly found myself running out of fds, which brings things to a screeching halt. For future reference, here are some helpful things to remember.

Check the current settings with launchctl:

www.feorlen.org[feorlen]:/etc$ launchctl limit
cpu unlimited unlimited
filesize unlimited unlimited
data 6291456 unlimited
stack 8388608 67104768
core 0 unlimited
rss unlimited unlimited
memlock unlimited unlimited
maxproc 1000 2500
maxfiles 256 unlimited

change for this shell only:

www.feorlen.org[feorlen]:/etc$ launchctl limit maxfiles 1024 unlimited

Make systemwide changes in launchd.conf:
http://support.apple.com/kb/TS1659

WWDC is come and gone and I’m home with shiny new goodies. I installed Snow Leopard on my laptop during the week and that went well. Exchange support seems to be working and various glitches are (mostly) minor. So I started plotting to upgrade my server.

Talking to some folks in the IT lab, what I got was they have been working on upgrade and migration. That’s nice to hear as I’m always skeptical. Tiger->Leopard was new hardware for me so I just started from scratch, but this time I’d rather not. With the mess that my email has been lately I decided to jump in and give it a try. I was ready for some wonderful automagical upgrade goodness, and to be rid of cyrus forever.

After getting a good, bootable backup I put the DVD in and let it go. I got to the second reboot and there it sat: The cheerful Welcome screen, staring at me for 90 minutes until I finally power cycled the box. On reboot I got more of the same. It’s basically sitting there continuously flushing the firewall rules. So far, I’ve filed the bug and they are looking at some logfiles. And in the meantime, imapd is still crashing.

Once again, my mailbox got corrupted. Makes me want to hand it all over to Google and get out of the email hosting business (such as it is, with three mailboxes.) But Certain Users are objecting.

In the meantime, I have this:

Reconstructing cyrus mailboxes in Mac OS X Server 10.3 or later

I hope you never need it. I’m posting it here so I can remember where to find it.

Some months back I hacked my WordPress akismet plugin to log all comments to my spinnyspinny.com blog. I’ve had 915 comments posted. 900 of them are spam. Of the 15 real comments, 10 are mine. 656 of those are from one ip address: 200.63.42.136. 102 of them are on a single message, the first one I posted when I set up the blog.

For those 656 spam comments from one address, there are 655 unique authors with 655 email addresses and 656 websites. Clearly somebody had a mistake there. And they aren’t all with the same setup, as the most common user agent has only 521 hits and the rest are from 9 others, all some Mozilla variant for Windows. Whoever this is, they are spamming all my posts more-or-less the same. Spam comments are from only about the past month, with a big spike around the Labor Day holiday weekend. Then, it appears, someone went on vacation until the 17th.

I’ve been poking at WordPress plugins to see what I can do with one. (Hence the proliferation of sidebar gizmos.) I want to write something that will use the Splunk REST API to show interesting things about my server in a widget on the blog. The handy-dandy new PHP SDK will help a lot here. So that much is all good.

But in the process of checking out a bunch of different WP plugins, I have noticed an annoying habit of hiding the configuration pages all over the map. Sometimes there’s a link in the Plugin Management page. Or maybe it’s a tab on the Settings page. Some of the widgets are configured on the Widgets page, itself buried under the Design tab. Ok, I know they were written by different people, and for different versions of WordPress. Which radically changes the administration UI with each new major release. But boy is it a pain to go and hunt down where the settings went this time just to see if this thing I downloaded actually does something interesting.

Move along, nothing to see here.

Finally the blog is up and running. I had it all working nicely last night and then somehow apache decided it liked “500 Internal Server Error” more than WordPress. The problem was that it wouldn’t allow access to either index.html or index.php, which I thought I had already taken care of with DirectoryIndex.

After mucking about with the conf files, I finally went back to Server Admin and did it from the GUI. Which, frankly, I still don’t really trust. Sure, the new Leopard version doesn’t totally eat my configuration any time it touches it, but it still does weird things I don’t understand. DirectoryIndex “index.php” “New”? Well, if it somehow decides to break later, I still have the backup copy of the configuration.

Spoke too soon. The damn thing changed AllowOverride for every single one of my sites, causing WordPress permalinks to break. I should file a bug, but I don’t feel like setting up a test server to reproduce and document.