How to allow 22 port via ufw?
(ubuntu server 22)
1. ufw status
-- if it is disable, you will enable
root@martin:~# ufw status
Status: inactive
root@martin:~# ufw enable
Command may disrupt existing ssh connections. Proceed with operation (y|n)? y
Firewall is active and enabled on system startup
root@martin:~# ufw status
Status: active
To Action From
-- ------ ----
514/tcp ALLOW Anywhere
514/tcp (v6) ALLOW Anywhere (v6)
2. allow port 22
root@martin:~# ufw allow 22/tcp
Rule added
Rule added (v6)
root@martin:~# ufw status
Status: active
To Action From
-- ------ ----
514/tcp ALLOW Anywhere
22/tcp ALLOW Anywhere
514/tcp (v6) ALLOW Anywhere (v6)
22/tcp (v6) ALLOW Anywhere (v6)
Žiadne komentáre:
Zverejnenie komentára