I am configuring the security in my server. For easier the manage at the firewall, I installed the UFW. I did some settings in the UFW and I allowed some ports. Therefor when I enabled it the DNS services not responding.
I tried running the command DIG www.domain.com.br
to test the DNS but it did not succeed. This command run without problems when the UFW is disabled. I already allowed the 53 port (TCP and UDP) but the DNS does not work.
My UFW settings:
Status: active
Logging: on (low)
Default: deny (incoming), deny (outgoing), disabled (routed)
New profiles: skip
To Action From
-- ------ ----
21/tcp ALLOW IN Anywhere
16/tcp ALLOW IN Anywhere
443/tcp ALLOW IN Anywhere
80 ALLOW IN Anywhere
53 ALLOW IN Anywhere
465 ALLOW IN Anywhere
25/tcp ALLOW IN Anywhere
22 ALLOW IN Anywhere
21/tcp (v6) ALLOW IN Anywhere (v6)
16/tcp (v6) ALLOW IN Anywhere (v6)
443/tcp (v6) ALLOW IN Anywhere (v6)
80 (v6) ALLOW IN Anywhere (v6)
53 (v6) ALLOW IN Anywhere (v6)
465 (v6) ALLOW IN Anywhere (v6)
25/tcp (v6) ALLOW IN Anywhere (v6)
22 (v6) ALLOW IN Anywhere (v6)
ufw status verbose
...