Pages

Showing posts with label plesk. Show all posts
Showing posts with label plesk. Show all posts

Friday, April 12, 2013

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

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

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

Reinstall Horde on Plesk, because of misbehaving (like authentication issue, broken images)

Please take a backup of the Horde database first to avoid any sort of data loss.

/usr/local/psa/admin/bin/webmailmng --remove --name=horde
rpm -e --nodeps psa-horde psa-imp psa-ingo psa-kronolith psa-mimp psa-mnemo psa-turba
mv /usr/share/psa-horde{,.$(date +%s)}
/usr/local/psa/admin/bin/autoinstaller --select-release-current --select-product-id plesk --install-component horde --reinstall-patch
/usr/local/psa/admin/bin/webmailmng --install --name=horde
/usr/local/psa/admin/bin/webmailmng --enable --name=horde
/usr/local/psa/admin/bin/httpdmng --reconfigure-all

IMAP authentication / SASL errors (warning: localhost.localdomain[127.0.0.1]: SASL LOGIN authentication failed: authentication failure)

Plesk 11.x have fix for this but you can fix this error on 10.x also as below :)

mv /usr/lib64/sasl2/smtpd.conf /usr/lib64/sasl2/smtpd.conf.$(date +%s)
cat <<'SASL_CONF_EOF'>/usr/lib64/sasl2/smtpd.conf
pwcheck_method: auxprop saslauthd
auxprop_plugin: sql_sqlite3
saslauthd_path: /var/spool/postfix/private/plesk_saslauthd
mech_list: DIGEST-MD5 CRAM-MD5 PLAIN LOGIN
auto_transition: yes
sql_engine: sqlite3
sql_hostnames: localhost
sql_database: /var/spool/postfix/plesk/passwd.db
sql_select: SELECT `%p` FROM domains d, users u WHERE u.name='%u' and d.name='%r' and d.status=0 and u.status=0 and u.dom_id=d.id
sql_verbose: yes
log_level: 9
SASL_CONF_EOF
service saslauthd restart
service postfix restart

cannot chdir to domain dir domain.com: Permission denied (Plesk postfix)

My nice finding with my previous company MyHosting .com

This error appears when the permissions on the user mail directories are incorrect, which usually shows up after a transfer. You can check the permissions under /var/qmail (even if the mail server is postfix), and his is what correct permissions look like:

# ll /var/qmail
total 8
drwxr-xr-x 7 root    root    4096 Jun 15 18:15 mailnames
drwxr-xr-x 3 popuser popuser 4096 Jun  2 02:48 popuser

# ll /var/qmail/mailnames/
total 16
drwxr-x--- 6 popuser popuser 4096 Jun  2 18:33 plesknew.prepgator.com
drwxr-x--- 2 popuser popuser 4096 Jun 15 18:09 test1.plesknew.prepgator.com
drwxr-x--- 2 popuser popuser 4096 Jun 15 18:09 test2.plesknew.prepgator.com

To fix it, you only need to fix the permissions:

How do i password protect subdomain directories in plesk

You can protect the subdomain directories in plesk using .htaccess and .htpasswd files. Follow the stpes below :

>> SSH to the server with root user
>> Go to the folder which you want to be password protected :

[root@server ~]# cd /www/vhosts/yourdomai.com/subdomains/directory/httpdocs/
NOTE : “Yourdomain.com” will be replaced with your domain main domain and “Directory” replaced with the folder that you want to protect.

>> Now create .htaccess file :

[root@server ~]# vi .htaccess
Enter the below code in .htaccess file :