vi /etc/my.cnf
[mysqld]
log-error=/var/log/mysqld.log
NSN
Bài đăng phổ biến
-
yum install install libxml2-devel Nguyen Si Nhan
-
How to create a bot to automate daily tasks using Slack Nguyen Si Nhan 1. Setting Up Your Slack App Create a Slack App: Sign in to your Sla...
Tuesday, February 7, 2012
Thursday, February 2, 2012
Cpanel : Backup and restore multi website by script
Backup:
Create a file with name backup.sh
Nguyễn Sĩ Nhàn
Create a file with name backup.sh
for i in $(ls /var/cpanel/users)
do /scripts/pkgacct $i
done
Restore:
Create a file with name restore.sh:
for x in $(ls cpmove-*.tar.gz | cut -d "." -f 1); do /scripts/restorepkg $x; done
or
#!/bin/bash
for i in $(cat /backup/restore.txt)
do /scripts/restorepkg $i
done
With restore.txt is list username and file backup is in /home dir
or
#!/bin/bash
for x in $(ls /home/backup-*.tar.gz | cut -d "_" -f 3 | cut -d "." -f 1);
do /scripts/restorepkg $x;
done
echo "Written by Nguyen Si Nhan"
or
#!/bin/bash
for i in $(cat /backup/restore.txt)
do /scripts/restorepkg $i
done
With restore.txt is list username and file backup is in /home dir
or
#!/bin/bash
for x in $(ls /home/backup-*.tar.gz | cut -d "_" -f 3 | cut -d "." -f 1);
do /scripts/restorepkg $x;
done
echo "Written by Nguyen Si Nhan"
Nguyễn Sĩ Nhàn
Tuesday, January 31, 2012
Unknown SQL engine
Problem:After installing the FreePBX,admin page show the following message:
FATAL ERROR
Unknown SQL engine: []
Trace Back
/var/www/html/admin/common/db_connect.php:57 die_freepbx()
[0]: Unknown SQL engine: []
/var/www/html/admin/bootstrap.php:75 require_once()
[0]: /var/www/html/admin/common/db_connect.php
/var/www/html/admin/config.php:61 require()
[0]: /var/www/html/admin/bootstrap.php
Solution:================================================================vim +231 /etc/httpd/conf/httpd.conf
change User apache and Group apache to User asterisk and Group asterisk.vim +327 /etc/httpd/conf/httpd.conf
change None to All.
or use sed to replace.sed -i '231,232s/apache/asterisk/i;327s/none/All/i' /etc/httpd/conf/httpd.conf
Restart apache service.service httpd restart
Subscribe to:
Posts (Atom)