Archive

Archive for November, 2012

How to Uninstall MySQL Governor

November 29th, 2012 No comments

How to Uninstall MySQL Governor

 

Run the below commands to uninstall MySQL Governor

 

/usr/share/lve/dbgovernor/install-mysql.py –delete
yum erase db-governor db-governor-mysql

 

Upgrading MySQL Governor on CPanel, Plesk and DirectAdmin server

November 29th, 2012 No comments

Upgrading MySQL Governor on CPanel, Plesk and DirectAdmin server

 

Run the below command to update MySQL Governor

yum update db-governor db-governor-mysql –enablerepo=cloudlinux-updates-testing

Run the below command to restart the service

service db_governor restart

 

MySQL Governor installation in without control panel server

November 29th, 2012 No comments

MySQL Governor installation in without control panel server

 

Run the below command to install MySQL Governor in plain server or without control panel server.

yum install db-governor –enablerepo=cloudlinux-updates-testing
yum update mysql-server mysql-devel mysql –enablerepo=cloudlinux-updates-testing

Add the below line in my.cnf with root password

 [dbgovernor]

 

Run the below command to start.

service db_governor restart

How to install MySQL Governor on CPanel, Plesk and DirectAdmin

November 29th, 2012 No comments

How to install MySQL Governor on CPanel, Plesk and DirectAdmin

MySQL governor is set of utilities to monitor and restrict MySQL usage in shared hosting environment. The monitoring is done via USER_STATISTICS table that is available in CloudLinux version of MySQL as well as via tracking of slow queries.

To install MySQL governor on cPanel server

yum install db-governor –enablerepo=cloudlinux-updates-testing
/usr/share/lve/dbgovernor/install-mysql.py –install

Note :

MySQL on cPanel servers will be updated from CloudLinux RPMs.

MySQL Governor is compatible only with MySQL 5.x

 

How to install CageFS in Cloud Linux

November 29th, 2012 No comments

How to install CageFS in Cloud Linux

 

CageFS is a virtualized file system and a set of tools to contain each user in its own ‘cage’. Each customer will have its own fully functional CageFS, with all the system files, tools, etc.
CageFS was previously known as SecureLVE. The benefits of CageFS are:
Only safe binaries are available to user
User will not see any other users, and would have no way to detect presence of other users & their usernames on the server
User will not be able to see server configuration files, such as apache config files.

Run the below command to install CageFS

yum install cagefs

If you are using cPanel or Plesk with Apache web server – CageFS will automatically detect your settings, and install necessary configuration files. CageFS plugin will be installed in WHM and Plesk admin interface correspondingly. You can manage initialization, updates and users via that plugin.

After that, initialize file system template

/usr/sbin/cagefsctl –init

That will create file system template in /usr/share/cagefs-skeleton directory based on config files in /etc/cagefs/conf.d. It will also create mount points file and set “Disable All” CageFS mode.

Now, check your WHM. You can see the cageFS plugin in WHM.

 

Note: /usr/share/cagefs-skeleton can use 5-7GB of disk space. If you don’t have enough space on that partition you can create a symbolic link to partition where you have enough disk space. For example:
mkdir /home/cagefs-skeleton
ln -s /home/cagefs-skeleton /usr/share/cagefs-skeleton

 

 

Categories: Cloud Linux Tags:

Cannot Login plesk after installation

November 12th, 2012 No comments

Cannot Login plesk after installation or reset plesk admin

password

 

Login to SSH.

Run the below command

/usr/local/psa/bin/init_conf –set-admin-password -passwd NEW_PASSWORD

 

Categories: Plesk Tags:

Exim causing load on server

November 12th, 2012 No comments

Exim causing load on server

 

Login to server via SSH.

Once login then login to mysql

[email protected] [~]# mysql
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1851
Server version: 5.1.65-cll MySQL Community Server (GPL)

Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.

mysql>

Now in mysql run use eximstats command it will look like

mysql> use eximstats;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed

Now, type show tables. it will look like

mysql> show tables;
+———————+
| Tables_in_eximstats |
+———————+
| defers |
| failures |
| sends |
| smtp |
+———————+
4 rows in set (0.00 sec)

Now, start deleting data from above tables. These tables having failure attempts etc.

mysql> delete from defers;
Query OK, 757 rows affected (0.02 sec)

mysql> delete from failures;
Query OK, 24901 rows affected (0.06 sec)

mysql> delete from sends;
Query OK, 47625 rows affected (0.06 sec)

mysql> delete from smtp;
Query OK, 59861 rows affected (0.10 sec)

