Shin
2014-10-21

No APC on Yosemite

OPcache

After upgrading to Yosemite it turns out APC is gone, and no longer installable. Yosemite comes with PHP5.5 for which there is no APC.
But the new PHP comes with opcache which you just have to enable by adding the following to your php.ini:
zend_extension=opcache.so
On my site here it basically cut my page generation times in half straight out of the box. If you like some pretty graphics and an interface to manage it (and you run WordPress as well) grab the ‘OPcache Dashboard‘ plugin.

2014-10-18

Blocking WordPress xmlrpc.php scans

My server was frying at 100% cpu usage when I saw my apache log filled with these:
x111.com 80.82.78.166 - - [17/Oct/2014:15:28:16 +0200] "POST /xmlrpc.php HTTP/1.0" 200 - "-" "Mozilla/4.0 (compatible: MSIE 7.0; Windows NT 6.0)"
Apparently there are bots going around hammering sites that have WordPress running to try and abuse xmlrpc to ddos other sites.
I tried some xmlrpc plugins but they didn’t do anything for me so I decided to nip in the bud at .htaccess level, thus blocking the requests at apache level and preventing php and mysql from getting hammered by adding this to my .htaccess file:
RewriteCond %{REQUEST_URI} =/xmlrpc.php [NC]
RewriteCond %{HTTP_USER_AGENT} .*Mozilla\/4.0\ \(compatible:\ MSIE\ 7.0;\ Windows\ NT\ 6.0.*
RewriteRule .* - [F,L]

So now all scans get an error 403:
x111.com 93.174.93.203 - - [18/Oct/2014:12:31:54 +0200] "POST /xmlrpc.php HTTP/1.0" 403 275 "-" "Mozilla/4.0 (compatible: MSIE 7.0; Windows NT 6.0)"
And my server is idling again.

2014-09-09

Ozymandias

I met a traveller from an antique land
Who said: “Two vast and trunkless legs of stone
Stand in the desert. Near them, on the sand,
Half sunk, a shattered visage lies, whose frown,
And wrinkled lip, and sneer of cold command,
Tell that its sculptor well those passions read
Which yet survive, stamped on these lifeless things,
The hand that mocked them and the heart that fed:
And on the pedestal these words appear:
‘My name is Ozymandias, king of kings:
Look on my works, ye Mighty, and despair!’
Nothing beside remains. Round the decay
Of that colossal wreck, boundless and bare
The lone and level sands stretch far away.”

2014-08-26

And there comes the hour

He who has waited long enough, will wait forever. And there comes the hour when nothing more can happen and nobody more can come and all is ended but the waiting that knows itself in vain.

– Samuel Beckett

Snow Patrol – Set the fire to the third bar

2014-08-22

Indila – Dernière Danse

Beautiful and gutwrenchingly sad.

2014-07-20

Sunday Solo Scooter Tour

The FallenBlurry scooterBridgeGate2Q14RainTracksDucks

Hey now

2014-06-27

Le Pont Mirabeau

同心而离居

同心而离居


Read more…

Work in progress... home!
Trying to get all/most of the new code working before I start on the eyecandy.