欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

設(shè)置VMWare虛擬機(jī)以及網(wǎng)絡(luò)開關(guān)批處理

大步's blog   發(fā)布時間:2015-07-06 14:58:44   作者:佚名   我要評論
這篇文章主要介紹了設(shè)置VMWare虛擬機(jī)以及網(wǎng)絡(luò)開關(guān)批處理,示例環(huán)境基于Windows系統(tǒng),需要的朋友可以參考下

由于VM虛擬機(jī)的網(wǎng)絡(luò)連接造成服務(wù)器不能正常啟動,所以把網(wǎng)絡(luò)連接禁用了.但每次使用VM步驟會很繁瑣.所以做了個批處理.

啟動:

復(fù)制代碼
代碼如下:
<p>:啟動,打印命令
@echo on
net start vmnetdhcp
net start "VMware NAT Service"
:啟用網(wǎng)絡(luò)連接
netsh interface set interface name="VMware Network Adapter VMnet1" admin=ENABLED
netsh interface set interface name="VMware Network Adapter VMnet8" admin=ENABLED
:啟動程序
"D:/Program Files/VMware/vmware.exe"
:暫停
pause
</p>

 

復(fù)制代碼
代碼如下:
<p>:啟動,打印命令
@echo on
net start vmnetdhcp
net start "VMware NAT Service"
:啟用網(wǎng)絡(luò)連接
netsh interface set interface name="VMware Network Adapter VMnet1" admin=ENABLED
netsh interface set interface name="VMware Network Adapter VMnet8" admin=ENABLED
:啟動程序
"D:/Program Files/VMware/vmware.exe"
:暫停
pause
</p>

停止

復(fù)制代碼
代碼如下:
<p>:停止服務(wù)
@echo on
net stop vmnetdhcp
net stop "VMware NAT Service"
:禁用網(wǎng)絡(luò)連接
netsh interface set interface name="VMware Network Adapter VMnet1" admin=DISABLED
netsh interface set interface name="VMware Network Adapter VMnet8" admin=DISABLED
:強(qiáng)殺進(jìn)程
taskkill /F /im vmware-tray.exe
:暫停
pause
</p>


 

復(fù)制代碼
代碼如下:
<p>:停止服務(wù)
@echo on
net stop vmnetdhcp
net stop "VMware NAT Service"
:禁用網(wǎng)絡(luò)連接
netsh interface set interface name="VMware Network Adapter VMnet1" admin=DISABLED
netsh interface set interface name="VMware Network Adapter VMnet8" admin=DISABLED
:強(qiáng)殺進(jìn)程
taskkill /F /im vmware-tray.exe
:暫停
pause
</p>

以下是更加方便的

安裝VM后發(fā)現(xiàn)默認(rèn)服務(wù)是啟動的,但并不是每次動用到VM,為了優(yōu)化系統(tǒng),可以考慮按需啟動服務(wù),但每次手工啟動好幾個相關(guān)的服務(wù)的確比較麻煩??梢钥紤]采用批處理的方式來解決啟動、停止的問題:

@ echo off
title vmware服務(wù)開啟、關(guān)閉程序
set in=set /p in=1.開啟vm服務(wù),2.關(guān)閉vm服務(wù)。請輸入:

復(fù)制代碼
代碼如下:
if "%in%"=="1" goto start
if "%in%"=="2" goto stop
exit
:start
net start ufad-ws60
net start VMAuthdService
net start VMnetDHCP
net start "VMware NAT Service"
net start VMUSBArbServicepause
exit
:stop
net stop ufad-ws60
net stop VMAuthdService
net stop VMnetDHCP
net stop "VMware NAT Service"
net stop VMUSBArbService
pause
exit

或者如下:

復(fù)制代碼
代碼如下:
echo off
title Switch %date% %time%
:A
color A
cls
echo ++++++++++++++++++++++++++++++++++++++++++++++++
echo = WELCOME TO VMware SWITCH =
echo. = =
echo = 啟動= 1 關(guān)閉= 2 設(shè)置手動= 3 退出= 4 =
echo. = =
echo. = =
echo ++++++++++++++++++++++++++++++++++++++++++++++++
echo.
echo.
set session=""
set /p session= Select[1/2/3/4]:
if /i "%session%"=="1" (goto:1)
if /i "%session%"=="2" (goto:2)
if /i "%session%"=="3" (goto:3)
if /i "%session%"=="4" (goto:4)</p> <p>:1
echo "正在啟動VMware相關(guān)開機(jī)服務(wù)..."
net start VMAuthdService
net start VMnetDHCP
net start "VMware NAT Service"
net start VMUSBArbService
echo 服務(wù)啟動完畢!
ping 127.0.0.1 /n 2 >nul
goto:A</p> <p>:2
echo "正在關(guān)閉VMware相關(guān)開機(jī)服務(wù)..."
net stop VMAuthdService
net stop VMnetDHCP
net stop "VMware NAT Service"
net stop VMUSBArbService
echo 服務(wù)已關(guān)閉!
ping 127.0.0.1 /n 2 >nul
goto:A</p> <p>:3
echo 切換VMware開機(jī)啟動服務(wù)為手動中,請稍候...
sc config VMAuthdService start= demand
sc config VMnetDHCP start= demand
sc config "VMware NAT Service" start= demand
sc config VMUSBArbService start= demand
echo 成功切換為手動模式!
ping 127.0.0.1 /n 2 >nul
goto:A</p> <p>:4
cls
echo 謝謝使用...
ping 127.0.0.1 /n 2 >nul
exit

另外,如果安裝VM之后,開機(jī)時按一下用戶名才能登錄桌面的解決方法:
1運(yùn)行框中輸入netplwiz   
2取消 "要使用本機(jī),用戶必須輸入用戶名和密碼"  前面的勾

相關(guān)文章

最新評論