Allow traffic from all ip to a range of ports ufw

Discussion in 'Installation/Configuration' started by Anders Yuran, Mar 28, 2020.

  1. Anders Yuran

    Anders Yuran New Member

    Beginner with ufw. I have a vps with two ip. Eth0 and eth 0:1. Now I want the eth0:1 to only accept tcp traffic to a range of ports. How do I do that? The other ip I have figured out myself.

    Another question. What ports should be open for a webserver? No ftp, no mail. Only Bind and ssh.


    Anders Yuran
  2. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    for a webserver. depends on what ports your using :)
    generally, 80 and 443 for http and https. also for ispconfig usually 8080 and 8081, for Plesk 8443.
    if you're proxying anything, it could literally be any port.
    ssh port 22
    bind port 53 ( udp and tcp )
    assuming you'll also need MySQL, and aren't using unix sockets, then that will want port 3306 by default.

Share This Page