one network-card with 2 different configurations
Hi In my office I need to define a fix IP address for the network-card, but at home everythink works with DHCP. since I don't feel like everytime I change to the office or come home to newly define the network card with yast: Is there a possibility to define one and the same network-card with two different 'profiles' so that I just need to switch the profile ( I think this exists for mac's ...) many thanks for your kind help I am sure, there must be many users, facing the same problem cheers christoph
-----Message d'origine----- De : Christoph Lehmann [mailto:christoph.lehmann@gmx.ch] Envoye : lundi 28 juin 2004 21:54 A : suse-linux-e@suse.com Objet : [SLE] one network-card with 2 different configurations
Hi
In my office I need to define a fix IP address for the network-card, but at home everythink works with DHCP.
since I don't feel like everytime I change to the office or come home to newly define the network card with yast:
Is there a possibility to define one and the same network-card with two different 'profiles' so that I just need to switch the profile ( I think this exists for mac's ...)
many thanks for your kind help
I am sure, there must be many users, facing the same problem
cheers
christoph
I've met the same problem with my nvidia card, I wanted to boot either with TVout support or not. Isolved it by defining an environment variable at boot, according to the value I choose by a symbolic link between two different XF86Config files. In your case you can define either the "office=" or the "home=' as boot parameter and in one case link to a ifcfg-eth-id-xxxxxx file and in the other case to another file. You define an init script in /etc/init.d which is run before starting network and it'll work. As example you'll find below the script I wrote for xfree. Ready to explain more and to help you. Michel ------------------------- #!/bin/sh # # /etc/init.d/xfree # # and symbolic its link # # /usr/sbin/rcxfree # # This script manages the graphic card configuration # # Basic support for the Linux Standard Base Specification 1.0.0 (to be used by # insserv for exemple) ### BEGIN INIT INFO # Provides: TVout # Required-Start: $network # Required-Stop: # Default-Start: 5 # Default-Stop: # Description: Manages the graphic card configuration ### END INIT INFO # . /etc/rc.status # See how we were called. case "$1" in start) rc_reset rm /etc/X11/XF86Config if env | grep '^vga=' > /dev/null ; then { echo -n "Disabling TV out" ln -s /etc/X11/XF86Config_notv /etc/X11/XF86Config } else { echo -n "Enabling TV out" ln -s /etc/X11/XF86Config_tvout /etc/X11/XF86Config } fi rc_status -v ;; stop) ;; *) echo "Usage: $0 {start|stop}" exit 1 esac --------------------------------------------------------
-- Check the headers for your unsubscription address For additional commands send e-mail to suse-linux-e-help@suse.com Also check the archives at http://lists.suse.com Please read the FAQs: suse-linux-e-faq@suse.com
Christoph Lehmann wrote:
Hi
In my office I need to define a fix IP address for the network-card, but at home everythink works with DHCP.
since I don't feel like everytime I change to the office or come home to newly define the network card with yast:
Is there a possibility to define one and the same network-card with two different 'profiles' so that I just need to switch the profile ( I think this exists for mac's ...)
many thanks for your kind help
I am sure, there must be many users, facing the same problem
There's a couple of ways. One is to just start the dhcp client, when you need it. The other, is to use profiles, which can be configured with Yast. The Profile Manager is located in the System section of Yast.
Hi
In my office I need to define a fix IP address for the network-card, but at home everythink works with DHCP.
Why not just add a host statement to the dhcpd.conf at work so you computer
always gets the same "fixed" IP at work while still being configured as a
dhcp client? Example:
host yourbox {
hardware ethernet 12:34:56:78:AB:CD;
fixed-address 207.175.42.254;
}
see man dhcpd.conf
The host statement
host hostname {
[ parameters ]
[ declarations ]
}
There must be at least one host statement for every BOOTP client
that is to be served. host state
ments may also be specified for DHCP clients, although this is not
required unless booting is only
enabled for known hosts.
If it is desirable to be able to boot a DHCP or BOOTP client on
more than one subnet with fixed
addresses, more than one address may be specified in the
fixed-address parameter, or more than one
host statement may be specified.
If client-specific boot parameters must change based on the network
to which the client is attached,
then multiple host statements should be used.
If a client is to be booted using a fixed address if it's possible,
but should be allocated a dynamic
address otherwise, then a host statement must be specified without a
fixed-address clause. hostname
should be a name identifying the host. If a hostname option is not
specified for the host, hostname
is used.
Host declarations are matched to actual DHCP or BOOTP clients by
matching the dhcp-client-identifier
option specified in the host declaration to the one supplied by the
client, or, if the host declara
tion or the client does not provide a dhcp-client-identifier option,
by matching the hardware parame
ter in the host declaration to the network hardware address supplied
by the client. BOOTP clients
do not normally provide a dhcp-client-identifier, so the
hardware address must be used for all
clients that may boot using the BOOTP protocol.
--
David C. Rankin, J.D., P.E.
RANKIN * BERTIN, PLLC
510 Ochiltree Street
Nacogdoches, Texas 75961
(936) 715-9333
(936) 715-9339 fax
www.rankin-bertin.com
--
----- Original Message -----
From: "Christoph Lehmann"
Hi
In my office I need to define a fix IP address for the network-card, but at home everythink works with DHCP.
since I don't feel like everytime I change to the office or come home to newly define the network card with yast:
Is there a possibility to define one and the same network-card with two different 'profiles' so that I just need to switch the profile ( I think this exists for mac's ...)
many thanks for your kind help
I am sure, there must be many users, facing the same problem
cheers
christoph
-- Check the headers for your unsubscription address For additional commands send e-mail to suse-linux-e-help@suse.com Also check the archives at http://lists.suse.com Please read the FAQs: suse-linux-e-faq@suse.com
On Mon, 2004-06-28 at 12:53, Christoph Lehmann wrote:
Hi
In my office I need to define a fix IP address for the network-card, but at home everythink works with DHCP.
since I don't feel like everytime I change to the office or come home to newly define the network card with yast:
Is there a possibility to define one and the same network-card with two different 'profiles' so that I just need to switch the profile ( I think this exists for mac's ...)
many thanks for your kind help
I am sure, there must be many users, facing the same problem
yes I have dialup at home and DHCP for university use for updates. What config files do you need? CWSIV
Quoting Carl William Spitzer IV
On Mon, 2004-06-28 at 12:53, Christoph Lehmann wrote:
Hi
In my office I need to define a fix IP address for the network-card, but at home everythink works with DHCP.
since I don't feel like everytime I change to the office or come home to newly define the network card with yast:
Is there a possibility to define one and the same network-card with two different 'profiles' so that I just need to switch the profile ( I think this exists for mac's ...)
many thanks for your kind help
I am sure, there must be many users, facing the same problem
Look at SCPM. Once installed, it is at Yast > System > Profile Manager. HTH, Jeffrey
participants (6)
-
Carl William Spitzer IV
-
Catimimi
-
Christoph Lehmann
-
David Rankin
-
James Knott
-
Jeffrey L. Taylor