標籤:des io ar os 使用 sp 檔案 on 2014
常用windows運行命令
mstsc---遠端桌面連線
regedit.exe---開啟註冊表
services.msc---開啟服務管理員
rsop.msc---組策略結果集
taskmgr---工作管理員
eventvwr---事件檢視器
gpedit.msc---本機群組原則編輯器
osk---開啟螢幕小鍵盤
calc---啟動計算機
write---開啟寫字板
notepad---開啟記事本
winver---查看windows版本
msconfig.exe---系統配置公用程式
devmgmt.msc---開啟裝置管理員
mspaint---畫圖板
lusrmgr.msc---本機使用者和組
fsmgmt.msc---共用檔案管理工具
logoff---登出電腦
dcomcnfg---開啟系統元件服務
secpol.msc---開啟本地安全性原則
compmgmt.msc---電腦管理
perfmon.msc---電腦效能監測程式
cleanmgr---開啟磁碟清理工具
diskmgmt.msc---磁碟管理器
hostname---查看主機名稱
ipconfig---查看IP配置資訊
dvdplay---DVD播放器
tsshutdn----60秒倒計時關機命令
shutdown -s -t 600 ---10分鐘後關閉電腦(-s表示關閉,-t時間,-r重啟,-l登出) shutdown -a 取消剛才的操作
=========================
net user---查看當前系統有哪些使用者
net user 使用者名稱---查看使用者屬性
net start---查看開啟了哪些服務
net time \\目標IP---查看指定IP時間
net share ---查看本地開啟的共用
netstat -an ---相關開啟了哪些視窗及串連情況
netstat -s ---查看正在使用的所有協議的使用方式
……
========================
檔案及目錄操作命令
dir ---查看目前的目錄,類似linux下的ls命令。
md 目錄名----建立目錄
cd ---進入目錄
C:\Users\Administrator\Desktop>cd /d e: ---進入E盤,使用CD命令要加參數/D。 可者如下直接輸入e:斷行符號即可。
C:\Users\Administrator\Desktop>e:
E:\>c: ----要進入某一磁碟,直接輸入盤符加冒號,斷行符號即可。
C:\Users\Administrator\Desktop>cd /d d:/app
d:\app>push f:\share ----使用pushd命令直接到f:\share目錄下。
tree c:\ ----以tree方式顯示磁碟機或路徑目錄結構
tree c:\test /F ---顯示每個檔案夾中檔案的名稱
type c:\test.txt ---顯示檔案的內容
====================
Microsoft Windows [版本 6.1.7600]
著作權 (c) 2009 Microsoft Corporation。著作權所有,並保留一切權利。
C:\Users\Administrator>cd /d E:
E:\>dir--------------------查看目前的目錄內容
磁碟機 E 中的卷沒有標籤。
卷的序號是 0006-5BAA
E:\ 的目錄
2014/11/19 23:22 <DIR> DB2
2014/11/19 23:03 <DIR> LDAP資料
2014/11/19 23:26 <DIR> linux資料
……
E:\>md test-------------------------建立test目錄
E:\>cd test---------------------進入test目錄
E:\test>dir--------------------顯示test目錄下的內容
磁碟機 E 中的卷沒有標籤。
卷的序號是 0006-5BAA
E:\test 的目錄
2014/11/23 16:14 <DIR> .
2014/11/23 16:14 <DIR> ..
0 個檔案 0 位元組
2 個目錄 89,755,025,408 可用位元組
E:\test>echo this is a test of dos cmd to > testCreateFile.txt -------------------使用echo命令利用管道把內容輸出到檔案。
DOS下沒有提供直接建立檔案的命令,但可以使用管道操作來建立檔案,比如: dir>a.txt 此命令將dir的執行結果寫入並儲存到檔案a.txt中。
E:\test>echo test2 > test2.txt
E:\test>echo test3 > test3.txt
E:\test>dir
磁碟機 E 中的卷沒有標籤。
卷的序號是 0006-5BAA
E:\test 的目錄
2014/11/23 16:33 <DIR> .
2014/11/23 16:33 <DIR> ..
2014/11/23 16:33 8 test2.txt
2014/11/23 16:33 8 test3.txt
2014/11/23 16:23 31 testCreateFile.txt
3 個檔案 47 位元組
2 個目錄 89,755,025,408 可用位元組
E:\test>type test2.txt ---------------------使用type命令查看檔案內容
test2
E:\test>md testdir -------------------------建立目錄testdir
E:\test>tree /f --------------------------以tree方式顯示每個檔案夾中檔案的名稱
檔案夾 PATH 列表
卷序號為 0006-5BAA
E:.
│ test2.txt
│ test3.txt
│ testCreateFile.txt
│
└─testdir
----------------------------返回上一目錄及進入指定目錄
E:\test>
E:\test\testdir>e:
E:\test\testdir>cd ..
E:\test>cd ..
E:\>cd test/testdir
E:\test\testdir>
-------------------------------使用pushd命令或是/d參數進入指定目錄
E:\test\testdir>pushd f:
F:\>cd /d c:
C:\Users\Administrator>cd /d e:/test
e:\test>
e:\test>rd testdir-----------------------使用rd刪除空目錄,不能刪除非空目錄,不能刪除當前子目錄。
e:\test>copy test2.txt e:\test\testdir2\ --------------------使用copy命令複製檔案
已複製 1 個檔案。
e:\test\testdir2 的目錄
2014/11/23 16:46 <DIR> .
2014/11/23 16:46 <DIR> ..
2014/11/23 16:33 8 test2.txt
2014/11/23 16:45 14 test3
2014/11/23 16:46 5 test4.txt
3 個檔案 27 位元組
2 個目錄 89,755,025,408 可用位元組
e:\test\testdir2>del test3 test2.txt ----------------------使用del命令刪除檔案
e:\test\testdir2>dir
磁碟機 E 中的卷沒有標籤。
卷的序號是 0006-5BAA
e:\test\testdir2 的目錄
2014/11/23 16:46 <DIR> .
2014/11/23 16:46 <DIR> ..
2014/11/23 16:46 5 test4.txt
1 個檔案 5 位元組
2 個目錄 89,755,025,408 可用位元組
e:\test\testdir2>ren test4.txt testtest.txt -------------------使用ren命令重命令檔案
e:\test\testdir2>dir
磁碟機 E 中的卷沒有標籤。
卷的序號是 0006-5BAA
e:\test\testdir2 的目錄
2014/11/23 16:48 <DIR> .
2014/11/23 16:48 <DIR> ..
2014/11/23 16:46 5 testtest.txt
1 個檔案 5 位元組
2 個目錄 89,755,025,408 可用位元組
e:\test\testdir2>
e:\test>xcopy testdir3 e:\test\testdir2\ --------------使用xcopy命令複製目錄及其目錄下所有檔案
testdir3\test111.txt
複製了 1 個檔案
e:\test>move test2.txt testdir2\ ---------------使用move命令來移動檔案(剪下)
移動了 1 個檔案。
windows下常用的操作命令及dos命令