Techkiwi's Blog

The adventures of a technical kiwi


June 2014

Nginx & PHP5-FPM WordPress upgrade issue

Tonight I upgraded my Ubuntu 14.0 server to the latest of Nginx & PHP5-FPM packages  which broke my WordPress site running the latest 3.9.1 version of WordPress so I thought I would share the fixes used to resolve it.


It broke it in two different places, one was a PHP5-FPM related error the other was related to Nginx so I have split each resolution below.


First error: PHP5FPM


Firstly the issue straight after the upgrade was that I would get a “505 Error page not found” fault, I checked the nginx error log files to find this error: connect() to unix:/var/run/php5-fpm.sock failed (13: Permission denied).


The fix was update the php5 config file: /etc/php5/fpm/pool.d/www.conf

Find this block:

;listen.owner = www-data
; = www-data
;listen.mode = 0660

Now edit the block to look like this:

listen.owner = www-data = www-data
listen.mode = 0666


Now restart php5-fpm “service php5-fpm restart”


Second error: Nginx


This solved the first error but now I am getting a second error relating to the Nginx upgrade to version Nginx 1.4.6.


The error in the Nginx logs: “rewrite or internal redirection cycle while internally redirecting”


The resolution is to add this line of code into each Nginx server config, NOTE if might have two one for port 80 one for port 443 etc


I just added this block:


Now restart Nginx: “service nginx restart” after rebooting all of my errors have been resolved.
Please use the above at your own risk and do your own research but in my case this has resolved my issues.

Ipredator Multiple OpenVpn Sessions / Devices

One of the things I wanted from Ipredator which I could not find at the beginning was the ability to have multiple OpenVPN sessions or devices running at the same time.

Apparently there is documentation for this (I and others couldn’t find it) but the friendly staff at Ipredator have given me the tip.


You can use different server addresses to use multiple devices for example:

Device 1:

Device 2: is a newer address that has been added and using the above I have successfully been connecting two devices at the same time.

Ipredator OpenVPN Android Setup

I have been tinkering with VPN services provided by (One of The Pirate Bay founders companies) for the past couple of days.

I will be doing a more in depth write up about their services and how I have experienced them in the future (So far I am happy with the service) but this post is just to give others an updated configuration file so that it can be easily used on the Android platform.


After successfully getting the VPN connected with OpenVPN for my LinuxMint machine I moved onto my Android device where I have had quite a few issues.

It appears that the configuration file they are providing does not work correctly with the latest version of OpenVPN for Android (Which is what they recommend).


I have adjusted this configuration file manually by creating a new one and then migrating the lines of code I can see that they have in their configuration file which seems to work perfectly.

The generated config file was used on Android 4.4.2 Kitkat via my new Sony Z2 and successfully opened and held a OpenVPN connection to the Ipredator network.


It appears it is mostly relating to the GUI options that are at the top of the configuration.


So far I am averaging speeds around 2/2mb’s from fibre 100/50 based connections here, the only end point servers are located in Sweeden so this is acceptable at this stage in my opinion.

Configuration Download Link:


*Note* Please use this configuration file at your own risk, it has been tested but checking the settings are correct for security is up to you

Create a free website or blog at

Up ↑