Top
||
Section Contents
||
Permuted Index
SavaJe OS
1.1.0
net display or set network settings
net show net [set] (gw | mask | ip | essid | adhoc)val
net dns (rehash | get | load)val
Command | Subcommands | Description |
[set]
|
gw mask ip essid adhoc
|
If the optional set command is specified, set the gateway, netmask, IP address, ESSID, or adhoc to the value specified by val . Otherwise, just show the current value. |
dns
|
||
rehash
|
Reload static hostnames from the file specified in val . |
|
get
|
Report the IP address of the hostname specified in val . |
|
load
|
Load IP address/hostname information from the file specified in val . The file should be in the same format as an /etc/hosts file. |
There is another application,
net(tools)
, which
allows you to change between DHCP (default) and a static IP address.
This application also reports the same information as net
in
a more user-friendly form.
Discover the IP address of this machine:
lsh%net ip
ip: 192.168.0.238
Discover the IP address of a particular host (defined in /ramfs/etc/hosts
or loaded explicitly using net dns load
):
lsh%net dns get localhost
127.0.0.1 lsh%net dns get blue
192.168.0.237
Load the IP address/hostname pairs from the file myhosts:
lsh% cat myhosts 192.168.0.123 chopin 111.222.111.237 monet lsh%net dns load myhosts
lsh%net dns get chopin
192.168.0.123
Set the ESSID (extended service set identifier) to savaJe
:
lsh%net set essid savaJe
Enable adhoc access using an 802.11b wireless networking card:
To disable adhoc wireless networking:lsh%net set adhoc true
lsh%net set adhoc false