Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am running glassfish v2.1.1 on linux. I have some datasources set up to connect to mysql and other databases. There are times where I would like to run glassfish without connecting to these databases, as some of them are only available to me at work. If I try to do so, glassfish will hang and will never start up at all. Is there a good way to get glassfish to give up connecting to the datasources and continue loading anyway? BTW, when glassfish hangs this way, I have created further problems by trying to start it again when the last start was unsuccessful.

share|improve this question

migrated from stackoverflow.com Jun 29 '11 at 19:20

This question came from our site for professional and enthusiast programmers.

add comment

1 Answer

up vote 0 down vote accepted

There are a couple of ways I can think of to do this. One is to switch to cluster profile (assuming you're on the developer profile), then create a standalone instance that does not have the datasources associated with it. Datasources have a Target tab in the admin page and you can pick which server instances each datasource is associated with. You'll need to run asadmin start-node-agent from the command line to start the second instance. This second instance can have different ports (typically 38081, 38181, 33700, etc.)

I haven't done it, but another way is to create a second domain configured the way you need. It would also use different ports. Something like this: http://lysra.blogspot.com/2008/09/initialize-second-domain-in-glassfish.html

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.