History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: PENROSE-138
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Blocker Blocker
Assignee: Jim Yang
Reporter: Sébastien RENON
Votes: 0
Watchers: 1
Operations

Clone this issue
Create sub-task
If you were logged in you would be able to see more operations.
Penrose

Cannot connect to a remote penrose server

Created: 13/Mar/06 03:42 PM   Updated: 27/Dec/08 03:01 AM
Component/s: Studio
Affects Version/s: Penrose-0.9.9
Fix Version/s: Penrose-1.0

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
Environment: Win Xp, JDK sun 1.4.2


 Description  « Hide
i'am using penrose-server 0.9.9.2, and penrose-studio 0.9.9

penrose-server is installed on a linux FC4 server.
penrose-server is installed on a Xp Client Machine.

I have configured the Penrose server with the example data included and installed the schemas and everything. I am able to successfully start the Penrose server without any errors showing up in debug logging mode (created log4j config file). I am also able to successfully browse the LDAP tree from remote with a java-based ldap browser. This also generates no errors in any logs.

However when I try to connect to the server using penrose studio, it doesn't work at all. Here is the output of the local logfile for Penrose Studio:

PenrosePlugin [ ?] Starting PenrosePlugin
PenroseApplication [ ?] Initializing PenroseApplication ... init()
PenroseApplication [ ?] Running Penrose Studio ... run()
PenroseWorkbenchWindowAdvisor [ ?] preWindowOpen
PenroseApplication [ ?] Loading projects from C:\Documents and Settings\mbditt\.penrose\config.xml
ApplicationConfig [ ?] Loading project configurations file from: C:\Documents and Settings\mbditt\.penrose\config.xml
PenroseClient [ 63] Connecting to 10.0.0.30:1099 as admin with password secret
PenroseClient [ 63] Connecting to 10.0.0.30:1099 as admin with password secret
ProjectEditorDialog$1 [ ?] Connection refused to host: 127.0.0.1; nested exception is:
java.net.ConnectException: Connection refused: connect
java.rmi.ConnectException: Connection refused to host: 127.0.0.1; nested exception is:
java.net.ConnectException: Connection refused: connect
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:574)
at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:185)
at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:171)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:94)
at javax.management.remote.rmi.RMIServerImpl_Stub.newClient(Unknown Source)
at javax.management.remote.rmi.RMIConnector.getConnection(RMIConnector.java:2229)
at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:271)
at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:248)
at org.safehaus.penrose.management.PenroseClient.connect(PenroseClient.java:74)
at org.safehaus.penrose.studio.project.ProjectEditorDialog$1.widgetSelected(Unknown Source)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:90)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:843)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3080)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2713)
at org.safehaus.penrose.studio.project.ProjectEditorDialog.open(Unknown Source)
at org.safehaus.penrose.studio.project.ProjectDialog.editProject(Unknown Source)
at org.safehaus.penrose.studio.project.ProjectDialog$10.widgetSelected(Unknown Source)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:90)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:843)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3080)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2713)
at org.safehaus.penrose.studio.project.ProjectDialog.open(Unknown Source)
at org.safehaus.penrose.studio.PenroseWorkbenchWindowAdvisor.preWindowOpen(Unknown Source)
at org.eclipse.ui.internal.WorkbenchWindow.fireWindowOpening(WorkbenchWindow.java:1038)
at org.eclipse.ui.internal.WorkbenchWindow.<init>(WorkbenchWindow.java:304)
at org.eclipse.ui.internal.Workbench.newWorkbenchWindow(Workbench.java:1173)
at org.eclipse.ui.internal.Workbench.busyOpenWorkbenchWindow(Workbench.java:662)
at org.eclipse.ui.internal.Workbench.doOpenFirstTimeWindow(Workbench.java:1282)
at org.eclipse.ui.internal.Workbench.openFirstTimeWindow(Workbench.java:1223)
at org.eclipse.ui.internal.WorkbenchConfigurer.openFirstTimeWindow(WorkbenchConfigurer.java:190)
at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(WorkbenchAdvisor.java:706)
at org.eclipse.ui.internal.Workbench.init(Workbench.java:1034)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1636)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:367)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143)
at org.safehaus.penrose.studio.PenroseApplication.run(Unknown Source)
at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:226)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:376)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:163)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.eclipse.core.launcher.Main.invokeFramework(Main.java:334)
at org.eclipse.core.launcher.Main.basicRun(Main.java:278)
at org.eclipse.core.launcher.Main.run(Main.java:973)
at org.eclipse.core.launcher.Main.main(Main.java:948)
Caused by: java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:364)
at java.net.Socket.connect(Socket.java:507)
at java.net.Socket.connect(Socket.java:457)
at java.net.Socket.<init>(Socket.java:365)
at java.net.Socket.<init>(Socket.java:178)
at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:22)
at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:128)
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:569)

Any idea

 All   Comments   Work Log   Change History      Sort Order:
Anteos - [06/Apr/06 04:20 AM ]
I've the same problem with penrose 0.9.9 and 0.1RC1. On windows XP i'm able to connect from studio to local server, but i'm unable to connect to a remote server on Linux. Connections from studio to server on a remote XP works!

Jim Yang - [16/May/06 04:29 PM ]
I was trying to replicate this on my Fedora Core 3 system (running Penrose).

I had to open all these ports on my iptables in order to get Penrose Studio connect to it

# allow access to port 10389
-A INPUT -p tcp -m tcp -s 0/0 --dport 10389 -j ACCEPT
-A INPUT -p tcp -m tcp -s 0/0 --dport 1099 -j ACCEPT
-A INPUT -p tcp -m tcp -s 0/0 --dport 50246 -j ACCEPT

I know these ports: 1099 (JMX), 10389 (LDAP), and a random high port (32000+) for RMI. in this case, it's port 50246.

My advise is to check your iptables/firewall config for the time being.

Having a fixed rmi port is a good idea.

See also http://forum.java.sun.com/thread.jspa?threadID=344254&messageID=1421944

Endi S. Dewata - [18/May/06 03:30 PM ]
This has been fixed. You can specify a fixed port number in the rmiTransportPort parameter. See:
http://docs.safehaus.org/display/PENROSE10/Services

Douglas Hammond - [14/Jun/06 10:26 AM ]
I had my hostname defined in my hosts file pointing to localhost.

eg.

127.0.0.1 localhost jedi

This causes rmi to send 127.0.0.1 as the host to contact.

Removed jedi and al works now.

Jim Yang - [18/Jul/06 09:15 AM ]
Try setting the PENROSE_OPTS environment variable before running the server:

export PENROSE_OPTS="-Djava.rmi.server.hostname="
penrose.sh -d

http://java.sun.com/j2se/1.4.2/docs/guide/rmi/javarmiproperties.html

java.rmi.server.hostname (1.1 and later)

The value of this property represents the host name string that should be associated with remote stubs for locally created remote objects, in order to allow clients to invoke methods on the remote object. In 1.1.7 and later, the default value of this property is the IP address of the local host, in "dotted-quad" format. Penrose doesn't set the java.rmi.server.hostname property, so the value would be the default as described above.

Chandrasekar Kannan - [27/Dec/08 03:01 AM ]
This Penrose Jira issue has been migrated to bugzilla.redhat.com as bug 478124. Access it here https://bugzilla.redhat.com/show_bug.cgi?id=478124