Linux

First Post On This New Web Server

Six months ago I retired a web server I had been using for 11 years. I commemorated the occasion because I was paying for a server to host my sites that had become a museum piece. Linux is so good at running Apache, MySQL and PHP that your hardware can become a decade out of date without performance becoming an issue. My other two web servers were almost as old. The company I use for hosting, SoftLayer, recently offered me a deal to upgrade. A sales rep told me, "After reviewing your account we ... (read more)

Fix a 'No HTTP Transports' Error in WordPress

I recently installed WordPress on this server for a new blog. I've been using homebrew software for years, but I want to see whether I like WordPress enough to switch this blog and others to the platform. I need all of my sites to be usable on mobile devices, a goal that is a long way from being true today. The new blog is far better out of the box on mobile than anything I've created on my own. In the two weeks I've been running WordPress 4.4.2, I encountered several problems where it could ... (read more)

Boot Device Not Found, Brain Also Missing

My desktop PC, an HP Pavilion p6000, crashed this morning and won't boot successfully, displaying an ominous "Boot Device Not Found" error instead. This used to be the kind of situation that would send me into a fetal position mumbling "why didn't I make a backup?" over and over to myself. But a few years ago, I burned to CD a free copy of Knoppix, a stripped-down version of Linux, that can be used in an emergency like this. I booted the computer off this CD and found all of my files are still ... (read more)

Deterring Spammers with Fake MX Records

For the past 48 hours, I've been dealing with a Sendmail server that was shutting down frequently with a load average above 13. The server's getting flooded constantly with spam attempts to non-existent users on more than 100 domains. I've set up Sendmail to use a virtusertable that rejects every non-valid email address with a "user unknown" error. This is helpful, but Sendmail still has to take the time to reject each spam attempt. Since all but six domains on the server don't receive any mail ... (read more)

Peace Declared Between Myself and Sweden

As it turns out, Sweden did not intentionally declare war on my web server earlier this month. Programmer Daniel Stenberg explains how the international incident happened: A few years ago I wrote up silly little perl script (let's call it script.pl) that would fetch a page from a site that returns a "random URL off the internet." I needed a range of URLs for a test program of mine and just making up a thousand or so URLs is tricky. Thus I wrote this script that I would run and allow to get a ... (read more)

Sweden Declares War on My Web Server

Since 4 a.m. Friday, a computer at a Swedish IT company made more than 1.5 million web requests to my web site URouLette, which links to random web pages stored in a MySQL database. They're coming in at a speed of 38 requests a second. My MySQL database server can't handle that many requests, so by Friday afternoon Workbench and a bunch of other sites slowed to a crawl as the web server began belching black smoke. A massive crash was imminent. The last time somebody did this, I used the Linux ... (read more)

Fixing a 'Recompile with -fPIC' Error in MySQL

I run my web servers by compiling the most important components from source code, which makes it possible for me to add security fixes more quickly and fine-tune my installations of Apache, MySQL and PHP. While compiling the new release PHP 5.2.8 this weekend, the make process failed with this error: /usr/bin/ld: /usr/mysql/lib/mysql/libz.a(compress.o): relocation R_X86_64_32 against 'a local symbol' can not be used when making a shared object; recompile with -fPIC /usr/mysql/lib/mysql/libz.a: ... (read more)

Apache HTTP Server 2.2.10 Released

This afternoon I upgraded the servers that run the Drudge Retort and SportsFilter to Apache 2.2.10, a minor upgrade released on Oct. 15 that fixes a cross-site scripting (XSS) vulnerability in FTP URLs discovered by Marc Bevand of the network security company Rapid 7. The rest of the changes in the new version look like minor bug fixes. I compile the Apache web server from source code on both servers, a process that was difficult the first time around but has been easy since then. After I ... (read more)

Setting Up Westell Modems with Linksys WRT54G Routers

I connect to my high-speed DSL Internet service using a Westell WireSpeed modem that's hooked up to a Linksys WRT54G router. Last week a power outage hosed the settings on the modem and router, which knocked me offline until I figured out the proper configuration. I was so desperate at one point that I called my ISP's outsourced tech support, speaking for 15 minutes to a pleasant wage slave in Bangalore or another distant port o' call center who could not have been less helpful. For the help of ... (read more)

Adding Atom 1.0 Support to RSS Sites

I switched to Atom 1.0 on Workbench two months ago, a move that hasn't been as smooth as I'd like because of one popular aggregator that doesn't support the format. This site is created using Wordzilla, a LAMP-based weblog publishing tool that I've developed over the last year. Writing code to generate Atom feeds in PHP was extremely simple, since most of the code used to generate RSS feeds could be applied to the task. Atom uses a different format for date-time values than RSS, so I had to ... (read more)