Ubuntu 18.04: switch back to /etc/network/interfaces

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
10
down vote

favorite
5












Starting sometime around Ubuntu 18.04, the Ubuntu devs stopped using the classic /etc/init.d/networking and /etc/network/interfaces method of configuring the network and switched to some thing called netplan. This has made a lot of people very angry and been widely regarded as a bad move. Is it possible to remove netplan and use the correct /etc/network/interfaces method for configuring the network?







share|improve this question
















  • 1




    Why not just configure with netplan? In most situations, it is pretty straightforward.
    – chili555
    May 3 at 20:00






  • 1




    @chili555 It may be that I just have to accept the change and learn something new. I'd just like to know if it is trivial to revert back to the way it should be. Much like systemd, I understand that disruptive change can sometimes be beneficial and be embraced. However, this is certainly not one of those times when the change was needed or beneficial.
    – jdgregson
    May 3 at 20:06






  • 1




    It is not trivial and not easily reversible in case of error. If you'd like to live dangerously, I'll be happy to propose an answer. On the other hand, we can configure netplan in a couple of minutes. Which do you prefer? PS- I don't pretend to fully understand how netplan, to the exclusion of /etc/network/interfaces, fits in to the larger systemd picture. All I can do is trust that those who introduced the change do know why it's a better fit.
    – chili555
    May 3 at 20:25










  • @chili555 This question is more or less academic, and certainly not something I would recommend anyone do in production. But it may serve to encourage offended users such as myself to begrudgingly accept that netplan is the correct way to configure networking in Ubuntu now, so by all means, suggest anything that comes to mind if you feel like exploring the question.
    – jdgregson
    May 3 at 20:54










  • Some workarounds I have thought of are: 1) place a script in /etc/init.d/networking which just calls netplan apply. 2) Write a script which converts the contents of /etc/network/interfaces into YAML-style netplan syntax and adds it to the netplan config.
    – jdgregson
    May 3 at 20:58














up vote
10
down vote

favorite
5












Starting sometime around Ubuntu 18.04, the Ubuntu devs stopped using the classic /etc/init.d/networking and /etc/network/interfaces method of configuring the network and switched to some thing called netplan. This has made a lot of people very angry and been widely regarded as a bad move. Is it possible to remove netplan and use the correct /etc/network/interfaces method for configuring the network?







share|improve this question
















  • 1




    Why not just configure with netplan? In most situations, it is pretty straightforward.
    – chili555
    May 3 at 20:00






  • 1




    @chili555 It may be that I just have to accept the change and learn something new. I'd just like to know if it is trivial to revert back to the way it should be. Much like systemd, I understand that disruptive change can sometimes be beneficial and be embraced. However, this is certainly not one of those times when the change was needed or beneficial.
    – jdgregson
    May 3 at 20:06






  • 1




    It is not trivial and not easily reversible in case of error. If you'd like to live dangerously, I'll be happy to propose an answer. On the other hand, we can configure netplan in a couple of minutes. Which do you prefer? PS- I don't pretend to fully understand how netplan, to the exclusion of /etc/network/interfaces, fits in to the larger systemd picture. All I can do is trust that those who introduced the change do know why it's a better fit.
    – chili555
    May 3 at 20:25










  • @chili555 This question is more or less academic, and certainly not something I would recommend anyone do in production. But it may serve to encourage offended users such as myself to begrudgingly accept that netplan is the correct way to configure networking in Ubuntu now, so by all means, suggest anything that comes to mind if you feel like exploring the question.
    – jdgregson
    May 3 at 20:54










  • Some workarounds I have thought of are: 1) place a script in /etc/init.d/networking which just calls netplan apply. 2) Write a script which converts the contents of /etc/network/interfaces into YAML-style netplan syntax and adds it to the netplan config.
    – jdgregson
    May 3 at 20:58












up vote
10
down vote

favorite
5









up vote
10
down vote

favorite
5






5





Starting sometime around Ubuntu 18.04, the Ubuntu devs stopped using the classic /etc/init.d/networking and /etc/network/interfaces method of configuring the network and switched to some thing called netplan. This has made a lot of people very angry and been widely regarded as a bad move. Is it possible to remove netplan and use the correct /etc/network/interfaces method for configuring the network?







share|improve this question












Starting sometime around Ubuntu 18.04, the Ubuntu devs stopped using the classic /etc/init.d/networking and /etc/network/interfaces method of configuring the network and switched to some thing called netplan. This has made a lot of people very angry and been widely regarded as a bad move. Is it possible to remove netplan and use the correct /etc/network/interfaces method for configuring the network?









share|improve this question











share|improve this question




share|improve this question










asked May 3 at 19:55









jdgregson

1981110




