How come all other distros see eth0 and slack eth1 for the dsl modem/router
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How come all other distros see eth0 and slack eth1 for the dsl modem/router
The story is: Due to an M/B failure, I had to replace the entire system(holding 3 linux distros). Two of them had serious corruption(superblock fot found), but one of them (Slack 12) I was able to recover. DSL however did not. I also installed Open Suse and again, no DSL. However, Slack's ifconfig detects and eth1 , but no eth0, while Open Suse 11.1 detects and eth0, no eth1.
Here is for Slack:
ifconfig -a
eth1 Link encap:Ethernet HWaddr 00:19:66:99:04:F8
inet addr:192.168.1.2 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::219:66ff:fe99:4f8/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:4294967279 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)
Interrupt:17 Base address:0xc000
I then tried an Ubuntu CD(ran it from the live cd without installing and the DSL worked like a charm. It also reports eth0, not eth1
In fact I also took the resolv.conf from there and now OpenSuse also worked. But Slack still refuses, though the resolv.conf and rc.inet1.conf are the same as Ubuntu.
I suspect the problem is the eth0 vs eth1? I don't think there are two interfaces, so probably Slack, which was built for the old M/B is confused here. The question is how do I fix that
This happens when you change network adapters, without modifying your network programs. udev is reserving eth0 for the original network adapter, so your new one gets eth1. The above solution works fine.
Regards,
Bill
This happens when you change network adapters, without modifying your network programs. udev is reserving eth0 for the original network adapter, so your new one gets eth1. The above solution works fine.
Regards,
Bill
Yup, Alien Bob covered this in a post a few days back.
I looked at the post mentioned, but still no success:
Briefly, I have an Open Suse that works and a Slack that does not ON THE SAME machine. So, what would be simpler than just copying the config files?
Let's see:
udev: There is no difference in the persistent-net.rules file(because I copied the one from suse to the slack one)
bash-3.1# diff 70-persistent-net.rules /mnt/root/etc/udev/rules.d/70-persistent-net.rules
bash-3.1#
cat 70-persistent-net.rules
# This file was automatically generated by the /lib/udev/write_net_rules
# program run by the persistent-net-generator.rules rules file.
#
# You can modify it,as long as you keep each rule on a single line.
# PCI device 0x10ec:0x8136 (r8169)
# This file was automatically generated by the /lib/udev/write_net_rules
# program run by the persistent-net-generator.rules rules file.
#
# You can modify it,as long as you keep each rule on a single line.
# PCI device 0x10ec:0x8136 (r8169)
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="00:19:66:99:04:f8", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:19:66:99:04:F8
inet addr:192.168.1.6 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::219:66ff:fe99:4f8/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:4294967257 overruns:0 frame:0
TX packets:0 errors:0 dropped:6 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Interrupt:17 Base address:0x8000
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:16436 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:0
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
--------------------
for completeness, here is rc.inet1.conf from Slack(Suse uses xinetd and I forgot where the relevant files are, but this file looks ok):
# /etc/rc.d/rc.inet1.conf
#
# This file contains the configuration settings for network interfaces.
# If USE_DHCP[interface] is set to "yes", this overrides any other settings.
# If you don't have an interface, leave the settings null ("").
# You can configure network interfaces other than eth0,eth1... by setting
# IFNAME[interface] to the interface's name. If IFNAME[interface] is unset
# or empty, it is assumed you're configuring eth<interface>.
# Several other parameters are available, the end of this file contains a
# comprehensive set of examples.
# Config information for eth0:
IPADDR[0]="192.168.1.6"
NETMASK[0]="255.255.255.0"
USE_DHCP[0]=""
DHCP_HOSTNAME[0]=""
# Config information for eth1:
IPADDR[1]=""
NETMASK[1]=""
USE_DHCP[1]=""
DHCP_HOSTNAME[1]=""
# Config information for eth2:
IPADDR[2]=""
NETMASK[2]=""
USE_DHCP[2]=""
DHCP_HOSTNAME[2]=""
# Config information for eth3:
IPADDR[3]=""
NETMASK[3]=""
USE_DHCP[3]=""
DHCP_HOSTNAME[3]=""
# Default gateway IP address:
GATEWAY="192.168.1.1"
# Change this to "yes" for debugging output to stdout. Unfortunately,
# /sbin/hotplug seems to disable stdout so you'll only see debugging output
# when rc.inet1 is called directly.
DEBUG_ETH_UP="no"
## Example config information for wlan0. Uncomment the lines you need and fill
## in your info. (You may not need all of these for your wireless network)
#IFNAME[4]="wlan0"
#IPADDR[4]=""
#NETMASK[4]=""
#USE_DHCP[4]="yes"
#DHCP_HOSTNAME[4]="icculus-wireless"
#DHCP_KEEPRESOLV[4]="yes"
#DHCP_KEEPNTP[4]="yes"
#DHCP_KEEPGW[4]="yes"
#DHCP_IPADDR[4]=""
#WLAN_ESSID[4]=BARRIER05
#WLAN_MODE[4]=Managed
##WLAN_RATE[4]="54M auto"
##WLAN_CHANNEL[4]="auto"
##WLAN_KEY[4]="D5AD1F04ACF048EC2D0B1C80C7"
##WLAN_IWPRIV[4]="AuthMode=WPAPSK EncrypType=TKIP WPAPSK=7B1ABEEB5D197741923ED26727569C365E31212096A0EAFAD563B268BAD01CAF TxRate=0"
#WLAN_WPA[4]="wpa_supplicant"
#WLAN_WPADRIVER[4]="ndiswrapper"
## Some examples of additional network parameters that you can use.
## Config information for wlan0:
#IFNAME[4]="wlan0" # Use a different interface name nstead of
# the default 'eth4'
#HWADDR[4]="00:01:23:45:67:89" # Overrule the card's hardware MAC address
#MTU[4]="" # The default MTU is 1500, but you might need
# 1360 when you use NAT'ed IPSec traffic.
#DHCP_KEEPRESOLV[4]="yes" # If you dont want /etc/resolv.conf overwritten
#DHCP_KEEPNTP[4]="yes" # If you don't want ntp.conf overwritten
#DHCP_KEEPGW[4]="yes" # If you don't want the DHCP server to change
# your default gateway
#DHCP_IPADDR[4]="" # Request a specific IP address from the DHCP
# server
#WLAN_ESSID[4]=DARKSTAR # Here, you can override _any_ parameter
# defined in rc.wireless.conf, by prepending
# 'WLAN_' to the parameter's name. Useful for
# those with multiple wireless interfaces.
#WLAN_IWPRIV[4]="AuthMode=WPAPSK EncrypType=TKIP WPAPSK=thekey TxRate=0"
# Some drivers require a private ioctl to be
# set through the iwpriv command. If more than
# one is required, you can place them in the
# IWPRIV parameter (space-separated, see the
# example).
Looking at your last post, it seems that you have the nic identified as eth0, so that problem looks sorted.
I notice that resolv.conf, which you copied from SUSE, seems to list your router as the nameserver. This has never worked for me with Slackware. Probaly some additional config voodoo required. Instead, try explicitly stating the nameserver your ISP has given you in resolv.conf. You can find this listed often on the configuration page for your router (point a browser to your default gateway - at least in my case, YMMV) or you can use 4.2.2.1 and 4.2.2.2 as the nameserver:
I did change the resolv.conf(I have no idea why Suse can do without it though and it would be nice to understand this), so it reads
nameserver 195.170.0.1
nameserver 195.170.2.2
(which are the correct ones), but it still has the same problem. I can ping to the ip address, but not the router(default gw) address. Again, no idea why this is so and why this is not a problem for Suse.
I cannot ping(connction timed out)
192.168.1.1
which according to rc.inet1.conf is the
Default gateway IP address:
GATEWAY="192.168.1.1"
I can ping eth0:192.168.1.6
I will try the route and netstat commands. I am not sure which configuration files set the
relevant parameters(if I did, I could copy them over from the Suse installation, which works fine)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.