I recently upgraded to Glassfish V3.1 Final from the beta releases and noticed that the Felix shell was no longer activated by default. It wasn’t completely obvious as to how to enable it. Turns out there has been some discussion around security and the need for it to be enabled by default (see GLASSFISH-13006 for more info).
To fix this, modify your domain config file ($GLASSFISH_HOME/glassfish/domains/domain1/config/domain.xml) and update the entry as per below:
<jvm-options> -Dorg.glassfish.additionalOSGiBundlesToStart=org.apache.felix.shell, org.apache.felix.gogo.runtime,org.apache.felix.gogo.shell, org.apache.felix.gogo.command, org.apache.felix.shell.remote </jvm-options>
And for those who would prefer the vanilla felix shell sans-gogo, just remove the gogo jar entries:
<jvm-options> -Dorg.glassfish.additionalOSGiBundlesToStart=org.apache.felix.shell, org.apache.felix.shell.remote </jvm-options>
Start the application server and telnet to localhost:
telnet localhost 6666
… and we’re done!