=========================================== README for "where2-fc1.sh" shell script =========================================== PURPOSE OF SCRIPT A portable PC typically needs to operate in multiple networking environments, e.g. home, office, friend's home... Each of these environments has its own unique settings for hostname / hosts device IP addresses gateway device/address DNS interfaces (eth0, eth1, rfcomm0...). This script allows you to switch networking settings between two different locations, for example, home and office. It can easily be extended to cover more locations if required. Because the hostname will most likely need to change between locations, a full shutdown is required (at least I have not found a way of doing it "on the fly" without serious host misconfiguration..!). The script will perform this for you. You will need to know exactly the network settings for home and office before going any further. Make sure you have a working configuration for each. Print out the contents of each of the following files, first when you are working at home, then when you are working at the office: /etc/sysconfig/ file: network /etc/sysconfig/networking/profiles/default/ files: ifcfg-eth*, keys-* (if wireless networking is used), hosts, network, resolv.conf Create two additional files for /etc/sysconfig/network: /etc/sysconfig/network.home /etc/sysconfig/network.office Edit network.home so that it contains the settings appropriate to your home network. Edit network.office so that it contains the settings appropriate to your office network. Create two new directories: /etc/sysconfig/networking/home and /etc/sysconfig/networking/office Copy all the files from /etc/sysconfig/networking/profiles/default/ into /etc/sysconfig/networking/home/ Edit them according to your home networking settings (from the printouts you made previously). Copy all the files from /etc/sysconfig/networking/profiles/default/ into /etc/sysconfig/networking/office/ Edit them according to your office networking settings (from the printouts you made previously). You should now have all the required files. If not, you will get error messages when you run "where2-fc1.sh". ----------------------------------------------------------------------------------- RUNNING THE "where2-fc1" SCRIPT (MUST BE RUN su root) Simply cd to the directory where the script is stored, and enter: sh where2-fc1.sh If you have problems, make sure you have read and implemented everything above before contacting me! However, I may have missed out something important, so all feedback will be appreciated. ________________________________ Jeremy Thompson mail@jeremythompson.uklinux.net ________________________________