Centos and nginx – phpMyAdmin not working

With my default setup of Centos 6.5 64 bit and nginx 1.4.x, I got a strange error when setting up phpMyAdmin. It turns out that it was just a directory permission issue and that the default setup expects user it be apache instead of nginx.

What I got is a UI error saying something is wrong with sessions with red colors all over the place.

phpMyAdmin - Error

Cannot start session without errors, please check errors given in your PHP and/or webserver log file and configure your PHP installation properly. Also ensure that cookies are enabled in your browser.

Behind it is a clearer error as seen in error log:

PHP Fatal error: Class 'PMA_Message' not found in ...

The issue is that the permission set on /var/lib/php/session is owned by root user and apache group. Just change the group to nginx to solve the issue.

sudo chgrp nginx -R /var/lib/php/session

That’s it!

Posted in Linux | Tagged , , , | Leave a comment

Beware of Smart Prepaid Data Offers

Been experimenting with Smart’s data offers for more than a month now especially the Always ON promo. Don’t know what went wrong but most of the time, it eats up all my load as if I was using the default … Continue reading

Posted in Personal Blog | Tagged , | Leave a comment

Rooting Cherry Mobile Cosmos X

My wife got a Cherry Mobile Cosmos X phone last month. It is a mid-range phone with good specs and is powered by Android Jelly Bean 4.2.x. I’m hesitant to root it but since I have successfully rooted my other … Continue reading

Posted in Uncategorized | Leave a comment

Rooting Huawei Ascend G525

Got some entry level (or is it mid-range?) Android phone last December and I immediately rooted it. It is a Huawei Ascend G525 phone (a really good phone for the price). Rooting this Ascend G525 phone is really easy and … Continue reading

Posted in Android | Tagged , , , | Leave a comment

Ipad cannot close apps and does not turn off

When I arrived home from work, I noticed that the iPad is stuck at the app task manager screen frozen although it is still playing sounds from a farming app/game. Took mo so long to fix it and here is … Continue reading

Posted in Personal Blog | Tagged , , , , , | Leave a comment

Optimizing fonts for Slackware 14.1 – Without Infinality

Before, font optimization techniques were originally created by Infinality but support for Slackware stops sometime after the Slackware 14.0 release. Just recently, dugan shared how he optimized fonts for Slackware 14.1 which is good enough according to him. Read the … Continue reading

Posted in Linux, Slackware | Tagged , , , , | 10 Comments

I’m a Clash Of Clans Newbie

It is just about two days since I started this Clash of Clans game for iOS/Android. I don’t know what the type of game is called but you can build stuff like buildings, cannons, mortars and stuff. I remember those … Continue reading

Posted in Gaming | Tagged , , | Leave a comment

Cross domain AJAX that is cross browser as well

This is just a quick and dirty post about cross domain AJAX. If you wanted to create a working cross domain AJAX but also needs to secure the ajax requests from other referring domains, this is what we can do. … Continue reading

Posted in php | Tagged , , , | Leave a comment

The perfect crop using PIL

I’ve always wanted to display good looking thumbnail pictures with each thumbnail having the same width and height (dimension). Using some calculations, cropping and resizing, I was able to create thumbnails cropped from center and scaled down to my width/height … Continue reading

Posted in Python | Tagged , , , , | 2 Comments

REPOST – Speed up GIT via ssh with a simple config change

This is a repost of the awesome post from interrobeng.com where he was able to speed up GIT pull from Singapore EC2 against Github from 5~ seconds to 1~ second or so for the basic configuration and even less than … Continue reading

Posted in GIT, Linux | Tagged , | Leave a comment