Posts categorized “server”.

Another Reason I hate ie6

I recently had a ie6 that only broke when using digest authentication, all other browsers worked fine. Hence, yet another ie6 specific hack…

From Apache:

The Digest authentication implementation in previous Internet Explorer for Windows versions (5 and 6) had issues, namely that GET requests with a query string were not RFC compliant. There are a few ways to work around this issue.

The first way is to use POST requests instead of GET requests to pass data to your program. This method is the simplest approach if your application can work with this limitation.

Since version 2.0.51 Apache also provides a workaround in the AuthDigestEnableQueryStringHack environment variable. If AuthDigestEnableQueryStringHack is set for the request, Apache will take steps to work around the MSIE bug and remove the query string from the digest comparison. Using this method would look similar to the following.

Using Digest Authentication with MSIE:

BrowserMatch "MSIE" AuthDigestEnableQueryStringHack=On

This workaround is not necessary for MSIE 7, though enabling it does not cause any compatibility issues or significant overhead.

See the <a href="http://httpd.apache.org/docs/2.0/mod/mod_setenvif.html#browsermatch">BrowserMatch</a> directive for more details on conditionally setting environment variables

s3 backup + mySql dump

These two open source scripts are very useful when combined with cron:

s3 Tools : http://sourceforge.net/projects/s3tools/

OpenSource tools to access Amazon S3 file storage. s3cmd - unix-like tools to manipulate stored files from the command line, s3fuse - driver to mount the S3 storage locally.

and

automysqlbackup : http://sourceforge.net/projects/automysqlbackup/

A script to take daily, weekly and monthly backups of your MySQL databases using mysqldump. Features - Backup mutiple databases - Single backup file or to a seperate file for each DB - Compress backup files - Backup remote servers

EC2 Persistent Storage

This is the main issue I currently have with Amazon’s EC2: the lack of persistent storage. However, according to this press release,

“This new feature provides reliable, persistent storage volumes for use with Amazon EC2 instances. These volumes exist independently from any Amazon EC2 instances, and will behave like raw, unformatted hard drives or block devices, which may then be formatted and configured based on the needs of your application. The volumes will be significantly more durable than the local disks within an Amazon EC2 instance. Additionally, our persistent storage feature will enable you to automatically create snapshots of your volumes and back them up to Amazon S3 for even greater reliability.”

Here’s the thread

Amazon Elastic Compute Cloud (Amazon EC2)

I’m currently evaluating this service, after using some of the other amazon services such as s3, this looks super sexy in a techy way. Amazon Elastic Compute Cloud (Amazon EC2) is a web service that provides resizable compute capacity in the cloud. It is designed to make web-scale computing easier for developers. Amazon EC2’s simple web service interface allows you to obtain and configure capacity with minimal friction. It provides you with complete control of your computing resources and lets you run on Amazon’s proven computing environment. Amazon EC2 reduces the time required to obtain and boot new server instances to minutes, allowing you to quickly scale capacity, both up and down, as your computing requirements change. Amazon EC2 changes the economics of computing by allowing you to pay only for capacity that you actually use.  Amazon EC2 provides developers the tools to build failure resilient applications and isolate themselves from common failure scenarios

Heck, create a drupal site on EC2 with a single line: ec2-run-instances ami-4c7b9e25 -k gsg-keypair

and for us Mac OSX users, here’s a getting started on ec2

Amazon’s Getting Started Guide