Programs Are Unable To Bind To Ports

Issues related to configuring your network
Post Reply
sniper7kills
Posts: 12
Joined: 2007/08/24 04:24:35
Contact:

Programs Are Unable To Bind To Ports

Post by sniper7kills » 2008/06/23 22:30:48

This is a weird issue and I'm not quite sure how to explain it, but ill give it my best shot. Im running a web/mail server and all of the programs that were configured about a month or more ago work just fine. Today i started to try and install ventrilo, then team speak and then voice chatter. As soon as i start any of the programs it will do the who starting services, binds to port etc. etc. If i to a port scan from my laptop the port those programs are running on appear closed, and i cant connect to them using their clients. If i do "nmap -sT -sU -O localhost" This is the output "Starting nmap 3.70 ( http://www.insecure.org/nmap/ ) at 2008-06-23 18:29 EDT
Insufficient responses for TCP sequencing (1), OS detection may be less accurate
Interesting ports on 192.168.1.197:
(The 3117 ports scanned but not shown below are in state: closed)
PORT STATE SERVICE
22/tcp open ssh
25/tcp open smtp
53/tcp open domain
53/udp open|filtered domain
80/tcp open http
110/tcp open pop3
111/tcp open rpcbind
111/udp open|filtered rpcbind
123/udp open|filtered ntp
143/tcp open imap
631/tcp open ipp
631/udp open|filtered unknown
872/udp open|filtered unknown
875/udp open|filtered unknown
878/tcp open unknown
993/tcp open imaps
995/tcp open pop3s
3306/tcp open mysql
6667/tcp open irc
8000/tcp open http-alt
10000/tcp open snet-sensor-mgmt
Device type: general purpose
Running: Linux 2.4.X|2.5.X
OS details: Linux 2.4.0 - 2.5.20

Nmap run completed -- 1 IP address (1 host up) scanned in 4.942 seconds"

Ive tried to open the ports on the firewall (even though its not active) and still no luck. Any Ideas?

unspawn
Posts: 172
Joined: 2006/12/11 12:28:52

Programs Are Unable To Bind To Ports

Post by unspawn » 2008/06/23 23:09:05

Scanning "localhost" may yield odd results: best scan from a machine outside the network.
Also note the discrepancy between saying the filewall is "not active" and nmap returning "filtered" for some ports.
What protocol/ports do these services use?
Does '/etc/init.d/[servicename] status' show them as running?
Does 'netstat -ntuple' show them as running?
Do these services log info somewhere and are there any erros in the logs?
Are there any messages in syslog wrt these services?
If you stop one service, then let 'nc' listen on that port, then can you telnet to that port from (preferably) a machine outside the network?

sniper7kills
Posts: 12
Joined: 2007/08/24 04:24:35
Contact:

Re: Programs Are Unable To Bind To Ports

Post by sniper7kills » 2008/06/23 23:23:40

Yea that is weird, At the moment i would like to get voice chatter (http://www.voicechatter.org/) to work, its trying to use UDP port 7878.
The whole '/etc/init.d/[servicename] status' doesnt work, but i know its running because its not running as a demon yet, i can see the programs output and there are no errors.

netstat -ntuple does show it as running:

udp 0 0 0.0.0.0:7878 0.0.0.0:* 0 18889 10424/voicechatters

The whole 0.0.0.0:7878 i think may be causing a problem.

and no i cant find any errors in the logs.

Besides iptables are there any other firewalls that are installed by default?

unspawn
Posts: 172
Joined: 2006/12/11 12:28:52

Re: Programs Are Unable To Bind To Ports

Post by unspawn » 2008/06/24 20:02:19

[quote]Besides iptables are there any other firewalls that are installed by default?[/quote]
No. GNU/Linux has one firewall called "Netfilter". Iptables is just a front-end for managing rules.

If you stop voicechatter on port UDP/7878, then let 'nc' listen on that port, then can you netcat to that port from a machine outside the network?

sniper7kills
Posts: 12
Joined: 2007/08/24 04:24:35
Contact:

Re: Programs Are Unable To Bind To Ports

Post by sniper7kills » 2008/06/25 00:24:58

No, It appears if i have nc listen to udp port 7878 (nc -l -u -p 7878) i can not nc to the server ( nc -u 192.168.1.197 7878).... (and yes that's from inside the network)

NOTE: as i was righting this a friend tried from outside the network and no it still does not work.

unspawn
Posts: 172
Joined: 2006/12/11 12:28:52

Re: Programs Are Unable To Bind To Ports

Post by unspawn » 2008/06/25 11:10:05

If you diagnose things then posting exact errors is *way* more useful than "doesn't work" or any equiv. of that. While terse or cryptic, errors usually give good indications of what's going on. You should also try to be complete about things. You did post log output here: http://www.voicechatter.org/forums/viewtopic.php?t=94&sid=0 which you should have refered to in this thread as it gives clues you didn't give here. That said, four more things to try: listing iptables rules anyway ('iptables -n -L'), checking /etc/hosts.{deny,allow} for DENY rules, finding out if there's any other firewalling on both remote and host side (provider?) and checking your router rules if your laptop is behind one.

sniper7kills
Posts: 12
Joined: 2007/08/24 04:24:35
Contact:

Re: Programs Are Unable To Bind To Ports

Post by sniper7kills » 2008/06/25 15:09:23

Sorry About that, Things have been slightly crazy.

iptables:
Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain FORWARD (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination

(at one point i removed iptables and that had no effect on it.)


/etc/hosts:
127.0.0.1 localhost.localdomain localhost

/etc/hosts.allow and .deny are both empty.



and there are no other firewalls the server is in the same network as my laptop, its running from my house

unspawn
Posts: 172
Joined: 2006/12/11 12:28:52

Re: Programs Are Unable To Bind To Ports

Post by unspawn » 2008/06/25 16:01:18

[quote]Sorry About that, Things have been slightly crazy.[/quote]
NP, NP.


[quote]and there are no other firewalls the server is in the same network as my laptop[/quote]
Can you check your router settings like MAC filter, Firewall, Network Address Translation, "Virtual Servers" or "Special Applications" or whatever it's called for rules that apply to your laptop that should also apply to your server? If you router allows a device to be in the DMZ you could also try that. Be cautious though, once in the DMZ all services will be exposed, so you must raise the firewall on the machine to only expose services you need to.

sniper7kills
Posts: 12
Joined: 2007/08/24 04:24:35
Contact:

Re: Programs Are Unable To Bind To Ports

Post by sniper7kills » 2008/06/25 16:07:00

Thats not the problem i have them both going through the same switch. they are in the same room. its 100% something with the server its not anything with my laptop or the network.

Post Reply

Return to “CentOS 4 - Networking Support”