Home >

LunaSH Command Reference Guide > LunaSH Commands > network > network interface static

network interface static

Directs the specified Ethernet device to use the specified static IP address.

Syntax

network interface static -device <netdevice> -ip <ipaddress> -netmask <ipaddress> [-gateway <ipaddress>] [-force]

When setting "network interface" configuration, one of "static" or "dhcp" or "bonding" is required.

 

(Option)   Parameter Description
-device    -dev <netdevice>  

Network Device (Eth0,Eth1).   

-ip    -i <ipaddress>   IP address assigned to the device.   
-netmask   -n <ipaddress>   Enable network interface bonding.   
-gateway    -g <ipaddress>   Disable network interface bonding.   
-force    -f Force action.   

Sample Output

lunash:> net -interface -static -device eth1 -ip 192.22.101.77 -gateway 
	  192.16.0.2   -netmask  255.255.0.0
	  'net -interface' successful. 
         Ethernet device eth1 set to ip address 192.22.101.77.