Examples:
Example #1: The following command illustrates the usage and sample output for installing netprofmgr. Note that it creates a dhcp profile for each network interface listed by "ifconfig -a":
# netprofmgr -a install
Adding a network profile called off to disable all networking.
Adding enabled dhcp interface eth0 to profile dhcp-eth0
Adding disabled interface wlan0 to profile dhcp-eth0
Adding disabled interface eth0 to profile dhcp-wlan0
Adding enabled dhcp interface wlan0 to profile dhcp-wlan0
Example #2: The following command illustrates the usage and sample output for showing the active profile and listing available profiles:
# netprofmgr
The current profile is: home-wireless
Here are the available profiles:
dhcp
dhcp-eth0
dhcp-wlan0
home
home-wireless
off
Use -h flag to see proper usage
Example #3: The following command adds a network profile called 'atwork' where the only active inteface is eth0 with an IP address of 192.168.0.10, a netmask of 255.255.255.0, a default gateway 192.168.0.1, and a primary DNS server of 192.168.0.1:
# netprofmgr -a add -I eth0 -i 192.168.0.10 -n 255.255.255.0 -g 192.168.0.1 -N 192.168.0.1 -p atwork
Example #4: The following command activates the 'atwork' profile:
# netprofmgr atwork
Example #5: The following command deletes the 'atwork' profile:
# netprofmgr -a del -p atwork
Example #6: Run the netprofmgr-gui command to start up the netprofmgr graphical profile selector.
Example #7: To run netprofmgr-gui from kde or gnome launcher, add a launcher icon and use the following commmand:
/usr/bin/kdesu -u root /usr/local/bin/netprofmgr-gui
|