3.2.1 ProblemYou want to prevent all remote network connections, incoming and outgoing, on your network interfaces. 3.2.2 SolutionTo shut down one network interface, say, eth0: # ifconfig eth0 down To bring up one network interface, say, eth0: # ifconfig eth0 up To shut down all networking: # /etc/init.d/network stop or: # service network stop Red Hat To bring up all networking: # /etc/init.d/network start or: # service network start Red Hat 3.2.3 DiscussionLinux provides three levels of abstraction for enabling and disabling your network interfaces (short of unplugging the network cable):
The scripts ifup, ifdown, and network are pretty short and well worth reading. 3.2.4 See Alsoifconfig(8). usernetctl(8) describes how non-root users may modify parameters of network interfaces using ifup and ifdown, if permitted by the system administrator. |