Turn off ethernet negotiation Linux

Sometimes you might come across a situation where you need to manually set the ethernet speed and turn off the auto negotiation. In the below example, we set the ethernet speed to  1GBPS and turn off auto negotiation :

ethtool -s eth0 speed 1000 ethtool -s eth0 autoneg off