• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Tim Cooke
  • Devaka Cooray
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
Bartenders:
  • Carey Brown
  • Roland Mueller

Can you run multiple deployments of JForum?

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm interested in running one instance of Tomcat and MySQL with multiple instances of JForum each with their own database schema.

I have two instances of JForum deployed on a single instance of Tomcat. Both instances are running but when I modify the first instance the second instance sees the changes from the first.

Each instance has a different database name in the WEB-INF\config\database\mysql\mysql.properties.

Any ideas as to what I'm doing wrong?

Thanks,
Wes
[originally posted on jforum.net by wes]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You should have different context names and one JForum isntallation per context. You can't share a JForum installation.

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
yes. I have created multiple context names.

In my Tomcat webapps directory I have a jforum1 installation and a sperate jforum2 installation. I also created seperate databases for each called jforum1 and jforum2.

When I start tomcat I get what seems to be two separate instances of JForum until I start editing (adding Catagories, Topics, etc.).
[originally posted on jforum.net by wes]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Something isn't quite right in your configuration. I run 5 instances of JForum on a single Tomcat with no problem. However, I am doing it a bit different than you. Each JForum instance is in a separate Host in Tomcat. Within that Host I have a Context specifically for JForum.

If you can't use virtual hosting can you post a little bit of the server.xml section that you're using? Specifically, just the Context sections.
[originally posted on jforum.net by stdunbar]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If by context you mean separate directories within Tomcat's webapps directory or do you mean something different? Like special context entries within Tomcat's server.xml? I am using as standard default server.xml file. I have not tailored it in any way.

Thanks for your help!
[originally posted on jforum.net by wes]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok, well that makes it much simpler.

I think that, as Rafael said, you will want to make sure that your configuration is totally separate. It sounds as if both databases are logging into the same place. You've created different databases - I would also encourage different database users too. That way as long as you have two different WEB-INF/config/jforum-custom.conf files you are sure that the two instances can't overlap.

Lastly, I would encourage you to change the cookie names to two different things also. Because your hostname will be the same for both forums you may have some issues. This is set in the jforum-custom.conf file under cookie.name.data, cookie.name.user, cookie.name.autologin, and cookie.name.userHash. They default to things like jforumUserId for the cookie.name.data (see WEB-INF/config/SystemGlobals.properties for all of them). You might want to just append something like "forum1" and "forum2" to the cookie name.
[originally posted on jforum.net by stdunbar]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks stdunbar!! That fixed it!

I'm not sure how it happened but the WEB-INF/config/jforum-custom.conf file had the same database.connection.dbname=jforum1 in both files. I fixed that and everything is looking good so far!!
[originally posted on jforum.net by wes]
 
If you are using a rototiller, you are doing it wrong. Even on this tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic