Improving Apache Clustered Performance

  1. Use Apache 2.4 (so if you use Centos / RHEL, use v7). This has lower memory requirements, stable Event MPM (see below) and far more functionality.
  2. If you terminate SSL at Apache, use a clustered cache to keep track of SSL sessions. Otherwise the SSL session establishment will have to be renegotiated every time you hop server (if you have sticky sessions at the load balancer, this may not be the case, but sticky sessions can be unreliable) and this is very expensive.
  3. Consider using nginx or the event MPM where you can (eg for static requests).
  4. Disable Etags (FileEtag None). As with SSL, you will get a new Etag every time you hop server (so sticky session caveat applies again) breaking the client side cacheing. Disabling Etags will drop back to Last-modified.

 

Blog spam from 37.59.173.124

Not sure why OVH allows one of its customers (37.59.173.124) to blog spam

From: Jason Peterson <zanationline@gmail.com>
Subject: Increase Sales / Customers

Message Body:
Would you like to see you how your competitors are getting more sales than you are?

Improving your website visibility online is more important than ever. 

What's a good phone number so we can discuss my plan?

Thanks for your time

Jason

shell based SSL/TLS tester: testssl.sh

testssl.sh is a free command line tool which checks a server’s service on any port for the support of TLS/SSL ciphers, protocols as well as some flaws. It’s designed to provide a clear output for a “is this good or bad” decision. It works for Linux and BSD out of the box – no need to install or configure something, no gems, CPAN, pip or the like.

If you use the Qualys online SSL checker a lot, you need to try this, it’s very fast if you are experimenting with SSL config options.

Source: shell based SSL/TLS tester: testssl.sh

Command Line tools

Here are the tools I use to live my  life on the command line:

Mail

Client: Mutt
Filtering: procmail, imapfilter
Search: mairix

General Web

Client: Lynx, Links, Elinks, w3m
Tools: wget, aria2c, curl

Web Services

Toodledoo: toodledo (ruby gem)
Misc search engines: Surfraw
Google Calendar: gagenda
Ebay: esniper
BBC Iplayer: get_iplayer
Google Drive: gdrive
Google Mail: mutt (via IMAP)
StackExchange: sx.el (via Emacs)

Social Media

Twitter: Rainbowstream
Facebook: fbstream (RIP)
Hackernews: hackernews (via Emacs)
Chat: centerim

Software

Editor: Emacs, Vim
Icinga: icli, qicinga
RSS: Newsbeuter, Feednix
Weather: weatherman

File Viewers

MS Word docx: docx2txt.pl
MS Word: antiword
PDF: pdftohtml
RTF: unrtf
(all of these can be integrated into mutt via ~/.mailcap)

Commandline IMAP Mail check & Screen

I wanted a commandline IMAP mailbox checker so I wrote one: imapchkr

Normal output for this is as below:

➜  ~  [jamespo: 0/190] [gmail: 0/80] 

But I decided I wanted to embed it in my GNU screen hardstatus so expanded it to offer a short output option (imapchkr -s). See bottom left corner for output.

➜  ~  dstat  
----total-cpu-usage---- -dsk/total- -net/total- ---paging-- ---system--  
usr sys idl wai hiq siq| read  writ| recv  send|  in   out | int   csw   
  1   0  98   0   0   0|  45k   65k|   0     0 |   1B    2B| 114   112   
  0   0 100   0   0   0|   0     0 | 106B 1003B|   0     0 |  45    55   
  1   0  97   3   0   0|   0    44k| 172B 1122B|   0     0 |  65    65   
  1   0  99   0   0   0|   0     0 |2234B 5945B|   0     0 | 168   183   
  1   1  99   0   0   0|   0    56k| 109B 1145B|   0     0 |  91   104   
  3   1  95   0   0   0|   0   208k| 122B 1187B|   0     0 | 206   219 ^C  
➜  ~    
j:0 g:0 Sat Feb 28 2:30pm Get a hair cut 0$ ssu  1$ ~    2$* ~  3$ ~  4!$ 192.168.0.254  5-$ ~

Configure your ~/.screenrc like this:

backtick 1 60 60 /home/james/bin/screen_agenda
backtick 2 90 90 /home/james/bin/imapchkr -s
hardstatus on
hardstatus alwayslastline
hardstatus string '%{wk}%2`%{yk}%1` %{= kG}%-Lw%{= kW}%50>  %n%f* %t%{= kG}%+Lw%<'

screen -t root
screen -t mail
screen -t root

I'm also using gcalci for Google Calendar appointments.