Gentoo Archives: gentoo-ppc-dev

From: Marc Ozon <gentoo@×××××××××××××××××××××.org>
To: gentoo-ppc-dev@g.o
Subject: Re: [gentoo-ppc-dev] Suggestions for net rc scripts
Date: Mon, 06 Oct 2003 20:54:48
Message-Id: 20031006205447.GA17560@utoronto.ca
1 Re. Wendell's suggested modifications for the net startup scripts: This is
2 a good idea, and the suggested script is a bit more complete than the one
3 suggested here:
4
5 http://bugs.gentoo.org/show_bug.cgi?id=25742
6 (earlier version at http://bugs.gentoo.org/show_bug.cgi?id=16649)
7
8 That being done, the Gentoo net configuration still lacks something I wish
9 it had: a way to handle multiple sets of networking settings, as the
10 'location' setting in OS X does. As it is, I use multiple runlevels
11 (similar to what's described at http://www.desertsol.com/~kevin/ppc/#network),
12 and a simple shell script to switch locations. Doing this, I have a way to
13 issue the appropriate iwconfig commands for each location: I put them in my
14 runlevel-switching shell script.
15
16 This makes me wonder: since we're thinking about messing with the net.ethX
17 script, could multiple locations be included somehow? If so, how might this
18 be done?
19
20 In thinking about this, it seems it's still best to use multiple runlevels
21 for different 'locations', but it would be nice if I didn't need a separate
22 script to handle it. What I have in mind is something like this: in
23 /etc/conf.d/net, there could be, e.g., 'multiple_locations=yes', which would
24 trigger multiple location support in net.ethX. If there are multiple
25 locations, /etc/conf.d/net could include settings like
26 'wirelessessid_eth1_home="abc"' and 'wirelessessid_eth1_work="def"', etc.;
27 then, the net.ethX script might parse that, and apply the appropriate
28 settings for whatever runlevel (i.e., location) is active, which it could
29 read from /var/lib/init.d/softlevel. The result would be that switching
30 runlevels would result in switching network settings, too. This would add
31 significantly to the complexity of net.ethX, but enough of us might need
32 multiple location support that the added complexity would be worth it.
33
34 What do you think? Would this be a good idea? Is there a better way?
35
36 Cheers,
37 Marc
38
39
40 --- Wendell Thomas Duncan <wendell@××××××××.com> [2003-10-03, 11:04]:
41 > If these patch suggestions look good, could a developer forward these
42 >patch ideas for the net.eth0 rc-scripts to the right person.
43 >
44 > I just got a new 802.11g base station. I could not see a good way to
45 >get the iwconfig commands executed as part of the /ete/init.d/net.eth1
46 >scripts. Maybe I missed a good tool somewhere, but it makes a lot of
47 >sense to do this stuff in the net.eth0 rc-scripts. These scripts are
48 >part of the baselayout ebuild.
49
50 [script stuff snipped]
51
52 --
53 Marc Ozon Toronto, Ontario, Canada
54
55
56 --
57 gentoo-ppc-dev@g.o mailing list

Replies

Subject Author
Re: [gentoo-ppc-dev] Suggestions for net rc scripts Luca Barbato <lu_zero@g.o>