Installation of PowerAdmin Web Client

Written by Mike on October 31, 2008 – 1:42 pm -

In previous article I have explained how to install and configure PowerDNS with MySQL. Now, I am going to explain the steps to install PowerAdmin which can be used as Web Client or front End to create and manage DNS Zones through PowerDNS.

Download and Installation of PowerAdmin

1) Download PowerAdmin from and extract it.

2) Copy poweradmin folder to the document root of the webserver i.e. /var/www/html

Configuring PowerAdmin

Browse where will be the IP of the Server. You will get following screen when you browse your the Power admin.

pwradmin1 Installation of PowerAdmin Web Client

Select the Language in which you want to install PowerAdmin and press “Goto step 2″

Following screen will show you a warning about backing up existing database before you proceed with. As per suggestion I would too suggest you to take backup of existing database. If you are doing a fresh install you can proceed to “step 3″

pwradmin2 Installation of PowerAdmin Web Client


Here you will have to provide information of Database, user and its login and admin password. As per the image given below:

pwradmin3 Installation of PowerAdmin Web Client

STEP: 4 and 5

Now you will have to provide the Database username (if you have created for the ddatabase power_admin). We have used user as root and its login details. Now Press “Goto steps 5″ and then press “Go to Step 6″

pwradmin4 Installation of PowerAdmin Web Client

pwradmin5 Installation of PowerAdmin Web Client


Create a file as /path/to/poweradmin/inc/ and copy and paste the contents from “<?php ?>” (Text shown in the Red box).

pwradmin6 Installation of PowerAdmin Web Client

If you get following on your screen; then PowerAdmin has been installed and configured on the server. This screen will also provide you the Admin login details using which you will able to login into the PowerAdmin.

pwradmin71 Installation of PowerAdmin Web Client

Now remove the install Directory from PowerAdmin folder and access PowerAdmin using URL and use the login details provided by PowerAdmin.

login Installation of PowerAdmin Web Client

That’s All :)

Tags: ,
Posted in Dedicated Server Hosting | 2 Comments »

Query Cache in MySQL

Written by Mike on October 30, 2008 – 8:12 am -

What is Query Cache and How it works?

One of the best ways to speed up your web application is to enable query caching in your database, which caches commonly used SQL queries in memory for virtually instant access by the next page that makes the same request.

The query cache stores the text of a SELECT statement together with the corresponding result that was sent to the client. If an identical statement is received later, the server retrieves the results from the query cache rather than parsing and executing the statement again.

How to enable caching in MySQL?

Query Cache Can be Enabled by two ways
1) Using MySQL Queries
2) Using MySQL Configuration file i.e. my.cnf

1) Enabling Query Cache by executing query:

Login to MySQL prompt

[root@server ~]# mysql -u root –p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or g.
Your MySQL connection id is 16 to server version: 

Type 'help;' or 'h' for help. Type 'c' to clear the buffer.

Now setup cache size 16Mb (16*1024*1024=16777216):

mysql> SET GLOBAL query_cache_size = 16777216;
Query OK, 0 rows affected (0.00 sec)

You can check the cache size by executing following query:

mysql> SHOW VARIABLES LIKE 'query_cache_size';
 | Variable_name    | Value    |
 | query_cache_size | 16777216 |

2) Enabling Query Cache in MySQL Configuration (my.cnf)

You can setup them in /etc/my.cnf (Red Hat) or /etc/mysql/my.cnf (Debian) file. Open my.cnf uing vi or pico editor and insert following into it:

query_cache_size = 268435456

In above example the maximum size of individual query results that can be cached set to 1048576 using query_cache_limit system variable. Memory size in Kb.

Tags: ,
Posted in Dedicated Server Hosting, Linux VPS Hosting | 1 Comment »

How To Upgrade Perl Version On Cpanel Server

Written by Jahangir on October 30, 2008 – 6:32 am -

First check the current version of Perl

# perl -v

If the older version of Perl is running on server, you get an output something like,

This is perl, v5.8.7 built for i686-linux

Upgrade perl on the Cpanel server
1) Download the latest perl installer from cPanel site.

# wget

