Archive for June, 2007

eAccelerator with WHM/CPanel

Wednesday, June 27th, 2007

The Problem: The same friend had a problem with installation of eAccelerator on WHM 11.2.0 hosting server. It seems like eAccelerator was installed but phpinfo() showed that caching and optimization is not enabled.

The Solution: It seemed like WHM installed PHP as CGI and that caused the problem. First, I changed PHP to be loaded as Apache Module by editing the httpd.conf. Uncomment the following lines:

LoadModule php5_module        libexec/libphp5.so
AddModule mod_php5.c

Restarted Apache Webserver using the command “/etc/init.d/httpd restart” and everything is cool now.

WHM/CPanel MySQL 5 Problem

Wednesday, June 27th, 2007

The Problem: My friend has a server freshly installed with WHM / CentOS 4.5. The problem was that after WHM is install with MySQL 5, MySQL Server refused to startup giving the message “Couldn’t find MySQL manager or server”.

The Solution: The hosting company for the dedicated server said that it is a paid support, so I searched around the Internet and found that the solution is simply to comment out a single line in /etc/my.cnf:

[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
#old_passwords=1

[mysql.server]
user=mysql
#basedir=/var/lib  ## comment out this line ##

[mysqld_safe]
err-log=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

Then issue the command “/etc/init.d/mysql restart” and it works like a charm.

Want a Discount from GoDaddy?

Tuesday, June 26th, 2007

GoDaddy register domain at a pretty cheap price, but if you want to squeeze more out of your money:

  • use the code LIFE1 to get .com domains at $6.95 (instead of $8.95)
  • use the code LIFE2 to get 10% off
  • use the code LIFE3 to get $5 off order of $30 or more

PVR for AU$199 at ALDI

Tuesday, June 26th, 2007

I noticed that there is no much reader of my blog comes from Australia, but if you are there is a AU$199 PVR selling in ALDI on 28 June 2007 (Thursday) that you might want to watch out for.   The specification is pretty decent (yeah I know, it is “just” SD):

  • 250GB Hard Disk Drive
  • Twin tuner standard definition set top box
  • DVB-T/MPEG2 compliant
  • RF input and loop through
  • 4:3/16:9 screen format
  • 7 days electronic programming guide (EPG)
  • Time shift function
  • Auto programmable and auto memory
  • 600 channel memory
  • Coaxial digital output
  • Remote control
  • Dimensions: 250 x 320 x 38mm

How to Change MAC Address on a Mac?

Tuesday, June 19th, 2007

The Problem: How do one change the MAC Address on a Mac OS X?

I have decided that my blog posting is too litte, thus, I would put some of those hacks that I found interesting up. Hope that you will enjoy it.

The Solution:

  1. If you are on Mac OS X 10.4.x (Tiger), you are in luck. To change the MAC address:
    • You might want to record down your original MAC address by doing:
      $ ifconfig en0
    • To change the MAC address:
      $ sudo ifconfig en0 lladdr xx:xx:xx:xx:xx:xx:xx:xx
    • Check that your MAC address is changed:
      $ arp -a | grep xx:xx:xx:xx:xx:xx:xx:xx
  2. Now, what if you have Mac OS 10.0.x - 10.3.x…? Peter Bartoli has put up a page on showing you how to patch your OS X Kernel here with the appropriate patch to change your MAC address.

Develop with AMP (Apache/MySQL/PHP)??

Sunday, June 17th, 2007

…Freedom is no a permission for chaos…

The Problem: Apache / MySQL / PHP has been a popular Web development platform. However, till today, there are still a lot of question about “How can I setup Apache / MySQL / PHP on {Linux | Mac OS X | Windows}.

Here, let’s show some of the simple solution of setting up a quick and easy development environment. They are “not” really supposed to be a live environment, but more for development.

The Solution:

  1. If you are running Linux, most distribution comes with Apache / MySQL / PHP packages. However, you can also use XAMPP.
  2. If you don’t have a Linux distribution setup, but you want to try Linux / Apache / MySQL and PHP, then LAMPPIX may be your choice.
  3. More people are using their shiny new Mac today. Mac OS X comes with Apache / MySQL and PHP but it is not easy to set them up. The simpler solution is to use MAMP, the Pro version is not free, but there is a free version.
  4. Finally, on Windows. You are not alone, XAMPP for Windows will make your development platform a snap to setup.