1981110







  • 1




    Why not just configure with netplan? In most situations, it is pretty straightforward.
    – chili555
    May 3 at 20:00






  • 1




    @chili555 It may be that I just have to accept the change and learn something new. I'd just like to know if it is trivial to revert back to the way it should be. Much like systemd, I understand that disruptive change can sometimes be beneficial and be embraced. However, this is certainly not one of those times when the change was needed or beneficial.
    – jdgregson
    May 3 at 20:06






  • 1




    It is not trivial and not easily reversible in case of error. If you'd like to live dangerously, I'll be happy to propose an answer. On the other hand, we can configure netplan in a couple of minutes. Which do you prefer? PS- I don't pretend to fully understand how netplan, to the exclusion of /etc/network/interfaces, fits in to the larger systemd picture. All I can do is trust that those who introduced the change do know why it's a better fit.
    – chili555
    May 3 at 20:25










  • @chili555 This question is more or less academic, and certainly not something I would recommend anyone do in production. But it may serve to encourage offended users such as myself to begrudgingly accept that netplan is the correct way to configure networking in Ubuntu now, so by all means, suggest anything that comes to mind if you feel like exploring the question.
    – jdgregson
    May 3 at 20:54










  • Some workarounds I have thought of are: 1) place a script in /etc/init.d/networking which just calls netplan apply. 2) Write a script which converts the contents of /etc/network/interfaces into YAML-style netplan syntax and adds it to the netplan config.
    – jdgregson
    May 3 at 20:58












  • 1




    Why not just configure with netplan? In most situations, it is pretty straightforward.
    – chili555
    May 3 at 20:00






  • 1




    @chili555 It may be that I just have to accept the change and learn something new. I'd just like to know if it is trivial to revert back to the way it should be. Much like systemd, I understand that disruptive change can sometimes be beneficial and be embraced. However, this is certainly not one of those times when the change was needed or beneficial.
    – jdgregson
    May 3 at 20:06






  • 1




    It is not trivial and not easily reversible in case of error. If you'd like to live dangerously, I'll be happy to propose an answer. On the other hand, we can configure netplan in a couple of minutes. Which do you prefer? PS- I don't pretend to fully understand how netplan, to the exclusion of /etc/network/interfaces, fits in to the larger systemd picture. All I can do is trust that those who introduced the change do know why it's a better fit.
    – chili555
    May 3 at 20:25










  • @chili555 This question is more or less academic, and certainly not something I would recommend anyone do in production. But it may serve to encourage offended users such as myself to begrudgingly accept that netplan is the correct way to configure networking in Ubuntu now, so by all means, suggest anything that comes to mind if you feel like exploring the question.
    – jdgregson
    May 3 at 20:54










  • Some workarounds I have thought of are: 1) place a script in /etc/init.d/networking which just calls netplan apply. 2) Write a script which converts the contents of /etc/network/interfaces into YAML-style netplan syntax and adds it to the netplan config.
    – jdgregson
    May 3 at 20:58







1




1




Why not just configure with netplan? In most situations, it is pretty straightforward.
– chili555
May 3 at 20:00




Why not just configure with netplan? In most situations, it is pretty straightforward.
– chili555
May 3 at 20:00




1




1




@chili555 It may be that I just have to accept the change and learn something new. I'd just like to know if it is trivial to revert back to the way it should be. Much like systemd, I understand that disruptive change can sometimes be beneficial and be embraced. However, this is certainly not one of those times when the change was needed or beneficial.
– jdgregson
May 3 at 20:06




@chili555 It may be that I just have to accept the change and learn something new. I'd just like to know if it is trivial to revert back to the way it should be. Much like systemd, I understand that disruptive change can sometimes be beneficial and be embraced. However, this is certainly not one of those times when the change was needed or beneficial.
– jdgregson
May 3 at 20:06




1




1




It is not trivial and not easily reversible in case of error. If you'd like to live dangerously, I'll be happy to propose an answer. On the other hand, we can configure netplan in a couple of minutes. Which do you prefer? PS- I don't pretend to fully understand how netplan, to the exclusion of /etc/network/interfaces, fits in to the larger systemd picture. All I can do is trust that those who introduced the change do know why it's a better fit.
– chili555
May 3 at 20:25




It is not trivial and not easily reversible in case of error. If you'd like to live dangerously, I'll be happy to propose an answer. On the other hand, we can configure netplan in a couple of minutes. Which do you prefer? PS- I don't pretend to fully understand how netplan, to the exclusion of /etc/network/interfaces, fits in to the larger systemd picture. All I can do is trust that those who introduced the change do know why it's a better fit.
– chili555
May 3 at 20:25












@chili555 This question is more or less academic, and certainly not something I would recommend anyone do in production. But it may serve to encourage offended users such as myself to begrudgingly accept that netplan is the correct way to configure networking in Ubuntu now, so by all means, suggest anything that comes to mind if you feel like exploring the question.
– jdgregson
May 3 at 20:54




@chili555 This question is more or less academic, and certainly not something I would recommend anyone do in production. But it may serve to encourage offended users such as myself to begrudgingly accept that netplan is the correct way to configure networking in Ubuntu now, so by all means, suggest anything that comes to mind if you feel like exploring the question.
– jdgregson
May 3 at 20:54












Some workarounds I have thought of are: 1) place a script in /etc/init.d/networking which just calls netplan apply. 2) Write a script which converts the contents of /etc/network/interfaces into YAML-style netplan syntax and adds it to the netplan config.
– jdgregson
May 3 at 20:58




Some workarounds I have thought of are: 1) place a script in /etc/init.d/networking which just calls netplan apply. 2) Write a script which converts the contents of /etc/network/interfaces into YAML-style netplan syntax and adds it to the netplan config.
– jdgregson
May 3 at 20:58










4 Answers
4






active

oldest

votes

















up vote
9
down vote



accepted










The following procedure works for Ubuntu 18.04 (Bionic Beaver)



I. Reinstall the ifupdown package:



# apt-get update
# apt-get install ifupdown


II. Configure your /etc/network/interfaces file with configuration stanzas such as:



source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

allow-hotplug enp0s3
auto enp0s3
iface enp0s3 inet static
address 192.168.1.133
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
dns-nameservers 8.8.8.8 8.8.4.4


III. Make the configuration effective (no reboot needed):



# ifdown --force enp0s3 lo && ifup -a


IV. Disable and remove the unwanted services:



# systemctl stop networkd-dispatcher
# systemctl disable networkd-dispatcher
# systemctl mask networkd-dispatcher
# apt-get purge nplan netplan.io


Then, you're done.



Note: You MUST of course adapt the values according your system (network, interface name...).






