mirror of
https://github.com/leitbogioro/Tools.git
synced 2025-10-03 03:44:58 +08:00
Update SetupComplete.bat
This commit is contained in:
parent
d146d74365
commit
9ba4b230f4
1 changed files with 2 additions and 0 deletions
|
@ -17,7 +17,9 @@ for /f "tokens=2" %%a in ('echo list vol ^| diskpart ^| findstr "\<%systemDisk%\
|
|||
echo;%setmode%|find "on"&&goto:enable||goto:disable
|
||||
:enable
|
||||
wmic nicconfig where ipenabled=true call enablestatic(%staticip%),(%subnetmask%)
|
||||
::Using IPv4 of local server as a temporary "gateway" to make sure all of static IPv4 configs can be recognized by network service.
|
||||
wmic nicconfig where ipenabled=true call setgateways(%staticip%)
|
||||
::Replace temporary gateway to an actual one.
|
||||
wmic nicconfig where ipenabled=true call setgateways(%gateways%)
|
||||
wmic nicconfig where ipenabled=true call setdnsserversearchorder(%dnsserver1%,%dnsserver2%)
|
||||
del %0
|
||||
|
|
Loading…
Add table
Reference in a new issue