LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Canīt connect to our network with Linux (https://www.linuxquestions.org/questions/linux-networking-3/can%B4t-connect-to-our-network-with-linux-20470/)

junkhead 05-08-2002 03:36 AM

Canīt connect to our network with Linux
 
Hey everyone

I have tried installing several linux distributions ( RedHat 7.0, 7.1, 7.2 , Slackware 8, Debian 2.25, Mandrake 8.0 and 8.1) and have not been able to contact the local area network. When I then pinged the local host (127.0.0.1) on my pc Iīve got a positive response and the same when I pinged my own IP address, then it seemed like my network was running. Then I tried to ping our gateway and some of my friends, but couldnīt get in contact with them (no contact to extern IP addresses.) I have an Accton EN1207D-TX ethernet card (with a RealTek 8129/8139 chip) and at every installation it seemed like the networkcard was succesfully installed, when checking the loaded modules/drivers with lsmod. Between this pc and the gateway we have a hub.

Iīve never experienced these problems with win2k networking on my pc, but it became more mysterious as I tried installing FreeBSD 4.5 and experienced no problems connecting to the local area network (gateway) and setting up my internet connection. I thought that it could be a software thing like a firewall that prohibits the network connection, but since I always deselect this feature during installation /setup this doesnīt seem obvious. I seek an explanation for this behaviour. Can anyone help me or just give me a good idea of why ?????

DMR 05-08-2002 05:49 PM

Since you've tried so many distros (and it sounds as though your hardware is functioning, module is loading, etc.), I can only think that you might be consistently missing some key part of your network config.
Could you post more information, please:

-What is the gateway device?
-What other machines are on the network?
-What is the IP addressing scheme for the machines?
-What distro is currently running on the Linux box?
-Post the output of the ifconfig command.
-Post the contents of /etc/sysconfig/network and /etc/sysconfig/network-scripts/ifcfg-eth0 (the name and location of these files may differ between distros).

junkhead 05-12-2002 10:54 AM

Sorry, for the delayed response...
Right now I dualboot with slackware w. 2.2.19 kernel/windows because of the problem.
Due to the localnetwork construction I donīt know the type of gateway, the rest of the machines are windows machines running static ip settings.


Ifconfig output:

eth0 Link encap:Ethernet HWaddr 00:00:E8:8E:CA:D5
inet addr:172.17.22.23 Bcast:172.17.22.255 Mask:255.255.255.0
UP BROADCAST RUNNING 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:100
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Interrupt:5 Base address:0x9c00

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:3924 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)

Today I had a friend looking at the problem, but he neither couldnt locate the bug, but we detected that ifconfig didnt register the eth0 pinging packages as received, but ping command tells that it can connect to my ip (eth0). Only txqueuelen: ** number grows.
Is it standard to use IRQ 5 for the ethernetcard ?



selected line from dmesg output

rtl8139.c:v1.07 5/6/99 Donald Becker http://cesdis.gsfc.nasa.gov/linux/drivers/rtl8139.html
eth0: SMC1211TX EZCard 10/100 (RealTek RTL8139) at 0x9c00, IRQ 5, 00:00:e8:8e:ca:d5.

end


full rc.inet1 file:

#! /bin/sh
#
# rc.inet1 This shell script boots up the base INET system.
#
# Version: @(#)/etc/rc.d/rc.inet1 2.00 10/06/1999
#

HOSTNAME=`cat /etc/HOSTNAME`

# Attach the loopback device.
/sbin/ifconfig lo 127.0.0.1
/sbin/route add -net 127.0.0.0 netmask 255.0.0.0 lo

# IF YOU HAVE AN ETHERNET CONNECTION, use these lines below to configure the


# eth0 interface.

# Edit these values to set up a static IP address:
IPADDR="172.17.22.23" # REPLACE with YOUR IP address!
NETMASK="255.255.255.0" # REPLACE with YOUR netmask!
NETWORK="172.17.22.0" # REPLACE with YOUR network address!
BROADCAST="172.17.22.255" # REPLACE with YOUR broadcast address, if you
# have one. If not, leave blank and edit below.
GATEWAY="172.17.22.1" # REPLACE with YOUR gateway address!

