How to fix MikroTik RouterOS v7 SSH port forwarding not working: Connection refused
In multiple models of MikroTik routers running RouterOS v7.5 I got Error: Connection refusedwhen running simple SSH port forwarding commands such as
mikrotik_ssh_forward.sh
ssh [email protected] -L 8080:192.168.178.1:80but in the RouterLS log I could see multiple local forwarding forbidden error messages:

Solution
In this case, the solution was simple: Go to IP -> SSHin WebFig or Winbox and set Forwarding Enabled to **Both**and click Apply.
**If you have already set Forwarding Enabled to Both or Local,**on one of my routers this setting wasn’t properly activated - possibly after a RoutreOS upgrade. In order to fix this, set Forwarding Enabled to no, click Apply, then set Forwarding Enabled to Both and click Apply again. For me, this fixed the issue of being unable to do SSH port forwarding.
Check out similar posts by category:
MikroTik, Networking
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow