mysqldump -d dbname table > table.sql
Category Archives: Hosting
roundcube error log location
/var/cpanel/roundcube/errors /var/cpanel/roundcube/sendmail
cpanel use 80 port access webmail and cpanel
/scripts/proxydomains –user=
/scripts/proxydomains –domain=
[ERROR] Fatal error: Can’t open and lock privilege tables: Table ‘mysql.host’ doesn’t exist
If you have this error after mysql restore jobs.
Fix.
mysql_install_db –-user=mysql –ldata=/var/lib/mysql
service mysql start
mysql dump all users and privileges
Dumping:
mysql --skip-column-names -A -e"SELECT CONCAT('SHOW GRANTS FOR ''',user,'''@''',host,''';') FROM mysql.user WHERE user<>''" | mysql --skip-column-names -A | sed 's/$/;/g' > mysql_user_grants.sql
Importing:
mysql mysql < mysql_user_grants.sql
mysql -e "flush privileges" -D mysql
Starting httpd: httpd: Syntax error on line 50 of /etc/httpd/conf/httpd.conf
If you can’t start directadmin on your Centos server:
Starting httpd: httpd: Syntax error on line 50 of /etc/httpd/conf/httpd.conf: Syntax error on line 1 of /etc/httpd/conf/extra/httpd-phpmodules.conf
Fix:
cd /usr/local/directadmin/custombuild/
./build apache
./build mod_ruid2
./build php n
./build rewrite_confs
/etc/init.d/httpd restart
ispconfig restore admin password
cat /usr/local/ispconfig/server/lib/mysql_clientdb.conf
mysql -h localhost -p
UPDATE sys_user SET passwort = md5('YourNewPassword') WHERE username = 'admin';
FLUSH PRIVILEGES;
quit;
ispconfig mysql root password
You can find it there:
cat /usr/local/ispconfig/server/lib/mysql_clientdb.conf
cPanel – IP address has changed
Fix.
In WHM’s Tweak Settings, change the setting “Cookie IP validation” from Strict to Loose.
Preference file, /var/www/html/squirrelmail/data/[email protected], could not be opened. Contact your system administrator to resolve this issue.
Fast fix.
chown -R webapps:webapps /var/www/html
extract single mysql database
mysql -D db_name-o < add_mysql_dump.sql
Cloudlinux – Library files “too short”
If you have this error for some users: php error while loading shared libraries: libpcre.so.0: cannot open shared object file: No such file or directory
Fix.
yum check
yum reinstall alt-pcre
cPanel – Account does not exist
If you are trying to change mailbox password and you get “Account does not exist”. It means your account can be over quota, please try temporally increase account size. Also sometime helps this fix:
cd ~username/.cpanel
mv -v email_accounts.yaml email_accounts.yaml.backup
cPanel install memcahe Centos 7
yum install memcached
service memcached start or maybe: systemctl start memcached.service
pecl install memcache
systemctl restart httpd.service
If you want install from source:
wget http://pecl.php.net/get/memcache
cd memcache*
phpize
./configure
make && make install
echo “extension=memcache.so” >> /your_path/php.ini
log all mysql queries
If you want log all your MySQL queries:
vi /etc/my.cnf
log = log_file_name