1 |
Have you taken a look at /etc/conf.d/net.example around line 700? |
2 |
|
3 |
To quote: |
4 |
|
5 |
############################################################################## |
6 |
# ADVANCED CONFIGURATION |
7 |
# |
8 |
# Four functions can be defined which will be called surrounding the |
9 |
# start/stop operations. The functions are called with the interface |
10 |
# name first so that one function can control multiple adapters. An extra |
11 |
two |
12 |
# functions can be defined when an interface fails to start or stop. |
13 |
# |
14 |
# The return values for the preup and predown functions should be 0 |
15 |
# (success) to indicate that configuration or deconfiguration of the |
16 |
|
17 |
|
18 |
|
19 |
so just write yourself a preup function that sets the correct ethtool |
20 |
setting on your adapter before brining it up. This is very likely the |
21 |
correct way of doing it in Gentoo. |
22 |
|
23 |
preup() { |
24 |
if ethtool -s ${IFACE} duplex full; then |
25 |
return 0 |
26 |
fi |
27 |
ewarn "Couldn't set ${IFACE} to full duplex" |
28 |
return 1 |
29 |
} |
30 |
|
31 |
|
32 |
|
33 |
On 9/7/07, A. Khattri <ajai@××××.net> wrote: |
34 |
> |
35 |
> On Fri, 7 Sep 2007, Jared Klett wrote: |
36 |
> |
37 |
> > In the past I've used ethtool with great results. For example: |
38 |
> > |
39 |
> > ethtool -s duplex full eth0 |
40 |
> |
41 |
> I was hoping there would be a standard way to do this at boot time |
42 |
> without hackign together a "local" script? |
43 |
> |
44 |
> |
45 |
> > |
46 |
> > On 9/7/07, A. Khattri <ajai@××××.net> wrote: |
47 |
> >> |
48 |
> >> I Googled for this but found nothing useful. After a power outage in |
49 |
> our |
50 |
> >> data center one of my Gentoo servers failed to startup networking |
51 |
> >> correctly. It looks like the NIC failed to autonegotiate a full-duplex |
52 |
> >> connection to the switch and subsequently eth0 failed to come up |
53 |
> properly. |
54 |
> >> |
55 |
> >> What is the preferred way to tell Gentoo to force full duplex on all |
56 |
> NICs? |
57 |
> >> |
58 |
> >> |
59 |
> >> -- |
60 |
> >> A |
61 |
> >> -- |
62 |
> >> gentoo-server@g.o mailing list |
63 |
> >> |
64 |
> >> |
65 |
> > |
66 |
> |
67 |
> -- |
68 |
> A |
69 |
> -- |
70 |
> gentoo-server@g.o mailing list |
71 |
> |
72 |
> |