Using AMP on Oracle Cloud

This page was contributed by a member of the AMP community

Oracle Cloud Infrastructure offers a number of free instance types that are popular for running AMP. But the default Oracle Cloud setup can cause issues for getting AMP to work properly. This article helps resolve those issues.

  1. You must select Ubuntu 22.04 or newer (not minimal). Do not use Oracle Linux.
  2. For a better experience, run through steps 3 and 4 before installing AMP.
  3. Oracle Cloud uses iptables by default as the Ubuntu firewall, but has ufw installed, which currently confuses the AMP installation script. So, as root run the following to remove ufw entirely:
    apt purge ufw
    
  4. The default iptables rules on Oracle Cloud’s Ubuntu instances are set up badly, and will prevent most of AMP’s automatic firewall rules from working.
  • First, check that the rules are improperly configured. As root run:
    iptables -L INPUT --line-numbers
    
  • If you see a rule like the below in the INPUT chain, then you need to fix the rules. It might be a different line number:
    6 REJECT  All  -- anywhere   anywhere   reject-with icmp-host-prohibited
    
  • If you have a rule like the above, run the following as root (change 6 in the below to whatever line number you identified above):
    iptables -P INPUT DROP
    iptables -D INPUT 6
    iptables-save > /etc/iptables/rules.v4
    
  1. If you didn’t do the above before installing AMP, you will probably need to manually add a rule to allow access to the panel:
    iptables -A INPUT -p tcp -m tcp --dport 8080 -j ACCEPT && iptables-save > /etc/iptables/rules.v4
    
  2. As well as configuring the OS firewall, you also need to allow any required ports (such as 8080/TCP or 80/TCP and 443/TCP for AMP’s web interface, and 25565/TCP for a Minecraft server) on Oracle Cloud’s instance firewall. Instructions are here - see in particular the section Using the Console near the bottom for step-by-step instructions for adding Ingress Rules to an existing security list or to a new security list.
1 Like