66
votes
How do I remove an SSH forwarded port
When using ssh multiplexing,
killing the ssh process is often undesirable (it kills all open connections with that host),
and you cannot easily access the escape because "escape not available to ...
57
votes
Accepted
How does port-forwarding help in torrents?
In short: for BitTorrent (p2p) protocol to work at least one peer has to have a publicly open port (be an active node).
You can run Transmission without port forwarding (stay a passive node) and you ...
38
votes
I keep on getting a error when I connect to a ssh tunnel on putty
For me the key was that the "Diffie-Hellman group exchange" key exchange algorithm was not implemented on the server (see Connection > SSH > KEX).
Moving this key exchange algorithm to the bottom of ...
33
votes
SSH: Troubleshooting "Remote port forwarding failed for listen port" errors
Why does ssh -N -R 2222:localhost:22 <bluehost_user>@<bluehost_ip> result in a "Remote port forwarding failed for listen port" error?
I get this exact warning when I attempt to use a port ...
32
votes
Are there good alternative HTTP ports rather than port 80?
There are actually 3 HTTP alternative ports: 591, 8008 and 8080.
They are assigned by IANA as "HTTP Alternate", which makes them pretty much as official as it gets.
If you run Linux as a non-...
31
votes
How do I remove an SSH forwarded port
How to cancel a forwarded port in an already running SSH session:
Press ~+C (tilde + capital C)
Type -KL 10002 (or whatever port number)
Press Enter
You should see this:
ssh> -KL 10002
Canceled ...
23
votes
Windows 10 - NAT - Port forwarding & IP masquerade
Windows netsh can setup a proxy to allow administrators to proxy ipv6 traffic over ipv4. Netsh also has an option to configure a proxy for ipv4 to ipv4.
For your setup use netsh interface portproxy ...
23
votes
Accepted
How to choose open port number?
A port number is a 16-bit unsigned integer, thus ranging from 0 to 65535 (although 0 cannot be used for TCP; it has a special meaning for UDP).
You can use pretty much any port number in the range, ...
20
votes
How does port-forwarding help in torrents?
If uPnP/NAT-PMP was turned off on your torrent client, router, or both, then Inbound connections wouldn't work. You would then need to forward the port to your machine in your router's config or turn ...
16
votes
Accepted
Windows Subsystem for Linux & SSH Port Forwarding
Self answer: See this bug. The following works:
ssh -L 127.0.0.1:5432:localhost:5432 me@host
The problem is that IPv6 doesn't work in WSL and the failure flows through to the IPv4 port forwarding.
14
votes
Accepted
Can I run both a primary and secondary DNS server using the same public IP?
When it comes to primary and secondary DNS servers, from the viewpoint of any external entity it is actually irrelevant whether they run on a single machine, in separate VMs or on separate physical ...
13
votes
Set up a web server behind a Carrier Grade NAT
Your router's "WAN" address is from the private 100.64.0.0/10 range (which is kinda like 192.168.x, but dedicated specifically to CGNAT). So that means you're behind CGN and the global address you're ...
13
votes
Accepted
firewall-cmd - add-forward-port don't work
THE REAL PROBLEM:
The command...
firewall-cmd --permanent --zone=public --direct --add-rule ipv4 filter FORWARD 0 -d 0.0.0.0/0 -j ACCEPT
firewall-cmd --permanent --zone=public --add-forward-port=...
12
votes
Configure Tor as a listening proxy server that I can connect to remotely?
Use This:
SocksPort 0.0.0.0:9050
Setting 0.0.0.0 as host let all other devices on the network, see it and use it as a proxy.
11
votes
Accepted
Cannot access LAN with WAN address from within my LAN
It is possible to access your internal server using the router's public IP address/forwarded port, but your router must support loopback network address translation (a.k.a. hairpin NAT) and be ...
10
votes
UPnP port mapping client for Linux
Complementing @user1686 answer. This is how you can do it on Ubuntu, Mint and all Debian based distros:
# Install upnpc command line
sudo apt install -y miniupnpc
# Get network ip address (typically ...
10
votes
Accepted
Port Forwarding Samba
SMB uses ports 445/tcp and/or 139/tcp (usually just one is enough, but sometimes it's better to forward both). Additionally, the Windows SMB client requires Ping (ICMP Echo) to be open.
Note, however,...
Community wiki
10
votes
SSH: Troubleshooting "Remote port forwarding failed for listen port" errors
Make sure there is no hanging connection on port 2222 at bluehost.
Test at bluehost lsof -t -i:2222 whether any process id is using port 2222. Additionally, kill this process (for example with kill $(...
10
votes
Accepted
227 Entering Passive Mode (0,0,0,0,...) when connecting to vsftpd FTP server
Response: 227 Entering Passive Mode (0,0,0,0,31,84).
The 0,0,0,0 is most probably due to a known bug in vsftpd.
If that's the case, to fix this, make sure the server does not listen on IPv6 ...
10
votes
SSH forwarding through PuTTY not working on Windows 10
TCP port 49900 is within the port range (49152 to 65535) that is reserved for dynamic ports.
You should not open services using ports in that range. The recommended port range is from 1024 to 49151.
9
votes
I keep on getting a error when I connect to a ssh tunnel on putty
I got a similar error on 0.63 ... upgrading to 0.67 made it go away.
9
votes
How to create a subdomain pointing to a different port number?
You cannot assign a port number to a domain name or statically-defined host name.
A host name is translated into an IP address and port number is a separate number added to the IP address.
A DNS ...
9
votes
Unable to restart ssh on Mac OS Sierra - launchctl unload Could not find specified service
You can restart openSSH on your mac with the following (tested on Sierra 10.12.6)
sudo launchctl stop com.openssh.sshd
sudo launchctl start com.openssh.sshd
Source
9
votes
Set up a web server behind a Carrier Grade NAT
ngrok working fine for me. I was about to bang my head but you saved me.
my router is behind CGNAT. I signed up in ngrok with free account and believe me its free forever.
just need to download ngrok ...
9
votes
Can I run both a primary and secondary DNS server using the same public IP?
The primary objective of having two separate DNS servers is so that if one goes down the other will remain up for those who are using it, not because (as one might be-- albeit potentially while half-...
9
votes
Accepted
Difference between external port and internal port in port forwarding?
In layman's terms: Your router has a public IP address (the "external" address). Your router also provides the network devices within your home network with private IP addresses (the "...
8
votes
Accepted
Two computers with application running on same port
The router does not care. You have to tell it which of the two computers to forward to, and it ignores the other one.
If you want both computers to be accessible on the internet, you have to forward ...
8
votes
Access external IP from inside the network?
Most SOHO routers don't support hairpin NAT (AKA NAT loopback), which is accessing an internal machine via the external IP, from inside the same LAN.
You need a better router. If your router ...
8
votes
Accepted
Was my server being SSH brute-forced?
Why? Because you have a system on the internet.
A few simple steps you can take to combat this:
Disable password authentication and use key auth instead.
Put in place firewall rules to only accept ...
8
votes
Set up a web server behind a Carrier Grade NAT
I'd like to mention some other alternatives to ngrok. They are the following, in no particular order:
Serveo (Disabled at the time of writing)
Holepunch.io
See pricing there
Packetriot
See pricing ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
port-forwarding × 2327networking × 1133
router × 779
ssh × 423
linux × 207
port × 205
nat × 169
firewall × 151
wireless-networking × 141
iptables × 119
vpn × 114
ubuntu × 87
webserver × 77
virtualbox × 74
ssh-tunnel × 74
ip × 72
apache-http-server × 69
routing × 65
dns × 63
windows × 56
raspberry-pi × 54
macos × 53
wireless-router × 52
proxy × 46
openvpn × 41