Gentoo Logo
Gentoo Spaceship




Note: Due to technical difficulties, the Archives are currently not up to date. GMANE provides an alternative service for most mailing lists.
c.f. bug 424647
List Archive: gentoo-laptop
Navigation:
Lists: gentoo-laptop: < Prev By Thread Next > < Prev By Date Next >
Headers:
To: gentoo-laptop@g.o
From: Henrik Brix Andersen <brix@g.o>
Subject: Re: Abort network startup when cable not connected
Date: Wed, 18 May 2005 11:30:02 +0200
On Tue, 2005-05-17 at 18:12 -0400, Zander Z365 wrote:
> How can I configure the startup script so that networking will not be
> started if the cable is not connected?

I have the following preup() function in my /etc/conf.d/net file:

preup() {
    case ${IFACE} in
        eth0)
            ebegin "Checking link on ${IFACE}"
            mii-tool ${IFACE} 2> /dev/null | grep -q 'link ok'
            eend $?
            ;;

        *)
            ;;
    esac
}

Note: this is for use with baselayout-1.11.x.

Sincerely,
Brix
-- 
Henrik Brix Andersen <brix@g.o>
Gentoo Linux
Attachment:
signature.asc (This is a digitally signed message part)
References:
Abort network startup when cable not connected
-- Zander Z365
Navigation:
Lists: gentoo-laptop: < Prev By Thread Next > < Prev By Date Next >
Previous by thread:
Re: Abort network startup when cable not connected
Next by thread:
can't patch the kernel to swsusp2
Previous by date:
Re: Abort network startup when cable not connected
Next by date:
Re: swsusp2 *hang* :(


Updated Jun 17, 2009

Summary: Archive of the gentoo-laptop mailing list.

Donate to support our development efforts.

Copyright 2001-2013 Gentoo Foundation, Inc. Questions, Comments? Contact us.