Unable to get ifup & ifdown to bring up eth0 | Ubuntu 14.04
30,101
Please try '=false' and restart Network Manager:
sudo service network-manager restart
Your interfaces
file looks a bit busy; I'd amend it to:
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 192.168.1.101
netmask 255.255.255.0
gateway 192.168.1.1
dns-nameservers 192.168.1.1 8.8.8.8
dns-domain example.com
dns-search example.com
Then try again:
sudo ifdown eth0 && sudo ifup -v eth0
Did you connect?
ping -c3 www.ubuntu.com
Related videos on Youtube
Author by
Autoresponder
Updated on September 18, 2022Comments
-
Autoresponder over 1 year
I'm trying to set up a static IP on a dual boot laptop ( Win10 and Ubuntu Studio 14.04). These are the settings:
sudo nano /etc/network/interfaces:
# interfaces(5) file used by ifup(8) and ifdown(8) auto lo iface lo inet loopback auto eth0 iface eth0 inet static address 192.168.1.101 netmask 255.255.255.0 network 192.168.1.0 broadcast 192.168.1.255 gateway 192.168.1.1 dns-nameservers 192.168.1.1 8.8.8.8 dns-domain example.com dns-search example.com
sudo nano /etc/NetworkManager/NetworkManager.conf:
/etc/NetworkManager/NetworkManager.conf [main] plugins=ifupdown,keyfile,ofono #dns=dnsmasq no-auto-default=54:04:A6:25:64:2E, [ifupdown] managed=true
(there is a line space above and below "no-auto--")
The ifconfig returns the below:
eth0 Link encap:Ethernet HWaddr 54:04:a6:25:64:2e inet addr:192.168.1.101 Bcast:192.168.1.255 Mask:255.255.255.0 UP BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:312 errors:0 dropped:0 overruns:0 frame:0 TX packets:312 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1 RX bytes:29521 (29.5 KB) TX bytes:29521 (29.5 KB) wlan0 Link encap:Ethernet HWaddr 78:92:9c:45:05:ae inet addr:192.168.43.110 Bcast:192.168.43.255 Mask:255.255.255.0 inet6 addr: fe80::7a92:9cff:fe45:5ae/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:2631 errors:0 dropped:0 overruns:0 frame:0 TX packets:2507 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:1816247 (1.8 MB) TX bytes:375757 (375.7 KB)
sudo ifdown eth0 returns
`RTNETLINK answers: No such process
Any advice from pros what I should try to get it right? The targetted configuration is : eth0 up / internet connectivity while eth0 is up. I can post router and gui network manager settings.
sudo ifup eth0 elicits this response:
`RTNETLINK answers: File exists Failed to bring up eth0.`
-
Autoresponder over 7 yearsTried with both 'true' and 'false' - there's no connectivity - i need eth0 up and connecting to the net.
-
Autoresponder over 7 yearsI de-indented the interfaces file, thanks. And No. The console had this to say : when I ran the second command :** ifdown: interface eth0 not configured Configuring interface eth0=eth0 (inet) run-parts --verbose /etc/network/if-pre-up.d run-parts: executing /etc/network/if-pre-up.d/wireless-tools run-parts: executing /etc/network/if-pre-up.d/wpasupplicant ip addr add 192.168.1.101/255.255.255.0 broadcast 192.168.1.255 dev eth0 label eth0 ip link set dev eth0 up ip route add default via 192.168.1.1 dev eth0 RTNETLINK answers: File exists Failed to bring up eth0.**
-
chili555 over 7 yearsAre there any clues in the log?
cat /var/log/syslog | grep eth0
? As the result may be lengthy, paste the result here and give us the link: paste.ubuntu.com What is the ethernet driver? Find it fromsudo lshw -C network
driver=?? -
Autoresponder over 7 yearsSorry I took awhile- had to boot back into windows after commands on the other OS. The 'networks' graphical symbol has completely vanished from the top menu. The pastebin is here: paste.ubuntu.com/23673821
-
chili555 over 7 yearsAhhh! The infamous
r8169
! Please try:sudo ethtool -s eth0 autoneg off speed 100
and then:sudo ifdown eth0 && sudo ifup -v eth0
Any change? -
Autoresponder over 7 yearsthanks for pointing out the r8169 driver part. (It wasn't easy with zilch connectivity). I downloaded stuff via windows and rebooted into ubuntu to config. The new driver shows up, but still no internet. Pastebin here, appreciate any further advice on whatever cranking I need to do to get eth0 up and running with access to internet.paste.ubuntu.com/23677673 have a great holiday season!
-
chili555 over 7 yearsYour
eth0
appears to be connected; it has the requested IP address. May I assume that you've carefully checked the numbers? 192.168.1.1; not x.0.1, etc.? Can you ping the gateway?ping -c3 192.168.1.1
If so, how about:ping -c3 8.8.8.8
? With the newer driver, may we see:sudo ifdown eth0 && sudo ifup -v eth0
and:sudo ethtool eth0
paste.ubuntu.com please. -
Autoresponder over 7 yearspaste.ubuntu.com/23677963 I'm risking moderator attention by ignoring the "avoid extended discussions.." warning - it isn't feasible to move to chat because I'd have to reboot between OS's to find the data you want to de-geek while you're waiting! Thanks for taking the trouble! Did I mess up in router settings- I've port-forwarded (http to port 80) to the eth0 IP?
-
chili555 over 7 yearsSee in the paste it says "Link detected: no"? I still think you'll have to:
sudo ethtool -s eth0 autoneg off speed 100
to see a link. Check:sudo ethtool eth0
We can automate the autoneg and speed if it works as I expect.