2. In Linux system, you can use the sudoiptables command to open the port. Here is a simple example. Suppose we want to open port 8080 to all network access: first, log in to Linux system.
3. It seems that there are two main ways to open ports under ubuntu. One is ubuntu's own firewall, and the other is iptables. We mainly use iptables here. In general, iptables will be installed when ubuntu is installed, and there is no problem. You can install it with a command.
4.iptables-a output-ptcp-dport port number -jDROP Open port number: iptables-a input-ptcp-dport port number -jACCEPT The following is how to use the linux open port command.