Untar the file as,

# tar -zxvf perl588installer.tar.gz

Change the directory to perl588installer

# cd perl588installer

Now run the installer file as,

 # ./install

Check perl modules

 # /scripts/checkperlmodules

Force a cPanel update

 # /scripts/upcp –force

Check the new installed perl version using “perl -v” and you get an output something like,

This is perl, v5.8.8 built for i686-linux

Tags: , , , ,
Posted in Dedicated Server Hosting, Linux VPS Hosting | 1 Comment »

Install and Configure PowerDNS with MySQL

Written by Mike on October 29, 2008 – 2:44 pm -

What is PowerDNS

PowerDNS is a versatile DNS server, written in C++ and licensed under the GPL. It runs on most Unix derivatives and on Microsoft Windows. PowerDNS features a large number of different backends ranging from simple BIND style zonefiles to relational databases and load balancing/failover algorithms. A DNS recursor is also included as a separate program. (Definition as per

Installation of PHP, MySQL other required modules

Installation of PowerDNS and PDNS requires certain modules which are PHP(if you are going to install PowerAdmin web client too) Mysql, DB and MDB2. you can install all these modules using following commands:

yum install mysql mysql-devel mysql-server -y
yum install php-devel php-imap php-pear php-ldap php-gd php-mbstring php-ncurses php-xmlrpc php-domxml php-mysql php-odbc
pear install DB
pear install pear/MDB2#mysql

Creating Database and Tables

Once you install these modules, next step is to create Database for PDNS. To do that login to MySQL Console using mysql root password and execute following query to create database:

mysql> create database power_admin;

You can create any user as database user for power_admin. Here I have used root.

Next Step is to create Empty tables inside this database. Following are the SQL Queries to create tables

use power_admin;

create table domains (
id INT auto_increment,
last_check INT DEFAULT NULL,
notified_serial INT DEFAULT NULL,
primary key (id)

CREATE UNIQUE INDEX name_index ON domains(name);

CREATE TABLE records (
id INT auto_increment,
change_date INT DEFAULT NULL,
primary key(id)

CREATE INDEX rec_name_index ON records(name);
CREATE INDEX nametype_index ON records(name,type);
CREATE INDEX domain_id ON records(domain_id);

create table supermasters (
nameserver VARCHAR(255) NOT NULL,

GRANT SELECT ON supermasters TO power_admin;
GRANT ALL ON domains TO power_admin;
GRANT ALL ON records TO power_admin;

Installation and Configuration of PDNS

PDNS can be installed using YUM or using by the RPM provided by PowerDNS. Following is the command to install PDNS using yum

yum install pdns pdns-backend-mysql

Now we have to configure PDNS to work with MySQL Server. Open file /etc/pdns/pdns.conf which is configuration file for PDNS and search for “launch=bind” and change

# launch        Which backends to launch and order to query them in


# launch        Which backends to launch and order to query them in

Save and exit from the file.

Now restart the pdns Service using command “service pdns restart”. Now check if the server is responding to port 53 i.e. Port for DNS service. You can check that using telnet i.e. “telnet localhost 53″.

telnet Install and Configure PowerDNS with MySQL

If you get something like above image then pdns has been installed sucessfully on your Server/VPS.

You can go through This Article for installing and configuring PowerAdmin.

Tags: , ,
Posted in Dedicated Server Hosting, Linux VPS Hosting | 2 Comments »

PhpMyAdmin Error :: SQLite failed to open/create session database

Written by Jahangir on October 29, 2008 – 4:58 am -

Error :-
Getting following error whenever you access PhpMyAdmin either from WHM or cPanel.

Warning: session_start() [function.session-start]: SQLite: failed to
open/create session database
`/var/cpanel/userhomes/cpanelphpmyadmin/sessions/phpsess.sdb' - unable
to open database:
/var/cpanel/userhomes/cpanelphpmyadmin/sessions/phpsess.sdb in
/usr/local/cpanel/base/3rdparty/phpMyAdmin/libraries/ on
line 86

Fatal error: session_start() [<a
Failed to initialize storage module: sqlite (path:
/var/cpanel/userhomes/cpanelphpmyadmin/sessions/phpsess.sdb) in
/usr/local/cpanel/base/3rdparty/phpMyAdmin/libraries/ on
line 86

Cause :-
This is usually a bug in the PhpMyAdmin configuration on cPanel server.

Solution :-
Manually edit /usr/local/cpanel/3rdparty/etc/phpmyadmin/php.ini file as follow:

1) Login to shell of the server using root login details and open the file “/usr/local/cpanel/3rdparty/etc/phpmyadmin/php.ini” using vi or any other editor.

2) Search for the [Session] variable & underneath it, change the following
session.save_handler = sqlite
session.save_path = /var/cpanel/userhomes/cpanelphpmyadmin/sessions/phpsess.sdb

session.save_handler = files
session.save_path = /tmp

By default, PhpMyAdmin uses sqlite as as the file handler, but it needs to be changed to files & the location of the session files to be stored needs to be changed to /tmp which is the standard/default place to store temporary files.

3) Once all changes done, save & exit the php.ini file & restart the apache using “/scripts/restartsrv_httpd“.

4) Also ‘chattr’ the file “/usr/local/cpanel/3rdparty/etc/phpmyadmin/php.ini” so that it doesn’t get reverted back to original whenever cPanel updates run.

Tags: , , , , ,
Posted in Dedicated Server Hosting, Linux VPS Hosting | 1 Comment »

Change Time Zone On Linux VPS

Written by Jahangir on October 28, 2008 – 3:45 am -

Is it possible to change system time in a VPS?

You cannot change system time in a VPS because all VPS’s on the hardware node have the same system time. However, it is possible to change the default system timezone inside a VPS, for example, by replacing /etc/localtime with the file from /usr/share/zoneinfo which contains a description of your timezone.

1. Login as a Root.

2. Issue the following command.

[root@support ~]# tzselect

tzselect will prompt you with a series of questions to determine the appropriate time zone file to use.
Check the last line after tzselect is completed, it should look like: “Region/City

3. Take the backup of the the current localtime file.

[root@support ~]# mv /etc/localtime  /etc/localtime_org

4. Now update the localtime.

[root@support ~]# ln -s /usr/share/zoneinfo/"Region/City" /etc/localtime

Replace “Region/City” with the information given by tzselect [without ""].

5. Verify the changes done by “date” command.

[root@support007 ~]# date

Restart your VPS to take proper effect of the changes.

Tags: , , ,
Posted in Dedicated Server Hosting | No Comments »

Cron & Crontab

Written by Jahangir on October 27, 2008 – 6:39 am -

Cron is a scheduling daemon process on Linux and other Unix variants, it enables unix users to execute commands or scripts (groups of commands) automatically at a specified time/date. Cron is very useful to run backup scripts.

Cron Files/Directory


Crontab Restrictions
Cron has a built in feature of allowing you to specify who may and who may not use it. It can done by using “/etc/cron.allow” and “/etc/cron.deny” files.
If the username exist in the file “/etc/cron.allow“, that user is authorize to execute cron. If “/etc/cron.allow” file does not exist, you can use crontab if username does not appear in the file “/etc/cron.deny“. If only “cron.deny” exists and its empty, than all users can use crontab. If neither file exists, than only the root user can use crontab. The “allow/deny” files consist of one user name per line.

Crontab Options and Explanation
A crontab file has five fields for specifying time, day and date followed by the command to be run at that interval. Below is Crontab syntax,

*  *  *  *  * command to be executed
-  -  -  -  -
| | | | |
| | | | +—– day of week
| | | +——– month
| | +———– day of month
| +————— hour
+—————— minute

Minute (0-59),
Hour (0-23),
Day of the month (1-31),
Month of the year (1-12),
Day of the week (0-6 with 0=Sunday).

* Is treated as a wild card. Meaning all possible value.
*/5 is treated as ever 5 minutes, hours, days, or months. Replacing the 5 with another numerical value will change this option.
2,8,12 “,” Treated as an “OR“, so if placed in the hours, this could mean at 2, 8 or 12 o-clock. Or if put in days it would be on 2,8 and12. “,” is used to define more options [date, time, day]
6-10 Treats for any value between 6 and 10. So, if placed in day of month this would be days 6 through 16. Or if put in hours it would be between 6 and 10. “-” is used to define the range [date, time]

Crontab Commands
crontab -e Edit your crontab file, or create one if it doesn’t already exist.
crontab -l Display your crontab entries.
crontab -r Remove your current crontab entry..
crontab -u username -e This option allows you to modify or view the crontab file of a user, only super user can use this option.

Tags: , , , , , ,
Posted in linux, Linux VPS Hosting | 1 Comment »

Social Networking Sites

Written by Pravin on October 24, 2008 – 6:54 am -

Social networking sites are building huge online communites of people  sharing interests & activities.  Social networking sites allows individuals to meet strangers which makes it unique.  After joining a social network site, users are prompted to identify others in the system with whom they have a relationship. The label for these relationships differs depending on the site—popular terms include “Friends,” “Contacts,” and “Fans.” Most SNSs also provide a mechanism for users to leave messages on their Friends’ profiles. This feature typically involves leaving “comments,” although sites employ various labels for this feature. In addition, SNSs often have a private messaging feature similar to webmail. While both private messages and comments are popular on most of the major SNSs, they are not universally available.

Social networking has created new ways to communicate and share information. Social networking websites are being used regularly by millions of people, and it now seems that social networking will be an enduring part of everyday life.

Tags: , , , , , , , , , , , , , , , , , , , , , , , , ,
Posted in Dedicated Server Hosting | 1 Comment »

ps Command

Written by Jahangir on October 23, 2008 – 7:04 am -

What is ps command?

The ps command [Process Status] is a tool to display the running processes and identifying the programs that are running on the [Unix/Linux] system and the resources they are using, including their process identification numbers (PIDs).
It’s same like you see your running process using “Task-Manager” on your windows system.
The ps command displays information about the current workstation.

Advantage of ps command is that system admins will be able to see where the memory/cpu is used. ps will show the percentage of memory/cpu resource that is used by each process or task running in the system, With this command its easy to identified top memory/cpu hogging processes on system.

Here are some basic syntax and example of ps.

* ps r :- Shows only running processes.

* ps f :- Generates a full listing.

* ps e :- Shows the command environment for each process. This is useful in a situation where a program works for one user but not for another or works on one machine but not on another.

* ps -t pts/1 :- Shows processes associated with the specified tty. This is a useful to find out the process running on remote machine and for how long.

* ps aux :- aux is the options for ps command to see every process on the system.

To see only the memory resources occupied by each category of processes, such as Apache httpd, MySQL mysqld or Java, use the following command:

ps aux | awk ‘{print $4″\t”$11}’ | sort | uniq -c | awk ‘{print $2″ “$1″ “$3}’ | sort -nr

Tags: , , , ,
Posted in Dedicated Server Hosting | 1 Comment »

Installing udev in VE based on Debian-4.0

Written by Pritam on October 20, 2008 – 7:02 am -

What is udev?

udev – /dev/ and hotplug management daemon

udev is a daemon which dynamically creates and removes device nodes from /dev/, handles hotplug events and loads drivers at boot time. It replaces the hotplug package and requires a kernel not older than 2.6.12.

Install udev in Debian

#apt-get install udev

NOTE :: After installing this you need to reboot your machine.

When you install the Udev package in VPS based on Debian-4.0 template, you can may the following message:

Setting up udev (0.105-4) …
/var/lib/dpkg/info/udev.postinst: line 125: echo: write error: Operation not permitted

The problem is postinstall script tries to write to /proc/sys/kernel/hotplug file, and this operation is prohibited in a VPS.

To work around this problem ::

just comment the 125th line in /var/lib/dpkg/info/udev.postinst file, that writes to the /proc/sys/kernel/hotplug file. After that udev can be installed smoothly.close Installing udev in VE based on Debian-4.0

Tags: , , , , , , , , , ,
Posted in Linux VPS Hosting, VPS hosting | No Comments »

  • Subscribe Me

  • Tag Cloud

  • Archives