To install ejabberd with patch file(Serve cross domain policy file for Flash).
- Install erlang on your system.
- Download ejabberd
wget http://www.process-one.net/downloads/ejabberd/2.1.11/ejabberd-2.1.11.tgz
- tar zxf ejabberd-2.1.11.tar.gz
4 cd ejabberd-2.1.11
- Download patch files for ejabberd
https://support.process-one.net/browse/EJAB-960
https://support.process-one.net/secure/attachment/15839/flash-policy-file-ejabberd-2.1.x.diff
- Install the patch file
patch -p1 < flash-policy-file-ejabberd-2.1.x.diff
- cd ejabberd-2.1.6/src/
- ./configure --enable-odbc
- Run
make
- Run
make install
Add ejabberd mysql module
1. cd ejabberd-2.1.6/src/
2. svn co https://svn.process-one.net/ejabberd-modules
3. cd ejabberd-modules/mysql/trunk/
4. ./build.sh
5. cp ebin/*.beam /lib/ejabberd/ebin/
Import database
1. mysql -uusername -ppassword
2. Create database and import mysql file
3. Grant all privileges on database.* to 'user'@'localhost' identified by 'password' ;
Configure ejabberd-mysql
1.vi etc/ejabberd/ejabberd.cfg [conf file]
2.Comment the line in the file {auth_method, internal}
3.Uncomment the line in the file {auth_method, odbc}
{odbc_server, {mysql, "server", "DatabaseName", "Username", "password"}}.
Change mod_last[under modules] to mod_last_odbc to store the last seen date in MySQL.
Update conf file
vi etc/ejabberd/ejabberd.cfg [conf file]
{hosts, ["test-media-isprime.com"]}.
Start ejabberd server.
ejabberdctl start/live
ejabberdctl stop
Your ejabberd is free to run.
Cheers :)
0 Comment(s)