share|improve this answer


















  • 1




    Well, f*** them. Just apt-get install when you've got no network configuration. What a brilliant idea, Canonical.
    – Velkan
    Aug 3 at 6:47










  • @Velkan You can always pre-configure your network with netplan then switch back to ifupdown later on ;) But I agreed with you. Somehow canonical take bad decisions. For instance, they break softwares that rely on ifupdown for networking configuration (no provider for netplan). This is the case for our control panel software (stable serie) where we do not want add new network configuration provider...
    – Nuxwin
    Aug 5 at 9:58











  • @Nuxwin People who want a conservative system evolution will probably find Debian stable more to their liking. It is very like Ubuntu except that it moves more slowly - though processes a bit faster. I like Ubuntu because it does change and exposes me to new ideas, but I'm not running a production server or a system subject to any deadlines at all.
    – Stephen Boston
    2 days ago







  • 1




    @StephenBoston I totally agree with you. However, even if Canonical try to go ahead by introducing new technology, it could do this in less invasive manner. I mean, the choice should be left to end user. For workstations, the change from ifupdown to netplan is surely not a big deal but when you have to deal with Ubuntu servers, that's another story because most stable softwares doesn't necesserely provide adapters... That has been the same story for systemd. I've to deal with both Debian and Ubuntu everydays. The problem with Ubuntu is that they don't care much about backward compatibility.
    – Nuxwin
    yesterday


















up vote
1
down vote













Why not just configure with netplan?



Well, as it is configured in 18.04-Desktop, it is a single line handing over control to all interfaces to NetworkManager.



While that is probably suitable for 95% of users, remember that NetworkManager is only run once you are logged in to a session.



Should you want your machine to act as a server/desktop, for example start serving files to local machines, acting as VNP server, etc... or anything "fancy" before anyone is ever logged in, just by the simple fact it is on, you will have trouble with how it is configured in standard 18.04-Desktop.



Of course, the alternative would be to use the server-Netplan configuration, which, as far as I have read (not checked by myself), hands control over to systemd-networkd instead.
In this case you'd better learn how systemd does things as a replacement of the old System V init.



Should you go this path, you still have to make change to the netplan yaml, since on a desktop version the control is given to NetworkManager.






share|improve this answer




















  • At least one reason exists: Netplan does not support openvswitch.
    – Kamilion
    2 days ago

















up vote
1
down vote













The key is knowing that cloud.init is the real control program.

That being said the line in the netplan config file "optional: true" is mandatory.

Knowing that made it easy.



I just removed 01-network-manager-all.yaml and copied it to /root/save/.
Then put a known good config in place instead of it, 50-cloud-init.yaml: its contents follow:



network:
version: 2
renderer: networkd
ethernets:
eports:
match:
name: enp*
optional: true
bonds:
bond0:
interfaces: [eports]
addresses: [192.168.2.5/24]
gateway4: 192.168.2.1
nameservers:
addresses: [127.0.0.1, 8.8.4.4]
parameters:
mode: 0
mii-monitor-interval: 100


Then reboot and it should be working fine.



The known good config came from Configure bonded 802.3ad network using netplan on Ubuntu 18.04.






share|improve this answer










New contributor




pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

















  • The question here is how to switch back to ifupdown ;) In future, you should try to answer the questions without polluting them, even through it is not always easy to stick to initial subject ;)
    – Nuxwin
    yesterday

















up vote
0
down vote













According to this answer, the solution is to remove all operational .yaml files: Ubuntu 17.10 disable netplan



I wouldn’t remove anything without backing up. We can do so easily by simply moving the files aside. First, locate the files:



sudo updatedb
locate netplan | grep yaml


On my 18.04 system, it appears that the only operational file is /etc/netplan/01-network-manager-all.yaml. Let’s move it:



mkdir ~/netplan
sudo mv /etc/netplan/01-network-manager-all.yaml /home/user/netplan


...where user is your user name.



Now check to make sure the file is truly gone:



ls /etc/netplan


Now make your additions to /etc/network/interfaces as required.



Reboot.



Any improvement?



Footnote: The exact process to do this is hard to find. We may need to refine a bit as we go.






share|improve this answer




















  • I'll have to try that and see how it goes. The only other question would be how to apply the changes without rebooting. In the past you could use ifup/ifdown, /etc/init.d/networking restart, service networking restart, and the systemd methods, like systemctl restart networking, systemctl restart Network-Manager.service etc, but none of these were possible for me after installing Ubuntu 18.04.
    – jdgregson
    May 3 at 22:05










  • What is the result of: sudo ip link set eth0 down followed by: sudo ifup -v eth0 Of course, substitute your interface for the mythical eth0.
    – chili555
    May 3 at 23:01











  • ifupdown is not installed by default, so when you call ifup it just tells you how to install it. However, sudo ip link set eth0 down followed by sudo ip link set eth0 up does turn the interface off and back on.
    – jdgregson
    May 3 at 23:27











  • Awesome! So you are solved and all set?
    – chili555
    May 3 at 23:46










  • Careful, not all *.yaml files are related to netplan, so only remove those in netplan-related directories!
    – JanC
    May 5 at 19:33










Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "89"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1031709%2fubuntu-18-04-switch-back-to-etc-network-interfaces%23new-answer', 'question_page');

);

Post as a guest






























4 Answers
4






active

oldest

votes








4 Answers
4






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
9
down vote



accepted










The following procedure works for Ubuntu 18.04 (Bionic Beaver)



I. Reinstall the ifupdown package:



# apt-get update
# apt-get install ifupdown


II. Configure your /etc/network/interfaces file with configuration stanzas such as:



source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

allow-hotplug enp0s3
auto enp0s3
iface enp0s3 inet static
address 192.168.1.133
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
dns-nameservers 8.8.8.8 8.8.4.4


III. Make the configuration effective (no reboot needed):



# ifdown --force enp0s3 lo && ifup -a


IV. Disable and remove the unwanted services:



# systemctl stop networkd-dispatcher
# systemctl disable networkd-dispatcher
# systemctl mask networkd-dispatcher
# apt-get purge nplan netplan.io