# To use DHCP instead of a static IP, set this value to "yes":
DHCP="no" # Use DHCP ("yes" or "no")

# OK, time to set up the interface:
if [ "$DHCP" = "yes" ]; then # use DHCP to set everything up:
echo "Attempting to configure eth0 by contacting a DHCP server..."
/sbin/dhcpcd
elif [ ! "$IPADDR" = "127.0.0.1" ]; then # set up IP statically:
# Set up the ethernet card:
echo "Configuring eth0 as ${IPADDR}..."
/sbin/ifconfig eth0 ${IPADDR} broadcast ${BROADCAST} netmask ${NETMASK}

# If that didn't succeed, give the system administrator some hints:
if [ ! $? = 0 ]; then
cat << EOF
Your ethernet card was not initialized properly. Here are some reasons why this
may have happened, and the solutions:
1. Your kernel does not contain support for your card. Including all the
network drivers in a Linux kernel can make it too large to even boot, and
sometimes including extra drivers can cause system hangs. To support your
ethernet, either edit /etc/rc.d/rc.modules to load the support at boottime,
or compile and install a kernel that contains support.
2. You don't have an ethernet card, in which case you should comment out this
section of /etc/rc.d/rc.inet1. (Unless you don't mind seeing this error...)
EOF
fi

# Older kernel versions need this to set up the eth0 routing table:
KVERSION=`uname -r | cut -f 1,2 -d .`
if [ "$KVERSION" = "1.0" -o "$KVERSION" = "1.1" \
-o "$KVERSION" = "1.2" -o "$KVERSION" = "2.0" -o "$KVERSION" = "" ]; then
/sbin/route add -net ${NETWORK} netmask ${NETMASK} eth0
fi

# If there is a gateway defined, then set it up:
if [ ! "$GATEWAY" = "" ]; then
/sbin/route add default gw ${GATEWAY} netmask 0.0.0.0 metric 1
fi
fi

# End of rc.inet1


rc.inet2 selected (without most outcommented tekst)

IPV4_FORWARD=0
if [ -f /proc/sys/net/ipv4/ip_forward ]; then
if [ "$IPV4_FORWARD" = "1" ]; then
echo "Activating IPv4 packet forwarding."
echo 1 > /proc/sys/net/ipv4/ip_forward
else
echo "Disabling IPv4 packet forwarding."
echo 0 > /proc/sys/net/ipv4/ip_forward
fi
fi


if [ -x /sbin/rpc.portmap ]; then
echo "Starting RPC portmapper: /sbin/rpc.portmap"
/sbin/rpc.portmap


if [ -x /usr/sbin/syslogd ]; then
echo -n "Starting sysklogd daemons: "
echo -n " /usr/sbin/syslogd"
/usr/sbin/syslogd
sleep 1 # prevent syslogd/klogd race condition on SMP kernels
echo " /usr/sbin/klogd -c 3"
# '-c 3' = display level 'error' or higher messages on console
/usr/sbin/klogd -c 3
fi
# Done starting the syslogd and klogd daemons.

# Start the inetd server:
if [ -x /usr/sbin/inetd ]; then
echo "Starting Internet super-server daemon: /usr/sbin/inetd"
/usr/sbin/inetd
else
echo "WARNING: /usr/sbin/inetd not found."
fi
# Done starting the inetd meta-server.

# Start the OpenSSH SSH daemon:
if [ -x /etc/rc.d/rc.sshd ]; then # always default to this, if available
echo "Starting OpenSSH SSH daemon: /usr/sbin/sshd"
/etc/rc.d/rc.sshd start
elif [ -x /usr/local/sbin/sshd -a ! -e /etc/rc.d/rc.sshd ]; then
echo "Starting OpenSSH SSH daemon: /usr/local/sbin/sshd"
/usr/local/sbin/sshd
elif [ -x /usr/sbin/sshd -a ! -e /etc/rc.d/rc.sshd ]; then
echo "Starting OpenSSH SSH daemon: /usr/sbin/sshd"
/usr/sbin/sshd


All times are GMT -5. The time now is 02:01 AM.