Directadmin – Enable / Installing XsltProcessor

OS CentOS

 yum install libxml2-devel libxslt-devel libgcrypt-devel

OS Debian

 aptitude install libxslt1.1 libxslt1-dev libgcrypt11-dev libxml2 libxml2-dev

Edit config for Custombuild DirectAdmin

cd /usr/local/directadmin/custombuild
vi configure/ap2/configure.php5

Add below

--with-dom=/usr/lib \
--with-dom-exslt=/usr/lib \ 
--with-dom-xslt=/usr/lib  \
--with-xsl

or

--with-dom=/usr/local/lib
--with-dom-exslt=/usr/local/lib
--with-dom-xslt=/usr/local/lib
--with-xsl

Save and Compile Custombuild

./build clean
./build php n

Restart Apache service CentOS/Debian /etc/init.d/httpd restart

end.

Ubuntu Malaysia Mirror

For those using IP address that only accessible in Malaysia, or finding a Malaysia Mirror, here it is, I using long time to search it –

Mirror 1 – MMU Malaysia

Go to /etc/apt/sources.list.d  directory
create file call mmu.list
edit and addin following line -
deb http://archive.mmu.edu.my/ubuntu/ lucid  main
deb-src http://archive.mmu.edu.my/ubuntu/ lucid  main

deb http://archive.mmu.edu.my/ubuntu/ lucid-updates main
deb-src http://archive.mmu.edu.my/ubuntu/ lucid-updates  main

deb http://archive.mmu.edu.my/ubuntu/ lucid-updates  universe
deb-src http://archive.mmu.edu.my/ubuntu/ lucid-updates universe

Mirror 2 – OSCC Malaysia

Go to /etc/apt/sources.list.d  directory
create file call oscc.list
edit and addin following line -
deb http://mirror.oscc.org.my/ubuntu/ lucid main
deb-src http://mirror.oscc.org.my/ubuntu/ lucid main

deb http://mirror.oscc.org.my/ubuntu/ lucid-updates main
deb-src http://mirror.oscc.org.my/ubuntu/ lucid-updates main

deb http://mirror.oscc.org.my/ubuntu/ lucid-updates universe
deb-src http://mirror.oscc.org.my/ubuntu/ lucid-updates universe

Mirror 3 – UPM Malaysia

Go to /etc/apt/sources.list.d  directory
create file call upm.list
edit and addin following line -
deb http://biruni.upm.my/mirror/ubuntu/ lucid main
deb-src http://biruni.upm.my/mirror/ubuntu/ lucid main

deb http://biruni.upm.my/mirror/ubuntu/ lucid-updates main
deb-src http://biruni.upm.my/mirror/ubuntu/ lucid-updates main

deb http://biruni.upm.my/mirror/ubuntu/ lucid-updates universe
deb-src http://biruni.upm.my/mirror/ubuntu/ lucid-updates universe

FreePBX Showing DB Error

Following is the error screen –

If you all the while no problem on FreePBX recording, and out of sudden not able to retrieve the  recording and shows “DB Error: Unknow error” , this mostly due to DB table corruptions, this can be fix using following –

mysql -h localhost -u asteriskuser -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 7
Server version: 5.0.77 Source distribution

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

mysql>  USE asteriskcdrdb
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
mysql> optimize table cdr;

Done. You try again and it should work.

SSH Key Authentication

Server B need to access Server A  using SSH Public Key authentication (Does not need to have password login)

At Server B
To use public keys with an ssh server, you’ll first need to generate a public/private key pair at Server A:

$ ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/home/root/.ssh/id_rsa):
Enter passphrase (empty for no passphrase): 
Enter same passphrase again: 
Your identification has been saved in /home/root/.ssh/id_rsa.
Your public key has been saved in /home/root/.ssh/id_rsa.pub.
The key fingerprint is:
a1:3c:a4:eb:18:95:1b:16:b1:a3:28:18:ga:81:3a:ba root@localhost

At Server B
To install the generated cert/key from Server B to Server A (or any server that ServerB need to access) with IP address 192.168.0.20 :

$ ssh 192.168.0.20 "mkdir .ssh; chmod 0700 .ssh"
$ scp .ssh/id_rsa.pub 192.168.0.20:.ssh/authorized_keys2

By now, ServerB will be able to access ServerA without need to key in login password.

Alternative way of install cert from ServerB to ServerA

ssh-copy-id -i .ssh/id_rsa.pub root@serverA