Break Network between two hosts without pulling Cable

Posted on

Break Network between two hosts without pulling Cable – Managing your servers can streamline the performance of your team by allowing them to complete complex tasks faster. Plus, it can enable them to detect problems early on before they get out of hand and compromise your business. As a result, the risk of experiencing operational setbacks is drastically lower.

But the only way to make the most of your server management is to perform it correctly. And to help you do so, this article will share nine tips on improving your server management and fix some problem about linux, networking, ethernet, nic, internet.

I have two Linux hosts HOST1 and HOST2 connected by cross cable. How I can break the network between then without breaking the physical wire (I don’t have access).

If i do:

HOST1# ifconfig eth0 down

Then NIC card will down. I just want to down link. Is any other way we can make network link down?

Solution :

If the cards are supported, you could probably use mii-tool -F or ethtool to force both ends into incompatible speeds.

Be sure to get the correct setting first so you can set them back to normal.

You can setup a reject route in the routing table.

# route add -net X.X.X.X netmask reject

If you want it persistent, you can add it to rc.local or something similar.

Depending on the exact outcome you want, you could implement subinterfaces and VLANs. This page has some configuration info:

What’s the current configuration? What are you trying to accomplish?

Short of turning down NICs or pulling the cable, you could ensure those interfaces are in different IP networks (or remove IPs) so they can no longer communicate.

Leave a Reply

Your email address will not be published. Required fields are marked *