Ejabberd installation configuration

8,833 views
8,452 views

Published on

Ejabberd installation configuration

Published in: Technology
0 Comments
11 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
8,833
On SlideShare
0
From Embeds
0
Number of Embeds
16
Actions
Shares
0
Downloads
0
Comments
0
Likes
11
Embeds 0
No embeds

No notes for slide

Ejabberd installation configuration

  1. 1. Ejabberd Installation &Configuration ShaojieYang 12/2012
  2. 2. Instant Messaging• “Instant Messaging(IM) is a form of communication over the Internet that offers quick transmission of text-based messages from sender to receiver.• “In push mode between two or more people using personal computers basically offers real- time written language-based online chat.
  3. 3. Instant Messaging• “The user’s text is conveyed over a network, such as the Internet. It may address point-to-point communications as well as multicast communications from one sender to many receivers.• “More advanced instant messaging allows enhanced modes of communication, such as live voice or video calling, video chat and inclusion of hyperlinks to media.” – Definition from Wikipedia
  4. 4. About Ejabberd• “ejabberd is a Jabber/XMPP instant messaging server, licensed under GPLv2(Free and Open Source), written in Erlang/OTP. Among other features, ejabberd is cross-platform, fault- tolerant, clusterable and modular.” – Definition from Ejabberd Community Site(http://www.ejabberd.im)
  5. 5. Part AINSTALLATION (LINUX PLATFORM)
  6. 6. Download• Download ejabberd installation package:• http://www.process-one.net/en/ejabberd/downloads/
  7. 7. Download• Download the package into Linux machine.
  8. 8. Unzip & Grant Permissions
  9. 9. Start Installation• ./ejabberd-2.1.10-linux-x86- installer.bin• Installation language:[2]
  10. 10. Start Installation• Ejabberd server domain: ejabberdtest.com• Administrator user name: admin• Cluster: N• Want to continue? Y
  11. 11. After Installation• Installation Path: /opt/ejabberd-2.1.10
  12. 12. Start Ejabberd Daemon
  13. 13. Check Configuration File• Location: /opt/ejabberd-2.1.10/conf/ejabberd.cfg• Web administration port: 5280
  14. 14. Change Iptables• Location: /etc/sysconfig/iptables
  15. 15. Change Iptables• Insert the following line:• -A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 5280 -j ACCEPT• Before:• -A RH-Firewall-1-INPUT -j REJECT --reject-with icmp-host-prohibited
  16. 16. Change Iptables
  17. 17. Restart Iptables
  18. 18. Open Web Administration Page• URL:• http://ejabberdtest.com:5280/admin
  19. 19. Open Web Administration Page
  20. 20. Add Users
  21. 21. Add Users
  22. 22. Login with IM Software
  23. 23. Start Chatting
  24. 24. Start Chatting
  25. 25. Part BCONFIGURATION –CONNECT TO EXTERNAL DATABASE
  26. 26. Connect to an External Database• Ejabberd has its default database, located at:• /opt/ejabberd-2.1.10/database/ejabberd@localhost• How to connect to an external database?
  27. 27. Create Ejabberd Database(MySql)
  28. 28. Create Ejabberd Database
  29. 29. Import Mysql.sql to Ejabberd• Path:• /opt/ejabberd-2.1.10/lib/ejabberd-2.1.10/priv/odbc/mysql.sql
  30. 30. Import Mysql.sql to Ejabberd
  31. 31. Modify ejabberd.cfg File• Comment {auth_method, internal}
  32. 32. Modify ejabberd.cfg File• Open {auth_method, odbc}
  33. 33. Modify ejabberd.cfg File• Modify MYSQL Server Section:
  34. 34. Modify ejabberd.cfg File• Add _odbc to the following modules:• mod_last  mod_last_odbc• mod_offline  mod_offline_odbc• mod_privacy  mod_privacy_odbc• mod_private  mod_private_odbc• mod_pubsub  mod_pubsub_odbc• mod_roster  mod_roster_odbc• mod_vcard  mod_vcard_odbc
  35. 35. Register Admin Account
  36. 36. Register Admin Account
  37. 37. Add User to New Database
  38. 38. Part CCONFIGURATION –USE TLS CONNECTION
  39. 39. Introduction• Normally, if we use the default configuration, when we login to our accounts, there’s no encryption actived.• But in case of safety, we usually need to change settings to use TLS connection method.
  40. 40. Modify ejabberd.cfg File• Add “starttls_required,” into the “5222” listening ports section. Then restart service.
  41. 41. Change Settings in Client End
  42. 42. Try to Login
  43. 43. Check the Log File
  44. 44. Solution• linux-gate.so.1 => (0x00f9c000)• libssl.so.0.9.8 => not found• libcrypto.so.0.9.8 => not found• libc.so.6 => /lib/libc.so.6 (0x00d9c000) /lib/ld-linux.so.2 (0x00943000)
  45. 45. Solution
  46. 46. Solution
  47. 47. Solution• Open the port 5222 in iptables, then restart iptables service
  48. 48. Restart Service and Login Again

×