Go Back   ZeroC Forums > Help Center

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
  #1 (permalink)  
Old 07-12-2005
mwilson mwilson is offline
Registered User
 
Name: Mark Wilson
Organization: University of Rochester
Project: Omega EP laser
 
Join Date: Jul 2005
Location: Rochester, NY
Posts: 73
Question Connection Refused Exception with Redhat Linux

Hello,

I have a service running on Redhat (uname -a: Linux lakeway 2.4.21-15.0.2.EL #1 Wed Jun 16 23:12:30 EDT 2004 i686 i686 i386 GNU/Linux), a client on Solaris 9.

The service refuses the connection (everything works okay with the service on another Sun box). My sysadmin guy got this from snoop:

[6] # snoop host lakeway
Using device /dev/eri (promiscuous mode)
cactus.lle.rochester.edu -> lakeway.lle.rochester.edu TCP D=10003 S=40826 Syn Seq=4178344468 Len=0 Win=32850 Options=<mss 1460,nop,wscale 3,nop,nop,tstamp 110355863 0,nop,nop,sackOK>
lakeway.lle.rochester.edu -> cactus.lle.rochester.edu TCP D=40826 S=10003 Rst Ack=4178344469 Win=0
cactus.lle.rochester.edu -> lakeway.lle.rochester.edu TCP D=10003 S=40827 Syn Seq=4178476356 Len=0 Win=32850 Options=<mss 1460,nop,wscale 3,nop,nop,tstamp 110355864 0,nop,nop,sackOK>
lakeway.lle.rochester.edu -> cactus.lle.rochester.edu TCP D=40827 S=10003 Rst Ack=4178476357 Win=0

No Ack is coming from the server, apparently.

Does this mean I need to update my version of Redhat?

BTW, I built Ice myself...

Thanks!
Mark
__________________
Mark E. Wilson
Lead Programmer/Analyst
Omega EP Project
Laboratory for Laser Energetics (www.lle.rochester.edu)
University of Rochester
Rochester, NY 14623
Reply With Quote
  #2 (permalink)  
Old 07-12-2005
benoit's Avatar
benoit benoit is offline
ZeroC Staff
 
Name: Benoit Foucher
Organization: ZeroC, Inc.
Project: Ice
 
Join Date: Feb 2003
Location: Rennes, France
Posts: 1,540
Hi Mark,

Can you run your client and server with the --Ice.Trace.Network=2 command line option and post the trace here? This should give us some clues on why your server isn't accepting the connection!

Benoit.
Reply With Quote
  #3 (permalink)  
Old 07-12-2005
mwilson mwilson is offline
Registered User
 
Name: Mark Wilson
Organization: University of Rochester
Project: Omega EP laser
 
Join Date: Jul 2005
Location: Rochester, NY
Posts: 73
Hi Benoit,

Here is what the server output:

./MSCServer --Ice.Trace.Network=2
[ ./MSCServer: Network: attempting to bind to tcp socket 127.0.0.1:10003 ]
[ ./MSCServer: Network: accepting tcp connections at 127.0.0.1:10003 ]

Here is the client output:

./MSCClient --Ice.Trace.Network=2
[ ./MSCClient: Network: trying to establish tcp connection to 172.20.32.8:10003 ]
[ ./MSCClient: Network: trying to establish tcp connection to 172.20.32.8:10003 ]
./MSCClient: Network.cpp:545: Ice::ConnectionRefusedException:
connection refused: Connection refused


Hope this helps.

Thanks,
Mark
__________________
Mark E. Wilson
Lead Programmer/Analyst
Omega EP Project
Laboratory for Laser Energetics (www.lle.rochester.edu)
University of Rochester
Rochester, NY 14623
Reply With Quote
  #4 (permalink)  
Old 07-12-2005
benoit's Avatar
benoit benoit is offline
ZeroC Staff
 
Name: Benoit Foucher
Organization: ZeroC, Inc.
Project: Ice
 
Join Date: Feb 2003
Location: Rennes, France
Posts: 1,540
Your server is listening on the loopback interface not on the network interface as shown by the traces. You need to change the configuration of your object adapter to get it to listen on the network interface instead. For example, the property:

Code:
HelloAdapter.Endpoints=tcp -h 72.20.32.8 -p 10003
will configure the adapter named "HelloAdapter" to listen on the interface with the IP address 72.20.32.8 and the port 10003. See the Ice manual for more information on how to configure the object adapter endpoints.

Let us know if you need more information!

Benoit.
Reply With Quote
  #5 (permalink)  
Old 07-12-2005
bernard's Avatar
bernard bernard is offline
ZeroC Staff
 
Name: Bernard Normier
Organization: ZeroC, Inc.
Project: Ice
 
Join Date: Feb 2003
Location: Palm Beach Gardens, FL
Posts: 816
This also suggests that your Linux server is not properly configured.

`hostname` should not return 'localhost' or 'localhost.localdomain', but a real hostname.
See the property Ice.Default.Host in the Ice manual.

Cheers,
Bernard
Reply With Quote
  #6 (permalink)  
Old 07-12-2005
mwilson mwilson is offline
Registered User
 
Name: Mark Wilson
Organization: University of Rochester
Project: Omega EP laser
 
Join Date: Jul 2005
Location: Rochester, NY
Posts: 73
Smile

Well, it works now. This is how I originally configured it in code:

adapter_ = communicator()->createObjectAdapterWithEndpoints(
"MSCAdapter",
"tcp -h lakeway -p 10003");


This is what I did to get it to work (in response to you guys):

adapter_ = communicator()->createObjectAdapterWithEndpoints(
"MSCAdapter",
"tcp -h 172.20.32.8 -p 10003");

and it works.

Why didn't the first work? When I do 'host lakeway', I get 172.20.32.8.
__________________
Mark E. Wilson
Lead Programmer/Analyst
Omega EP Project
Laboratory for Laser Energetics (www.lle.rochester.edu)
University of Rochester
Rochester, NY 14623
Reply With Quote
  #7 (permalink)  
Old 07-12-2005
bernard's Avatar
bernard bernard is offline
ZeroC Staff
 
Name: Bernard Normier
Organization: ZeroC, Inc.
Project: Ice
 
Join Date: Feb 2003
Location: Palm Beach Gardens, FL
Posts: 816
Your original code is correct (even if he does not work ). It's really a network configuration problem on lakeway, most likely in /etc/hosts.

`host lakeway` returns 172.20.32.8 when run from lakeway?

Cheers,
Bernard
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
No slice2java for Linux (no RedHat) at all alvakoldo10 Help Center 11 10-19-2006 05:56 AM
Build error in Redhat Linux 9.0 wuqiu Help Center 10 05-16-2006 11:39 PM
Performance problems on RedHat Linux 2.4.21 kernel gasproni Help Center 7 10-04-2005 10:54 AM
Redhat Enterprise Linux (RHEL) support? kent144 Help Center 3 08-07-2004 09:19 PM
Freeze build in Redhat Linux yomi Help Center 4 04-10-2004 01:20 PM


All times are GMT -4. The time now is 11:04 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0
(c) 2008 ZeroC, Inc.