Then, you're done.



Note: You MUST of course adapt the values according your system (network, interface name...).






share|improve this answer


















  • 1




    Well, f*** them. Just apt-get install when you've got no network configuration. What a brilliant idea, Canonical.
    – Velkan
    Aug 3 at 6:47










  • @Velkan You can always pre-configure your network with netplan then switch back to ifupdown later on ;) But I agreed with you. Somehow canonical take bad decisions. For instance, they break softwares that rely on ifupdown for networking configuration (no provider for netplan). This is the case for our control panel software (stable serie) where we do not want add new network configuration provider...
    – Nuxwin
    Aug 5 at 9:58











  • @Nuxwin People who want a conservative system evolution will probably find Debian stable more to their liking. It is very like Ubuntu except that it moves more slowly - though processes a bit faster. I like Ubuntu because it does change and exposes me to new ideas, but I'm not running a production server or a system subject to any deadlines at all.
    – Stephen Boston
    2 days ago







  • 1




    @StephenBoston I totally agree with you. However, even if Canonical try to go ahead by introducing new technology, it could do this in less invasive manner. I mean, the choice should be left to end user. For workstations, the change from ifupdown to netplan is surely not a big deal but when you have to deal with Ubuntu servers, that's another story because most stable softwares doesn't necesserely provide adapters... That has been the same story for systemd. I've to deal with both Debian and Ubuntu everydays. The problem with Ubuntu is that they don't care much about backward compatibility.
    – Nuxwin
    yesterday















up vote
9
down vote



accepted










The following procedure works for Ubuntu 18.04 (Bionic Beaver)



I. Reinstall the ifupdown package:



# apt-get update
# apt-get install ifupdown


II. Configure your /etc/network/interfaces file with configuration stanzas such as:



source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

allow-hotplug enp0s3
auto enp0s3
iface enp0s3 inet static
address 192.168.1.133
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
dns-nameservers 8.8.8.8 8.8.4.4


III. Make the configuration effective (no reboot needed):



# ifdown --force enp0s3 lo && ifup -a


IV. Disable and remove the unwanted services:



# systemctl stop networkd-dispatcher
# systemctl disable networkd-dispatcher
# systemctl mask networkd-dispatcher
# apt-get purge nplan netplan.io


Then, you're done.



Note: You MUST of course adapt the values according your system (network, interface name...).






share|improve this answer


















  • 1




    Well, f*** them. Just apt-get install when you've got no network configuration. What a brilliant idea, Canonical.
    – Velkan
    Aug 3 at 6:47










  • @Velkan You can always pre-configure your network with netplan then switch back to ifupdown later on ;) But I agreed with you. Somehow canonical take bad decisions. For instance, they break softwares that rely on ifupdown for networking configuration (no provider for netplan). This is the case for our control panel software (stable serie) where we do not want add new network configuration provider...
    – Nuxwin
    Aug 5 at 9:58











  • @Nuxwin People who want a conservative system evolution will probably find Debian stable more to their liking. It is very like Ubuntu except that it moves more slowly - though processes a bit faster. I like Ubuntu because it does change and exposes me to new ideas, but I'm not running a production server or a system subject to any deadlines at all.
    – Stephen Boston
    2 days ago







  • 1




    @StephenBoston I totally agree with you. However, even if Canonical try to go ahead by introducing new technology, it could do this in less invasive manner. I mean, the choice should be left to end user. For workstations, the change from ifupdown to netplan is surely not a big deal but when you have to deal with Ubuntu servers, that's another story because most stable softwares doesn't necesserely provide adapters... That has been the same story for systemd. I've to deal with both Debian and Ubuntu everydays. The problem with Ubuntu is that they don't care much about backward compatibility.
    – Nuxwin
    yesterday













up vote
9
down vote



accepted







up vote
9
down vote



accepted






The following procedure works for Ubuntu 18.04 (Bionic Beaver)



I. Reinstall the ifupdown package:



# apt-get update
# apt-get install ifupdown


II. Configure your /etc/network/interfaces file with configuration stanzas such as:



source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

allow-hotplug enp0s3
auto enp0s3
iface enp0s3 inet static
address 192.168.1.133
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
dns-nameservers 8.8.8.8 8.8.4.4


III. Make the configuration effective (no reboot needed):



# ifdown --force enp0s3 lo && ifup -a


IV. Disable and remove the unwanted services:



# systemctl stop networkd-dispatcher
# systemctl disable networkd-dispatcher
# systemctl mask networkd-dispatcher
# apt-get purge nplan netplan.io


Then, you're done.



Note: You MUST of course adapt the values according your system (network, interface name...).






share|improve this answer














The following procedure works for Ubuntu 18.04 (Bionic Beaver)



I. Reinstall the ifupdown package:



# apt-get update
# apt-get install ifupdown


II. Configure your /etc/network/interfaces file with configuration stanzas such as:



source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

allow-hotplug enp0s3
auto enp0s3
iface enp0s3 inet static
address 192.168.1.133
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
dns-nameservers 8.8.8.8 8.8.4.4


III. Make the configuration effective (no reboot needed):



# ifdown --force enp0s3 lo && ifup -a


IV. Disable and remove the unwanted services:



# systemctl stop networkd-dispatcher
# systemctl disable networkd-dispatcher
# systemctl mask networkd-dispatcher
# apt-get purge nplan netplan.io


Then, you're done.



Note: You MUST of course adapt the values according your system (network, interface name...).







share|improve this answer














share|improve this answer



share|improve this answer








edited Jul 21 at 16:36

























answered Jul 4 at 7:07









Nuxwin

20615




