LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
LinkBack Search this Thread
Old 02-06-2006, 01:34 PM   #1
mr_fern
LQ Newbie
 
Registered: Aug 2005
Distribution: RedHat 9
Posts: 3

Rep: Reputation: 0
Conflicts with TCP Ports


If you have two pieces of software both configured to listen to the same ports (and same ip addresses), what happens?

Does the first one that run actually listen to that port and the second program gets ignored?

Does the second program run listen and the first one get ignored?

Do both programs try to listen to the port?

or Does the second program not even run due to port conflict?
 
Old 02-06-2006, 01:46 PM   #2
bulliver
Senior Member
 
Registered: Nov 2002
Location: Edmonton AB, Canada
Distribution: Gentoo x86; Gentoo PPC; Gentoo Sparc64; FreeBSD; OS X; Solaris
Posts: 3,731
Blog Entries: 4

Rep: Reputation: 63
When you start the second server you should get:

SocketError: unable to bind to port
 
Old 02-06-2006, 01:47 PM   #3
gilead
Senior Member
 
Registered: Dec 2005
Location: Brisbane, Australia
Distribution: Slackware64 13.37
Posts: 4,084

Rep: Reputation: 135Reputation: 135
The first one running gets the port and the second one times out/errors. At least that's what happened on one of my boxes when Tomcat took port 8080 and another web server timed out waiting for it. Two programs can't listen on one port and if it were easy to bump an already listening daemon off with a second one, that sounds like an exploitable attack method.
 
Old 02-06-2006, 01:57 PM   #4
mr_fern
LQ Newbie
 
Registered: Aug 2005
Distribution: RedHat 9
Posts: 3

Original Poster
Rep: Reputation: 0
Thank you both for quick responses.

Just wanted to make sure the first daemon wouldn't be affected.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Sending files to open tcp ports skie_knite007 Programming 2 12-05-2005 10:19 AM
TCP Ports mm1977 Linux - Networking 1 01-31-2005 01:34 AM
Woody 3.0 Open Ports 1470/tcp/uaiact 1518/tcp/vpvd What for?How can I remove them? alexxxis Debian 5 07-05-2004 05:18 PM
DHCP, webmin, and TCP/IP ports mattrobbins Linux - Networking 5 10-14-2003 03:16 AM
how to open TCP/UDP ports RH9 franky Linux - Networking 3 07-18-2003 10:03 PM


All times are GMT -5. The time now is 06:35 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration