G
G
grabbee2016-10-24 17:02:21
Computer networks
grabbee, 2016-10-24 17:02:21

How to properly restart the network on the server?

I edited /etc/network/interfaces from initial to view

auto lo
iface lo inet loopback

# The primary network interface
auto enp1s0f0
iface enp1s0f0 inet manual

auto br0
iface br0 inet dhcp
        bridge_ports enp1s0f0
        bridge_stp off
        bridge_fd 0
        bridge_maxwait 0

Now I need the changes to take effect. How to do it? Previously restarted the server. But is it possible to do something else?
If something like
service network restart

Then the server stops responding to the ssh connection and you still need to restart the entire server ..

Answer the question

In order to leave comments, you need to log in

2 answer(s)
C
Cool Admin, 2016-10-24
@grabbee

If I do not confuse anything, then
Sequential execution:
sudo ifdown br0; ifup br0
Sequentially dependent execution
sudo ifdown br0 && ifup br0
It is better to use the first method, because the second one works only if the execution was completed successfully (as if, in reality, the interface can go down but return an execution error). Of course, you need to check it either if you have IPMI or in a virtual machine, or if you have the opportunity to restart.
SSH ceases to respond after the rise, because the tcp session is broken, you need to reconnect.
UPD but to say exactly what is wrong, you need to see the original file. The scale of the changes is not clear. Perhaps your network will not rise at all without a restart (for example, if you rebuild bridges)

P
Puma Thailand, 2016-10-25
@opium

in your case
service networking restart works fine for me

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question