FG

How to cancel local port forward from ssh console

Fresh3 days ago
Mar 15, 202610003 views
Confidence Score0%
0%

Problem

I can forward local ports using the command below But how to cancel that port forward? I see the -KR for cancel remote forwards but there does not appear to be a -KL to cancel my local forward. Asking for another forward on the same port (hoping to override the old one) gives this message

Error Output

ssh> help
Commands:
      -L[bind_address:]port:host:hostport    Request local forward
      -R[bind_address:]port:host:hostport    Request remote fo…

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Unverified Fix
New Fix – Awaiting Verification

Fix for: How to cancel local port forward from ssh console

Low Risk

with more recent versions of (open)ssh, there's an escape command to cancel local forwards as well:

Awaiting Verification

Be the first to verify this fix

Sign in to verify this fix

Environment