Type ctrl+D to exit mysql

mysql> Bye

Now, restart mysql and exim.

[email protected][/var/lib/mysql/eximstats]# /etc/init.d/mysql restart
Shutting down MySQL………. SUCCESS!
Starting MySQL.. SUCCESS!
[email protected][/var/lib/mysql/eximstats]# /etc/init.d/exim restart
Shutting down clamd: [ OK ]
Shutting down exim: [ OK ]
Shutting down spamd: [ OK ]
Starting clamd: [ OK ]
Starting exim: [ OK ]
/usr/local/cpanel/scripts/update_sa_rules: running in background
[email protected][/var/lib/mysql/eximstats]#

 

Categories: CPanel / WHM, Uncategorized Tags:

Error: rpmdb open failed

November 12th, 2012 No comments

Error: rpmdb open failed

 

If you are running easyapache and getting the below error or while updating any package using yum and getting the error:

TypeError: rpmdb open failed
TypeError: rpmdb open failed

 

Solution:

Go to the below folder

cd /dev/

Rename unrandom file.

mv urandom urandom-bak

Recreate the file using below command

mknod -m 644 /dev/urandom c 1 9

Done.

Categories: CPanel / WHM Tags:

How to create account using SSH in cpanel

November 12th, 2012 No comments

How to create account using SSH in cpanel

 

Login to server via SSH.

Use cpanel create account script.

Syntax:

/scripts/createacct domainname.com username password

Example:

/scripts/createacct elinux.co.in elinuxco q1w2e3r4

It will prompt for ok? Press y

The above information is enough to create a temporary cpanel account. It will show the below output.

+===================================+
| New Account Info |
+===================================+
| Domain: elinux.co.in
| UserName: elinuxco
| PassWord: q1w2e3r4
+===================================+

This ok? y
Checking input data……Done
WWWAcct 12.5.0 (c) 2012 cPanel, Inc…….Done
Running pre creation script (/usr/local/cpanel/scripts/prewwwacct)……Done
Adding User…Creating mailbox file: File exists
…Done
Adding Entries to httpd.conf……Done
Setting up Mail & Local Domains……Done
Configuring DNS……Done
Restarting apache……Done
Updating Authentication Databases……Done
Verifying MX Records and Setting up Databases……Done
Setting up Proxy Subdomains……Done
Sending Account Information……Done
Running post creation scripts (/usr/local/cpanel/scripts/legacypostwwwacct, /usr/local/cpanel/scripts/postwwwacct, /usr/local/cpanel/scripts/postwwwacctuser)……Done
Setting up Domain Pointers……Done
Setting Reseller Privs……Done
Account Creation Complete!!!……Done
Account Creation Ok
System has 2 free ips.
Dns Zone check is enabled.
+===================================+
| New Account Info |
+===================================+
| Domain: elinux.co.in
| Ip: your server ip (n)
| HasCgi: y
| UserName: elinuxco
| PassWord: q1w2e3r4
| CpanelMod: x3
| HomeRoot: /home
| Quota: 0 Meg
| NameServer1: ns1.com
| NameServer2: ns2.com
| NameServer3:
| NameServer4:
| Contact Email:
| Package: default
| Feature List: default
| Language: en
+===================================+
Adding Shell Access (y)
Successlocaldomains…valiases …vdomainaliases…vfilters…Bind reconfiguring on testserver using rndc
Zone elinux.co.in has been successfully added
Password for elinuxco has been changed
Updating ftp passwords for elinuxco
Ftp password files updated.
Ftp vhost passwords synced
Reconfiguring Mail Routing:
LOCAL MAIL EXCHANGER: This server will serve as a primary mail exchanger for elinux.co.in’s mail.:
This configuration has been manually selected.

Bind reloading on testserver using rndc zone: [elinux.co.in]
System has 2 free ips.
wwwacct creation finished
Account Creation Ok

Categories: CPanel / WHM, Uncategorized Tags:

How to install ffmpeg-php in linux

November 12th, 2012 No comments

How to install ffmpeg-php in linux

 

Login to server via SSH.

Go to the below path.

cd /usr/local/src

Download the tar file.

wget “http://downloads.sourceforge.net/project/ffmpeg-php/ffmpeg-php/0.6.0/ffmpeg-php-0.6.0.tbz2?use_mirror=garr”

Extract the tar file.

tar xjvf ffmpeg-php-0.6.0.tbz2

Go inside that folder

cd ffmpeg-php-0.6.0

run the below commands

phpize

./configure

make

make install

 

Categories: CPanel / WHM, PHP Tags: