
OSWD: Two Designs
Open Source Web Design
If you’re mainly a programmer, but would love to turn out sites with a bit more fit and finish, this site is for you. They provide packaged “site designs” which include sample HTML, css and images in a ready-to-download zip file. Lots of styles to choose from, and frequent new additions make it very helpful. [via lifehacker]
MySQL Performance Blog
This is one of those sites/blogs that you find while researching one topic, and then just keep reading and reading. Tons of well written, informative and helpful entries. Great discussion in the comments and on the attached forums.
The post that first sucked me in was Why MySQL could be slow with large tables ?
Benchmarking [php] magic
A great entry that considers the cost of many of the new features in the PHP5 object model. Also situated on another great blog that’s worth adding to your feed collection.
Amazon SimpleDB
A very interesting addition to their much talked about Web Service suite, SimpleDB provides a database (or directory service) in their computing cloud, along side S3, EC2 and others. With a pay-as-you-go model and some interesting features, this is the kind of environment that is sure to foster some awesome new projects.
Brady Forrest provides a great overview of the product and pricing on O’Reilly Radar.
Here are some quick notes on the step-by-step process I used to set up automated backups to Amazon’s S3 on my linux server. Not much is Ubuntu, or even linux, specfic, so it should be quite applicable for other platforms.
sudo apt-get install ruby
sudo apt-get install libopenssl-ruby
cd ~
wget http://s3.amazonaws.com/ServEdge_pub/s3sync/s3sync.tar.gz
cd /usr/local
sudo tar xzfv ~/s3sync.tar.gz
cd /usr/local/s3sync
cp s3config.yml.example s3sync.yml
wget http://mirbsd.mirsolutions.de/cvs.cgi/~checkout~/src/etc/ssl.certs.shar?rev=1.10;content-type=application%2Fx-shar
cd /usr/local/s3sync
./s3cmd.rb -s createbucket bucketname
cd /usr/local/s3sync;
./s3sync.rb -snrv --delete /etc/ bucketname:etc
./s3sync.rb -srv --delete /etc/ bucketname:etc
I created a simple script and threw it in /etc/cron.weekly/s3backup
#!/bin/bash
SARGS=“-vs” # you can add -n in here for testing, remove s for non-ssl, remove verbosity, etc
SENDMAIL=/usr/sbin/sendmail
EMAIL=myuser@mydomain
cd /usr/local/s3sync
echo -e “To: ${EMAIL}\nSubject: s3backup results\nContent-type: text/plain\n\n” > /tmp/s3backup.log
pg_dumpall -Ucdmoyer | gzip > /opt/www/db/pg_dumpall.gz #/root/.pgpass is needed for this
./s3sync.rb ${SARGS} —delete -r /etc/ bucketname:etc » /tmp/s3backup.log
./s3sync.rb ${SARGS} —delete -r /opt/ bucketname:opt » /tmp/s3backup.log
./s3sync.rb ${SARGS} —delete -r /var/backups/ bucketname:var/backups » /tmp/s3backup.log
cat /tmp/s3backup.log | ${SENDMAIL} “${EMAIL}”
This was originally done on Ubuntu Gutsy Gibon, so your mileage may vary.
Things I did:
Total Cost: $0.29 so far, and it will cost me $0.15 at the end of the month. It seems to cost a bit less than a penny each time I sync.