Block Advertisements in Gmail Or Anything Else
I highly recommend Gmail if you haven’t checked it out already. The web interface allows you to access your email from anywhere, I rarely get any spam in my Inbox, there’s ton of free storage space, and email conversations are threaded making it easier to keep track of messages (i.e. you see a single email rather than 50 “Re: Hello” messages).
Unlike Yahoo Mail, there are no advertisements appended to the emails you send. Instead, Google brings in revenue from their “sponsored ads” displayed on the sidebar of Gmail’s interface. But with a few addons for Firefox, you can completely remove these. The only real downside of Gmail is the security concerns of Google scanning all your emails to display contextual ads. But I think these concerns can apply to anything on the internet. Check out FirePGP for encryption if you are worried.
Google has recently began to roll out rolled out a new version of Gmail that improves speed dramatically, but can break many old addons and scripts, including those that block ads in Gmail. But blocking them yourself is simple, requiring only a few steps.
NOTE: the Better Gmail 2 addon add on blocks ads and has many other useful features. Only do the below if you don't want to use it.
- Install Firefox, a web browser that’s safer and more customizable than M$ Internet Explorer.
- Install the Adblock Plus addon. Wait to restart Firefox after step 3.
- Install the Adblock Plus Element Hiding Helper addon, which helps select special blocks of content to hide. Restart Firefox after it’s installed.
- Subscribe to the EasyList filter, which tell Adblock how to block ads.
- Bring up Adblock’s Element Hiding selector by right clicking on the red “ABP” icon and selecting “Select element to hide.” Or press down the shortcut keys CTRL+SHIFT+K.
- When the red selector comes up, click the area on the right where the ads are above “Sponsored Links” right below “Print all.”

- Click “Add filter rule.”
Simply installing Adblock Plus removes most ads, and the Element Hiding Helper can be used to take out any that remain.
Rotate Apache (or any) logs on linux
Logs can quickly grow to take up disk space. To alleviate this problem, install logrotate if your distribution does not come with it already. Edit /etc/logrotate.conf changing the first line to the period when you want to rotate the the logs (daily, weekly, monthly, yearly). Change the rotate command under that to how long you want to keep old logs for, e.g. if rotating logs every month and to keep the logs for a year use rotate 12.
Edit (or create if necessary) /etc/logrotate.d/httpd to contain the following:
/usr/local/apache/logs/*_log {
monthly
rotate 12
compress
missingok
notifempty
sharedscripts
postrotate
/usr/local/apache/bin/apachectl graceful
endscript
}
Where:
- monthly: time period elapsed before the logs are rotated
- rotate 12: logs are rotated 12 times before being removed (i.e. 1 year), if set to 0 old logs are removed rather then rotated
- compress: old logs are compressed with gzip to save disk space
- missingok: if logs are missing skip and do not issue an error
- notifempty: do not rotate empty logs
- sharedscripts: only run postrotate command once for all the logs in the specified directory, rather for each log
- postrotate: command to run after logs are rotated, necessary for apache to start logging again
Be sure the paths /usr/local/apache/logs/*_log and /usr/local/apache/bin/apachectl graceful are correct for your configuration. Graceful will restart apache without ending any current requests being served.
Thanks to nixCraft for the hints.
Plesk error: mail server requires authentication to send to a non-local e-mail address
Funny how most of the odd problems that I run into have to do with Plesk. This error randomly started happening one day when trying to send email to any user on a Plesk windows server:
503 This mail server requires authentication when attempting to send to a non-local e-mail address. Please check your mail client settings or contact your administrator to verify that the domain or address is defined for this server.