Don't miss the latest updates, ever
Buy VPN

[How-To] Setup Your Own Chat Server Using OpenFire

Monday, 7 September 2009, 19:57 | How-To, Tools | 13 Comments | Read 3804 Times
by Vaibhav Pandey

A few days back, i was working with a friend of mine who owns a startup and helped him with setting up an internal chat server for his internal team and employees and this article gets its motivation from there.

In order to get your own chat server running, you would need a software called OpenFire. The article will install and setup a chat server running over Windows. We will then also use a Jabber client to connect to the OpenFire chat server.

Openfire (previously known as Wildfire Server) is a Jabber/XMPP server written in Java and dual-licensed under both a proprietary license and the GNU General Public License.

In order to get started with OpenFire, first you need to download the OpenFire chat server software from here. Once downloaded,  run the Openfire installer. The application will be installed to C:\Program Files\Openfire by default.

Once the application installs, you can navigate to the standard admin console by typing in http://127.0.0.1:9090 (9090 is the default admin port).

Once you have the OpenFire setup installed and configured, you can use any Jabber client to connect to the OpenFire chat server.

Follow the steps below to setup OpenFire Chat Server ( assuming you have already downloaded and extracted the contents of the zip file)

1.) Launch OpenFire by navigating to the bin folder and double clicking on Openfire.exe .

2.) Configure OpenFire by providing valid values for Domain ( this will be used by the clients to connect to the server).

Choose-databse-when-setting-up-openfire

3.) You can setup your own external database or use an internal database. If you are setting up the chat server for a group of more than 10 people, i would recommend that you setup your external database. You can read about how to setup an external database here.

4.) You will also be required to choose a user and group system to use with the server. You can opt to create users and assign them passwords, integrate Openfire with LDAP or integrate with a clearspace integration. If you are setting it up for a small firm, my guess is you would be using the default option.

5.) Create an admin account user id and password. You will be required to login using the admin user id next time.

OpenFire-Setup-your-own-chat-server

The above steps help you setup and configure OpenFire. Next, you need to login to the admin console and create users for chat. Click on the menu tab Users/Groups and create new users.

Create-new-chat-user-using-openfire

Users can then use the account credentials to connect to the OpenFire server using any Jabber client. For this tutorial, i will use Spark. You can download the relevant version of Spark from here. (Look for product name “Spark”)

1.) Enter the username and password ( as created using the steps mentioned above).

2.) Enter the server hostname or IP address of the server. ( in my case, 127.0.0.1)

Spark-Jabber-Client-For-OpenFire

If you have provided correct details, and if OpenFire server is running, you should have logged in now. You can see all those users who are logged in by clicking on the menu tab called Sessions.

session-usage-in-openfire

OpenFire also provides very useful features through Plugins. You can consider installing Monitoring Service Plugin which Monitors conversations and statistics of the server. Another interesting plugin is Packet Filter which ensures that certain words are not used in the chat conversation. I also like IM Gateway which Provides gateway connectivity to the other public instant messaging networks.

plugins-with-openfire

You can access and search for available Plugins by navigating to the menu tab called Plugins and then clicking on the Available Plugins link.

Hope the above helps. If you are stuck with any doubts or questions, do leave them in comments and i will try to help.

You can also follow me on Twitter at http://twitter.com/vaibhav1981

Do stay tuned to Technofriends for more, one of the best ways of doing so is by subscribing to our feeds. You can subscribe to Technofriends feed by clicking here.



Follow me on Twitter at @vaibhav1981
Tagged with: , , , , , , , , ,
  • Pingback: Openfire : real time collaboration (RTC) chat server « Mahesh Prasad ( Web Development ) [LAMP/AJAX/SEO/SQL/XML]

  • Pingback: How To Setup your own Chat Server using OpenFire « Welcome to site of Harshal Malshe!

  • alberto

    Hi! thanks for the tutorial!!
    but one question, which port should I open to make accesible outside my local network? i mean, which ports should I open on the router? I’m already open de 5222 port

    Thanks in advacne and best regards

  • mike

    Check your firewall/router logs for deny’s, that should tell you right off the bat.

  • rehman

    Hi, i am not able to login administration console which i created mail id and password. plz help

  • http://www.technofriends.in Vaibhav

    What’s the error you get?

  • william

    what if i want to log in from outside the network??wat do i do?

  • http://www.liquidprinter.com John Reeves

    Thanks for info….

  • Shankar

    I am on a LAN, i am using default settings, i get the error “Can’t connect to server: Invalid name or server not reachable” :(

    I am able to ping the server, i can login to the Admin console via browser. I am using Spark client.

    Any help on this is welcome.

  • Shradscoolcapri

    java.lang.NoClassDefFoundError: Could not initialize class org.jivesoftware.admin.LoginLimitManager$LoginLimitManagerContainer
    at org.jivesoftware.admin.LoginLimitManager.getInstance(LoginLimitManager.java:48)
    at org.jivesoftware.openfire.admin.login_jsp._jspService(login_jsp.java:143)
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:530)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1216)
    at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:39)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1187)
    at org.jivesoftware.util.LocaleFilter.doFilter(LocaleFilter.java:74)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1187)
    at org.jivesoftware.util.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:50)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1187)
    at org.jivesoftware.admin.PluginFilter.doFilter(PluginFilter.java:78)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1187)
    at org.jivesoftware.admin.AuthCheckFilter.doFilter(AuthCheckFilter.java:164)
    at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1187)
    at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:425)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:119)
    at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:494)
    at org.eclipse.jetty.server.session.SessionHandler.handle(SessionHandler.java:182)
    at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:933)
    at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:362)
    at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:867)
    at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117)
    at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:245)
    at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:126)
    at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:113)
    at org.eclipse.jetty.server.Server.handle(Server.java:334)
    at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:559)
    at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1007)
    at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:747)
    at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:209)
    at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:406)
    at org.eclipse.jetty.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:462)
    at org.eclipse.jetty.util.thread.QueuedThreadPool$2.run(QueuedThreadPool.java:436)
    at java.lang.Thread.run(Unknown Source)

  • Raj

    how to use server adress

  • thees_k

    your domain name should not contain “_” character

  • thees_k

    your domain name should not contain “_” character