Archive for the ‘Linux’ Category

Monitor Your Web Services from Bash

with one comment

A lengthy explanation of a one liner I use to detect when a service is not responding. Bash-fu included.

Nginx / Memcached Direct Page Caching

without comments

There are a few different approaches to caching; data caching, fragment caching, and full-page caching. But first, here’s the typical model of a web application. User requests a page, and it works through the web server, through several layers, and finally to the database. Data caching takes the place of a database call and can be effective if there are a lot of database requests.  You would typically want to do this if you know that a piece of data is very common and unlikely to change. This saves time on one step of the process. Fragment caching is a [...]

Nginx 0.5.33 + SSL + gzip = corrupt data (on large files)

with 2 comments

First off, I love Nginx—It is by far, the best web-server I have ever used. I came across a bug recently which really caused me to scratch my head. It took me a couple days just to isolate the issue and then I couldn’t find anyone who wrote about it—so that’s what I’m doing here. The problem: On one particular javascript file I could never download the whole thing. This file was the concatenated version of about 8 files totaling near a megabyte. Turning on gzip compression helped significantly: 1mb turned into just over 250k. One caveat though, was that [...]

Installing php5-mssql in Ubuntu 8.04 LTS

with one comment

I needed to migrate an old website which still relied on an MSSQL connection not supported in our new server I just built. Luckily someone else has already figured this one out (http://ubuntuforums.org/showthread.php?t=350269&page=3) Here’s the gist of it (pertaining to php5): aptitude install php5-sybase This installs the generic support for mssql (FYI, mssql is based on sybase) but is missing a few mssql specific functions for php. pear install –nodeps MDB2_Driver_mssql This command installs those extra functions and everything seems to work. Cheers!