Re: Troubleshooting connection loss (novice question)



On Wed, 31 Oct 2007 01:01:10 GMT, Allen Weiner wrote:

I posted to this thread my output yesterday in a rush.

Dang, I'll have to google for it. I missed it.

Bit Twister: Your script dump_net.txt Ver 3.4 appears to have some
problems with respect to Fedora. I'd like to repair my copy of it. I
have zero experience with bash scripting.


http://tldp.org/LDP/abs/html/index.html


1. The script is intended to post
/etc/sysconfig/networks-scripts/ifdown.d and ifup.d.

Had you read the top of the script, you may have noticed it was to run
on several different Linux OSs.

Those directories exists on Mandriva.

Are you looking for /etc/sysconfig/network-scripts/ifdown-eth and ifup-eth?

Nope. Some users put their own code/script there and I wanted contents
of directories if existed. See

# ls -al /etc/sysconfig/network-scripts/ifdown.d
total 12
drwxr-xr-x 2 root root 4096 2007-10-09 11:59 .
drwxr-xr-x 8 root root 4096 2007-10-09 12:26 ..
-rwxr-xr-x 1 root root 224 2007-10-03 16:49 vpn

Here is new/improved/untested code.

if [ -d /etc/sysconfig/network-scripts ] ; then
for _d in "ifdown.d" "ifup.d" ; do
if [ -e /etc/sysconfig/network-scripts/${_d} ] ; then
_cmd="cd /etc/sysconfig/network-scripts/${_d} ; ls -al "
echo "===== $_cmd ====" >> $_out_fn
cd /etc/sysconfig/network-scripts/${_d}
ls -al >> $_out_fn
fi
done
fi



2. The output of mii-tool was truncated.

Hmmm, must work different on Fedora. On Mandriva

# mii-tool -v eth0
eth0: no autonegotiation, 100baseTx-FD, link ok
product info: vendor 00:c0:b4, model 0 rev 8
basic mode: autonegotiation enabled
basic status: autonegotiation complete, link ok
capabilities: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD
advertising: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD
link partner: 100baseTx-FD 100baseTx-HD 10baseT-FD 10baseT-HD flow-control


Then the script dumped dmesg without printing the comment line.

Might try changing it to

echo "======== dmesg | grep eth$nic ==========" >> $_out_fn

It also appears that possibly the dmesg contents were dumped more
than once. (There was an enormous amount of output)

It would look repeating because it was to get
eth0, eth1, eth2 and look something like

========== dmesg | grep eth0 =================
eth0: Lite-On 82c168 PNIC rev 32 at Port 0xdf00, 00:A0:CC:21:B8:91, IRQ 19.
eth0: Setting full-duplex based on MII#1 link partner capability of 05e1.
eth0: no IPv6 routers present

========== dmesg | grep eth1 =================
eth1: RealTek RTL8139 at 0xf8826000, 00:16:17:57:66:54, IRQ 19
eth1: Identified 8139 chip type 'RTL-8100B/8139D'

Guess I'll have to get back into the script and try to figure out how to exit
loop if there is not an eth1 or eth2.

3. Ethtool is installed on my system. The script source invokes ethtool.
There was no ethtool output in the results.

Maybe an argument problem. I know ethtool does not work on my linksys nic
.



Relevant Pages

  • speed up my LAN
    ... mii-tool -l -w eth0 ... Sep 25 01:09:01 dave kernel: eth1: Link changed: ... basic mode: autonegotiation enabled ... basic status: autonegotiation complete, link ok ...
    (comp.os.linux.networking)
  • Re: Problem with bonded (teaming) NICs on RHEL 4.0
    ... I think mii-tool has a problem with GIG speeds. ... When you run mii-tool for eth0 and eth1 it does not show that. ...
    (RedHat)
  • Re: 2.4.21, NFS v3, and 3com 920
    ... > You should be able to use mii-tool, or ethtool (one or both should ... eth0: negotiated 100baseTx-FD, link ok ... basic mode: autonegotiation enabled ... basic status: autonegotiation complete, link ok ...
    (Linux-Kernel)
  • Re: setting-up a dmz
    ... Not provide any actual log messages? ... No shorewall, i prefer a own debian iptables firewall:) ... eth1: link up, 10Mbps, half-duplex, lpa 0x0000 ... ADDRCONF: eth0: link is not ready ...
    (Debian-User)
  • Kernel upgrade 2.4.18-14 -> 2.4.23 (rh8)
    ... I just recompiled a new kernel, ... eth0: Broadcom BCM5701 Integrated Copper transceiver found ... eth1: Broadcom BCM5701 Integrated Copper transceiver found ... Dec 5 10:07:55 network: Setting network parameters: succeeded ...
    (RedHat)