Skip to main content

Firewall on Oracle virtual machines

·1 min

Oracle virtual machines, at least those running on Ubuntu, come with a restrictive firewall which doesn’t allow any incoming TCP traffic. Check before and after state using:

sudo iptables -L

Flush these rules:

sudo iptables --flush
sudo netfilter-persistent save

Or, just put the following into /etc/iptables/rules.v4:

# Generated by iptables-save v1.8.4 on Wed Oct 14 16:05:39 2020
*filter
:INPUT ACCEPT [255:17972]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [144:19732]
:InstanceServices - [0:0]
COMMIT
# Completed on Wed Oct 14 16:05:39 2020

Also: