start a virtualbox machine from cmd
cd /d "D:\Program Files\Oracle\VirtualBox"
start VirtualBoxVM.exe -startvm openwrt_04
exit
set a static ip from cmd
@echo off
cls
color 0A
Echo *******************************************************************************
Echo
Echo *******************************************************************************
cmd /c netsh interface ip set address name="Ethernet" source=static addr=192.168.3.24 mask=255.255.255.0 gateway=192.168.3.81 gwmetric=1
cmd /c netsh interface ip set dns name="Ethernet" source=static addr=192.168.3.81
@REM cmd /c netsh interface ip add dns name="Ethernet" addr=8.8.8.8 index=2
ipconfig /all
Echo *******************************************************************************
Echo
Echo *******************************************************************************
Pause
set a dynamic ip from cmd
@echo off
cls
color 0A
Echo *******************************************************************************
Echo
Echo *******************************************************************************
netsh interface ip set address name="Ethernet" source=dhcp
netsh interface ip delete dns "Ethernet" all
ipconfig /flushdns
ipconfig /all
Echo *******************************************************************************
Echo
Echo *******************************************************************************
Pause
|