20615







  • 1




    Well, f*** them. Just apt-get install when you've got no network configuration. What a brilliant idea, Canonical.
    – Velkan
    Aug 3 at 6:47










  • @Velkan You can always pre-configure your network with netplan then switch back to ifupdown later on ;) But I agreed with you. Somehow canonical take bad decisions. For instance, they break softwares that rely on ifupdown for networking configuration (no provider for netplan). This is the case for our control panel software (stable serie) where we do not want add new network configuration provider...
    – Nuxwin
    Aug 5 at 9:58











  • @Nuxwin People who want a conservative system evolution will probably find Debian stable more to their liking. It is very like Ubuntu except that it moves more slowly - though processes a bit faster. I like Ubuntu because it does change and exposes me to new ideas, but I'm not running a production server or a system subject to any deadlines at all.
    – Stephen Boston
    2 days ago







  • 1




    @StephenBoston I totally agree with you. However, even if Canonical try to go ahead by introducing new technology, it could do this in less invasive manner. I mean, the choice should be left to end user. For workstations, the change from ifupdown to netplan is surely not a big deal but when you have to deal with Ubuntu servers, that's another story because most stable softwares doesn't necesserely provide adapters... That has been the same story for systemd. I've to deal with both Debian and Ubuntu everydays. The problem with Ubuntu is that they don't care much about backward compatibility.
    – Nuxwin
    yesterday













  • 1




    Well, f*** them. Just apt-get install when you've got no network configuration. What a brilliant idea, Canonical.
    – Velkan
    Aug 3 at 6:47










  • @Velkan You can always pre-configure your network with netplan then switch back to ifupdown later on ;) But I agreed with you. Somehow canonical take bad decisions. For instance, they break softwares that rely on ifupdown for networking configuration (no provider for netplan). This is the case for our control panel software (stable serie) where we do not want add new network configuration provider...
    – Nuxwin
    Aug 5 at 9:58











  • @Nuxwin People who want a conservative system evolution will probably find Debian stable more to their liking. It is very like Ubuntu except that it moves more slowly - though processes a bit faster. I like Ubuntu because it does change and exposes me to new ideas, but I'm not running a production server or a system subject to any deadlines at all.
    – Stephen Boston
    2 days ago







  • 1




    @StephenBoston I totally agree with you. However, even if Canonical try to go ahead by introducing new technology, it could do this in less invasive manner. I mean, the choice should be left to end user. For workstations, the change from ifupdown to netplan is surely not a big deal but when you have to deal with Ubuntu servers, that's another story because most stable softwares doesn't necesserely provide adapters... That has been the same story for systemd. I've to deal with both Debian and Ubuntu everydays. The problem with Ubuntu is that they don't care much about backward compatibility.
    – Nuxwin
    yesterday








1




1




Well, f*** them. Just apt-get install when you've got no network configuration. What a brilliant idea, Canonical.
– Velkan
Aug 3 at 6:47




Well, f*** them. Just apt-get install when you've got no network configuration. What a brilliant idea, Canonical.
– Velkan
Aug 3 at 6:47












@Velkan You can always pre-configure your network with netplan then switch back to ifupdown later on ;) But I agreed with you. Somehow canonical take bad decisions. For instance, they break softwares that rely on ifupdown for networking configuration (no provider for netplan). This is the case for our control panel software (stable serie) where we do not want add new network configuration provider...
– Nuxwin
Aug 5 at 9:58





@Velkan You can always pre-configure your network with netplan then switch back to ifupdown later on ;) But I agreed with you. Somehow canonical take bad decisions. For instance, they break softwares that rely on ifupdown for networking configuration (no provider for netplan). This is the case for our control panel software (stable serie) where we do not want add new network configuration provider...
– Nuxwin
Aug 5 at 9:58













@Nuxwin People who want a conservative system evolution will probably find Debian stable more to their liking. It is very like Ubuntu except that it moves more slowly - though processes a bit faster. I like Ubuntu because it does change and exposes me to new ideas, but I'm not running a production server or a system subject to any deadlines at all.
– Stephen Boston
2 days ago





@Nuxwin People who want a conservative system evolution will probably find Debian stable more to their liking. It is very like Ubuntu except that it moves more slowly - though processes a bit faster. I like Ubuntu because it does change and exposes me to new ideas, but I'm not running a production server or a system subject to any deadlines at all.
– Stephen Boston
2 days ago





1




1




@StephenBoston I totally agree with you. However, even if Canonical try to go ahead by introducing new technology, it could do this in less invasive manner. I mean, the choice should be left to end user. For workstations, the change from ifupdown to netplan is surely not a big deal but when you have to deal with Ubuntu servers, that's another story because most stable softwares doesn't necesserely provide adapters... That has been the same story for systemd. I've to deal with both Debian and Ubuntu everydays. The problem with Ubuntu is that they don't care much about backward compatibility.
– Nuxwin
yesterday





@StephenBoston I totally agree with you. However, even if Canonical try to go ahead by introducing new technology, it could do this in less invasive manner. I mean, the choice should be left to end user. For workstations, the change from ifupdown to netplan is surely not a big deal but when you have to deal with Ubuntu servers, that's another story because most stable softwares doesn't necesserely provide adapters... That has been the same story for systemd. I've to deal with both Debian and Ubuntu everydays. The problem with Ubuntu is that they don't care much about backward compatibility.
– Nuxwin
yesterday













up vote
1
down vote













Why not just configure with netplan?



Well, as it is configured in 18.04-Desktop, it is a single line handing over control to all interfaces to NetworkManager.



While that is probably suitable for 95% of users, remember that NetworkManager is only run once you are logged in to a session.



Should you want your machine to act as a server/desktop, for example start serving files to local machines, acting as VNP server, etc... or anything "fancy" before anyone is ever logged in, just by the simple fact it is on, you will have trouble with how it is configured in standard 18.04-Desktop.



Of course, the alternative would be to use the server-Netplan configuration, which, as far as I have read (not checked by myself), hands control over to systemd-networkd instead.
In this case you'd better learn how systemd does things as a replacement of the old System V init.



