hai friends
while i runnig rmi simple application i do in the individual( both
client-server are in one) system it work nice.
server:


G:\hh>java -Djava.security.policy=hai.policy ProductServer
server
Binding
wait....

Client:

G:\hh>java -Djava.security.policy=client.policy ProductClient
connecting...
I am a Black book .Buy me
I am a core java .Buy me


but i run LAN i have exception like this
server
G:\hh>java -Djava.security.policy=hai.policy ProductServer
server
Binding
wait....

client:
G:\hh>java -Djava.security.policy=client.policy ProductClient
connecting...
javax.naming.ServiceUnavailableException [Root exception is
java.rmi.ConnectExce
ption: Connection refused to host: 172.16.1.133; nested exception is:
        java.net.ConnectException: Connection timed out: connect]
        at com.sun.jndi.rmi.registry.RegistryContext.lookup(Unknown
Source)
        at com.sun.jndi.toolkit.url.GenericURLContext.lookup(Unknown
Source)
        at javax.naming.InitialContext.lookup(Unknown Source)
        at ProductClient.main(ProductClient.java:15)
Caused by: java.rmi.ConnectException: Connection refused to host:
172.16.1.133;
nested exception is:
        java.net.ConnectException: Connection timed out: connect
        at sun.rmi.transport.tcp.TCPEndpoint.newSocket(Unknown Source)
        at sun.rmi.transport.tcp.TCPChannel.createConnection(Unknown
Source)
        at sun.rmi.transport.tcp.TCPChannel.newConnection(Unknown
Source)
        at sun.rmi.server.UnicastRef.newCall(Unknown Source)
        at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
        ... 4 more
Caused by: java.net.ConnectException: Connection timed out: connect
        at java.net.PlainSocketImpl.socketConnect(Native Method)
        at java.net.PlainSocketImpl.doConnect(Unknown Source)
        at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
        at java.net.PlainSocketImpl.connect(Unknown Source)
        at java.net.SocksSocketImpl.connect(Unknown Source)
        at java.net.Socket.connect(Unknown Source)
        at java.net.Socket.connect(Unknown Source)
        at java.net.Socket.<init>(Unknown Source)
        at java.net.Socket.<init>(Unknown Source)
        at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket
(Unknown S
ource)
        at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket
(Unknown S
ource)
        ... 9 more
suggest me friends whats a problem this is...

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"java-core" group.
 To post to this group, send email to [email protected]
 To unsubscribe from this group, send email to 
[email protected]
 For more options, visit this group at 
http://groups.google.co.in/group/java-core?hl=en-GB
-~----------~----~----~----~------~----~------~--~---

Reply via email to