Should you go this path, you still have to make change to the netplan yaml, since on a desktop version the control is given to NetworkManager.






share|improve this answer




















  • At least one reason exists: Netplan does not support openvswitch.
    – Kamilion
    2 days ago














up vote
1
down vote













Why not just configure with netplan?



Well, as it is configured in 18.04-Desktop, it is a single line handing over control to all interfaces to NetworkManager.



While that is probably suitable for 95% of users, remember that NetworkManager is only run once you are logged in to a session.



Should you want your machine to act as a server/desktop, for example start serving files to local machines, acting as VNP server, etc... or anything "fancy" before anyone is ever logged in, just by the simple fact it is on, you will have trouble with how it is configured in standard 18.04-Desktop.



Of course, the alternative would be to use the server-Netplan configuration, which, as far as I have read (not checked by myself), hands control over to systemd-networkd instead.
In this case you'd better learn how systemd does things as a replacement of the old System V init.



Should you go this path, you still have to make change to the netplan yaml, since on a desktop version the control is given to NetworkManager.






share|improve this answer




















  • At least one reason exists: Netplan does not support openvswitch.
    – Kamilion
    2 days ago












up vote
1
down vote










up vote
1
down vote









Why not just configure with netplan?



Well, as it is configured in 18.04-Desktop, it is a single line handing over control to all interfaces to NetworkManager.



While that is probably suitable for 95% of users, remember that NetworkManager is only run once you are logged in to a session.



Should you want your machine to act as a server/desktop, for example start serving files to local machines, acting as VNP server, etc... or anything "fancy" before anyone is ever logged in, just by the simple fact it is on, you will have trouble with how it is configured in standard 18.04-Desktop.



Of course, the alternative would be to use the server-Netplan configuration, which, as far as I have read (not checked by myself), hands control over to systemd-networkd instead.
In this case you'd better learn how systemd does things as a replacement of the old System V init.



Should you go this path, you still have to make change to the netplan yaml, since on a desktop version the control is given to NetworkManager.






share|improve this answer












Why not just configure with netplan?



Well, as it is configured in 18.04-Desktop, it is a single line handing over control to all interfaces to NetworkManager.



While that is probably suitable for 95% of users, remember that NetworkManager is only run once you are logged in to a session.



Should you want your machine to act as a server/desktop, for example start serving files to local machines, acting as VNP server, etc... or anything "fancy" before anyone is ever logged in, just by the simple fact it is on, you will have trouble with how it is configured in standard 18.04-Desktop.



Of course, the alternative would be to use the server-Netplan configuration, which, as far as I have read (not checked by myself), hands control over to systemd-networkd instead.
In this case you'd better learn how systemd does things as a replacement of the old System V init.



Should you go this path, you still have to make change to the netplan yaml, since on a desktop version the control is given to NetworkManager.







share|improve this answer












share|improve this answer



share|improve this answer










answered May 21 at 8:25









Zakhar

5618




5618











  • At least one reason exists: Netplan does not support openvswitch.
    – Kamilion
    2 days ago
















  • At least one reason exists: Netplan does not support openvswitch.
    – Kamilion
    2 days ago















At least one reason exists: Netplan does not support openvswitch.
– Kamilion
2 days ago




At least one reason exists: Netplan does not support openvswitch.
– Kamilion
2 days ago










up vote
1
down vote













The key is knowing that cloud.init is the real control program.

That being said the line in the netplan config file "optional: true" is mandatory.

Knowing that made it easy.



I just removed 01-network-manager-all.yaml and copied it to /root/save/.
Then put a known good config in place instead of it, 50-cloud-init.yaml: its contents follow:



network:
version: 2
renderer: networkd
ethernets:
eports:
match:
name: enp*
optional: true
bonds:
bond0:
interfaces: [eports]
addresses: [192.168.2.5/24]
gateway4: 192.168.2.1
nameservers:
addresses: [127.0.0.1, 8.8.4.4]
parameters:
mode: 0
mii-monitor-interval: 100


Then reboot and it should be working fine.



The known good config came from Configure bonded 802.3ad network using netplan on Ubuntu 18.04.






share|improve this answer










New contributor




pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

















  • The question here is how to switch back to ifupdown ;) In future, you should try to answer the questions without polluting them, even through it is not always easy to stick to initial subject ;)
    – Nuxwin
    yesterday














up vote
1
down vote













The key is knowing that cloud.init is the real control program.

That being said the line in the netplan config file "optional: true" is mandatory.

Knowing that made it easy.



I just removed 01-network-manager-all.yaml and copied it to /root/save/.
Then put a known good config in place instead of it, 50-cloud-init.yaml: its contents follow:



network:
version: 2
renderer: networkd
ethernets:
eports:
match:
name: enp*
optional: true
bonds:
bond0:
interfaces: [eports]
addresses: [192.168.2.5/24]
gateway4: 192.168.2.1
nameservers:
addresses: [127.0.0.1, 8.8.4.4]
parameters:
mode: 0
mii-monitor-interval: 100


Then reboot and it should be working fine.



The known good config came from Configure bonded 802.3ad network using netplan on Ubuntu 18.04.






share|improve this answer










New contributor




pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

















  • The question here is how to switch back to ifupdown ;) In future, you should try to answer the questions without polluting them, even through it is not always easy to stick to initial subject ;)
    – Nuxwin
    yesterday












up vote
1
down vote










up vote
1
down vote









The key is knowing that cloud.init is the real control program.

That being said the line in the netplan config file "optional: true" is mandatory.

Knowing that made it easy.



I just removed 01-network-manager-all.yaml and copied it to /root/save/.
Then put a known good config in place instead of it, 50-cloud-init.yaml: its contents follow:



network:
version: 2
renderer: networkd
ethernets:
eports:
match:
name: enp*
optional: true
bonds:
bond0:
interfaces: [eports]
addresses: [192.168.2.5/24]
gateway4: 192.168.2.1
nameservers:
addresses: [127.0.0.1, 8.8.4.4]
parameters:
mode: 0
mii-monitor-interval: 100


Then reboot and it should be working fine.



The known good config came from Configure bonded 802.3ad network using netplan on Ubuntu 18.04.






share|improve this answer










New contributor




pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









The key is knowing that cloud.init is the real control program.

That being said the line in the netplan config file "optional: true" is mandatory.

Knowing that made it easy.



I just removed 01-network-manager-all.yaml and copied it to /root/save/.
Then put a known good config in place instead of it, 50-cloud-init.yaml: its contents follow:



network:
version: 2
renderer: networkd
ethernets:
eports:
match:
name: enp*
optional: true
bonds:
bond0:
interfaces: [eports]
addresses: [192.168.2.5/24]
gateway4: 192.168.2.1
nameservers:
addresses: [127.0.0.1, 8.8.4.4]
parameters:
mode: 0
mii-monitor-interval: 100


Then reboot and it should be working fine.



The known good config came from Configure bonded 802.3ad network using netplan on Ubuntu 18.04.







share|improve this answer










New contributor




pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









share|improve this answer



share|improve this answer








edited 2 days ago









David Foerster

26k1361106




26k1361106






New contributor




pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.









answered 2 days ago









pksings

111




111




New contributor




pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.





New contributor





pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.






pksings is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.











  • The question here is how to switch back to ifupdown ;) In future, you should try to answer the questions without polluting them, even through it is not always easy to stick to initial subject ;)
    – Nuxwin
    yesterday
















  • The question here is how to switch back to ifupdown ;) In future, you should try to answer the questions without polluting them, even through it is not always easy to stick to initial subject ;)
    – Nuxwin
    yesterday















The question here is how to switch back to ifupdown ;) In future, you should try to answer the questions without polluting them, even through it is not always easy to stick to initial subject ;)
– Nuxwin
yesterday




The question here is how to switch back to ifupdown ;) In future, you should try to answer the questions without polluting them, even through it is not always easy to stick to initial subject ;)
– Nuxwin
yesterday










up vote
0
down vote













According to this answer, the solution is to remove all operational .yaml files: Ubuntu 17.10 disable netplan



I wouldn’t remove anything without backing up. We can do so easily by simply moving the files aside. First, locate the files:



sudo updatedb
locate netplan | grep yaml


On my 18.04 system, it appears that the only operational file is /etc/netplan/01-network-manager-all.yaml. Let’s move it:



mkdir ~/netplan
sudo mv /etc/netplan/01-network-manager-all.yaml /home/user/netplan


...where user is your user name.



Now check to make sure the file is truly gone:



ls /etc/netplan


Now make your additions to /etc/network/interfaces as required.



Reboot.



Any improvement?



Footnote: The exact process to do this is hard to find. We may need to refine a bit as we go.






share|improve this answer




















  • I'll have to try that and see how it goes. The only other question would be how to apply the changes without rebooting. In the past you could use ifup/ifdown, /etc/init.d/networking restart, service networking restart, and the systemd methods, like systemctl restart networking, systemctl restart Network-Manager.service etc, but none of these were possible for me after installing Ubuntu 18.04.
    – jdgregson
    May 3 at 22:05










  • What is the result of: sudo ip link set eth0 down followed by: sudo ifup -v eth0 Of course, substitute your interface for the mythical eth0.
    – chili555
    May 3 at 23:01











  • ifupdown is not installed by default, so when you call ifup it just tells you how to install it. However, sudo ip link set eth0 down followed by sudo ip link set eth0 up does turn the interface off and back on.
    – jdgregson
    May 3 at 23:27











  • Awesome! So you are solved and all set?
    – chili555
    May 3 at 23:46










  • Careful, not all *.yaml files are related to netplan, so only remove those in netplan-related directories!
    – JanC
    May 5 at 19:33














up vote
0
down vote













According to this answer, the solution is to remove all operational .yaml files: Ubuntu 17.10 disable netplan



I wouldn’t remove anything without backing up. We can do so easily by simply moving the files aside. First, locate the files:



sudo updatedb
locate netplan | grep yaml


On my 18.04 system, it appears that the only operational file is /etc/netplan/01-network-manager-all.yaml. Let’s move it:



mkdir ~/netplan
sudo mv /etc/netplan/01-network-manager-all.yaml /home/user/netplan


...where user is your user name.



Now check to make sure the file is truly gone:



ls /etc/netplan


Now make your additions to /etc/network/interfaces as required.



Reboot.



Any improvement?



Footnote: The exact process to do this is hard to find. We may need to refine a bit as we go.






share|improve this answer




















  • I'll have to try that and see how it goes. The only other question would be how to apply the changes without rebooting. In the past you could use ifup/ifdown, /etc/init.d/networking restart, service networking restart, and the systemd methods, like systemctl restart networking, systemctl restart Network-Manager.service etc, but none of these were possible for me after installing Ubuntu 18.04.
    – jdgregson
    May 3 at 22:05










  • What is the result of: sudo ip link set eth0 down followed by: sudo ifup -v eth0 Of course, substitute your interface for the mythical eth0.
    – chili555
    May 3 at 23:01











  • ifupdown is not installed by default, so when you call ifup it just tells you how to install it. However, sudo ip link set eth0 down followed by sudo ip link set eth0 up does turn the interface off and back on.
    – jdgregson
    May 3 at 23:27











  • Awesome! So you are solved and all set?
    – chili555
    May 3 at 23:46










  • Careful, not all *.yaml files are related to netplan, so only remove those in netplan-related directories!
    – JanC
    May 5 at 19:33












up vote
0
down vote










up vote
0
down vote









According to this answer, the solution is to remove all operational .yaml files: Ubuntu 17.10 disable netplan



I wouldn’t remove anything without backing up. We can do so easily by simply moving the files aside. First, locate the files:



sudo updatedb
locate netplan | grep yaml


On my 18.04 system, it appears that the only operational file is /etc/netplan/01-network-manager-all.yaml. Let’s move it:



mkdir ~/netplan
sudo mv /etc/netplan/01-network-manager-all.yaml /home/user/netplan


...where user is your user name.



Now check to make sure the file is truly gone:



ls /etc/netplan


Now make your additions to /etc/network/interfaces as required.



Reboot.



Any improvement?



Footnote: The exact process to do this is hard to find. We may need to refine a bit as we go.






share|improve this answer












According to this answer, the solution is to remove all operational .yaml files: Ubuntu 17.10 disable netplan



I wouldn’t remove anything without backing up. We can do so easily by simply moving the files aside. First, locate the files:



sudo updatedb
locate netplan | grep yaml


On my 18.04 system, it appears that the only operational file is /etc/netplan/01-network-manager-all.yaml. Let’s move it:



mkdir ~/netplan
sudo mv /etc/netplan/01-network-manager-all.yaml /home/user/netplan


...where user is your user name.



Now check to make sure the file is truly gone:



ls /etc/netplan


Now make your additions to /etc/network/interfaces as required.



Reboot.



Any improvement?



Footnote: The exact process to do this is hard to find. We may need to refine a bit as we go.







share|improve this answer












share|improve this answer



share|improve this answer










answered May 3 at 21:07









chili555

36.4k54776




36.4k54776











  • I'll have to try that and see how it goes. The only other question would be how to apply the changes without rebooting. In the past you could use ifup/ifdown, /etc/init.d/networking restart, service networking restart, and the systemd methods, like systemctl restart networking, systemctl restart Network-Manager.service etc, but none of these were possible for me after installing Ubuntu 18.04.
    – jdgregson
    May 3 at 22:05










  • What is the result of: sudo ip link set eth0 down followed by: sudo ifup -v eth0 Of course, substitute your interface for the mythical eth0.
    – chili555
    May 3 at 23:01











  • ifupdown is not installed by default, so when you call ifup it just tells you how to install it. However, sudo ip link set eth0 down followed by sudo ip link set eth0 up does turn the interface off and back on.
    – jdgregson
    May 3 at 23:27











  • Awesome! So you are solved and all set?
    – chili555
    May 3 at 23:46










  • Careful, not all *.yaml files are related to netplan, so only remove those in netplan-related directories!
    – JanC
    May 5 at 19:33
















  • I'll have to try that and see how it goes. The only other question would be how to apply the changes without rebooting. In the past you could use ifup/ifdown, /etc/init.d/networking restart, service networking restart, and the systemd methods, like systemctl restart networking, systemctl restart Network-Manager.service etc, but none of these were possible for me after installing Ubuntu 18.04.
    – jdgregson
    May 3 at 22:05










  • What is the result of: sudo ip link set eth0 down followed by: sudo ifup -v eth0 Of course, substitute your interface for the mythical eth0.
    – chili555
    May 3 at 23:01











  • ifupdown is not installed by default, so when you call ifup it just tells you how to install it. However, sudo ip link set eth0 down followed by sudo ip link set eth0 up does turn the interface off and back on.
    – jdgregson
    May 3 at 23:27











  • Awesome! So you are solved and all set?
    – chili555
    May 3 at 23:46










  • Careful, not all *.yaml files are related to netplan, so only remove those in netplan-related directories!
    – JanC
    May 5 at 19:33















I'll have to try that and see how it goes. The only other question would be how to apply the changes without rebooting. In the past you could use ifup/ifdown, /etc/init.d/networking restart, service networking restart, and the systemd methods, like systemctl restart networking, systemctl restart Network-Manager.service etc, but none of these were possible for me after installing Ubuntu 18.04.
– jdgregson
May 3 at 22:05




I'll have to try that and see how it goes. The only other question would be how to apply the changes without rebooting. In the past you could use ifup/ifdown, /etc/init.d/networking restart, service networking restart, and the systemd methods, like systemctl restart networking, systemctl restart Network-Manager.service etc, but none of these were possible for me after installing Ubuntu 18.04.
– jdgregson
May 3 at 22:05












What is the result of: sudo ip link set eth0 down followed by: sudo ifup -v eth0 Of course, substitute your interface for the mythical eth0.
– chili555
May 3 at 23:01





What is the result of: sudo ip link set eth0 down followed by: sudo ifup -v eth0 Of course, substitute your interface for the mythical eth0.
– chili555
May 3 at 23:01













ifupdown is not installed by default, so when you call ifup it just tells you how to install it. However, sudo ip link set eth0 down followed by sudo ip link set eth0 up does turn the interface off and back on.
– jdgregson
May 3 at 23:27





ifupdown is not installed by default, so when you call ifup it just tells you how to install it. However, sudo ip link set eth0 down followed by sudo ip link set eth0 up does turn the interface off and back on.
– jdgregson
May 3 at 23:27













Awesome! So you are solved and all set?
– chili555
May 3 at 23:46




Awesome! So you are solved and all set?
– chili555
May 3 at 23:46












Careful, not all *.yaml files are related to netplan, so only remove those in netplan-related directories!
– JanC
May 5 at 19:33




Careful, not all *.yaml files are related to netplan, so only remove those in netplan-related directories!
– JanC
May 5 at 19:33












 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1031709%2fubuntu-18-04-switch-back-to-etc-network-interfaces%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

pylint3 and pip3 broken

Missing snmpget and snmpwalk

How to enroll fingerprints to Ubuntu 17.10 with VFS491