900字范文,内容丰富有趣,生活中的好帮手!
900字范文 > windows的命令行工具和DOS工具的区别

windows的命令行工具和DOS工具的区别

时间:2018-11-07 18:56:56

相关推荐

windows的命令行工具和DOS工具的区别

很多的系统管理员可能认为命令行是程序员编程用的,这是不对的,其实命令行是另一种用来管理计算机的接口。

1 命令行窗口

Windows NT/Windows 2000以后的操作系统为用户提供了两种命令行窗口:cmd.exe和,CMD.EXE是Windows 窗口命令行接口,因此它可以通过窗口右上角的X来关闭,它不是一个dos窗口,而是一个16位的DOS应用程序,它用于支持老的dos应用程序,它必须通过命令行输入exit才可以退出,它一般运行于NTVDM中。但就用户来说,这两个命令有惊人的相似之处,如果用户运行command.exe,用户会在任务管理器中看到一个进程ntvdm.exe在运行,如果运行cmd.exe则进程可以看到cmd.exe,而且command.exe还支持以前的16位的现在已经不用的命令。下面分别是2种接口的打开方法和显示结果。

在开始->运行,输入cmd,然后enter。如下:

在开始->运行,输入command,然后enter。如下:

2 窗口的属性

第一种方法:

窗口中输入命令:Cmd [{/A | /U}] [/Q] [/D] [/E: {ON | OFF}] [[/S] [{/C | /K}] string] [/V:{ON |/OFF}] [/T:FG]

参数的含义:

/C string Executes the command specified in the string and then exits the command shell.

/K string Executes the command specified in the string and does not exit the command shell.

/S Modifies the commands used as strings with the /C and /K parameters. Usually, you place quotes around command strings.The /S parameter removes the pening and closing quotes before processing the command.

/A Causes the output of internal commands to be sent to a file (this process is also called piping) in ANSI character format.

/U Causes the output of internal commands to be sent to a file (this process is also called piping) in Unicode character format.

/Q Turns off echo, which is on by default. Echo off mode is also known as quiet mode. When echo is on, each command is displayed as it is processed.

/D Disables the AutoRun command from the Registry.

/E:ON Enables command extensions if they were disabled. Command extensions are enabled by default.

/E:OFF Disables command extensions.

/F:ON Enables the completion of characters for files and directories, which help improve typing speed at the command prompt.

/F:OFF Disables the completion of characters for files and directories.

/V:ON Enables delayed environment variable expansion by using the exclamation point character (!) as the delimiter. This means that using !ThisVar! will expand the variable ThisVar at the time of execution.

/V:OFF Disables delayed environment variable expansion.

/T:FG 设定命令行窗口的前背景色

第二种方法:在命令行窗口的左上角点击,可得到属性设置对话框,如下:

注:可以设定执行过的命令的记录数,然后用方向键查看。还有快捷键从F1到F9哦,怎么用自己试试看喽。

3 命令行Shell的内部命令

命令行可以执行2种命令:内部命令和外部命令。外部命令是以.exe的形式存在的,一般存放在系统的目录下,例如XCOPY.EXE用来拷贝整个目录树结构,DISKPART.EXE用来管理磁盘,IPCONFIG.EXE用来显示和刷新计算机的IP/TCP的配置。。。

以下是比较常用的内部命令:

■ Assoc 显示和修改文件的相关程序.

■ Call 在批处理文件中调用其他函数或批处理文件.

■ CD (ChDir) 改变目录.

■ Color 改变前背景色.

■ Cls 清屏.

■ Copy 拷贝文件

■ Date 显示和修改系统日期.

■ Dir 显示目录下文件信息.

■ Del (Erase) 删除文件.

■ Echo 在命令行窗口种显示文本.

■ Endlocal 退出使用本地化环境变量.

■ Exit 退出命令行窗口.

■ For 批处理文件种使用循环.

■ Ftype 显示修改文件类型.

■ Goto 批处理文件种语句跳转.

■ If 批处理文件种条件选择.

■ Md (Mkdir) 创建目录.

■ Move 移动文件.

■ Path 显示和改变命令行窗口执行程序的搜索路径,当无参数使用是显示当前的系统路径.

■ Pause 暂停批处理文件的执行.

■ PopD 使用存储的目录还原目录.

■ Prompt 设置命令行窗口的显示文本.

■ PushD 存储当前使用的目录.

■ Rd (Rmdir) 删除目录

■ Rem 在品处理文件种加注释.

■ Set 显示,设定或删除环境变量. 当你无参数使用这个命令,显示系统的环境变量

■ Setlocal 在批处理文件中开始使用本地环境变量

■ Shift 改变批处理文件中某能够取代的参数的位置.

■ Start 打开命令行窗口.

■ Time 显示和改变当前系统的时间.

■ Title 改变执行批处理文件时的命令行窗口的title

■ Type 显示文本文件的内容,但是不可以修改

■ Vol 显示分区的卷标和序列号

3 windows常用外部命令

winver---------检查windows版本

wmimgmt.msc----打开windows管理体系结构(wmi)

wupdmgr--------windows更新程序

w脚本--------windows脚本宿主设置

write----------写字板

winmsd---------系统信息

wiaacmgr-------扫描仪和照相机向导

winchat--------xp自带局域网聊天

mem.exe--------显示内存使用情况

msconfig-----------启动

msconfig.exe---系统配置实用程序

mplayer2-------简易widnows media player

mspaint--------画图板

mstsc----------远程桌面连接

mplayer2-------媒体播放机

magnify--------放大镜实用程序

mmc------------打开控制台

mobsync--------同步命令

dxdiag---------检查directx信息

drwtsn32------ 系统医生

devmgmt.msc--- 设备管理器

dfrg.msc-------磁盘碎片整理程序

diskmgmt.msc---磁盘管理实用程序

dcomcnfg-------打开系统组件服务

ddeshare-------打开dde共享设置

dvdplay--------dvd播放器

nslookup-------ip地址侦测器

net stop messenger-----停止信使服务

net start messenger----开始信使服务

notepad--------打开记事本

nslookup-------网络管理的工具向导

ntbackup-------系统备份和还原

narrator-------屏幕“讲述人”

ntmsmgr.msc----移动存储管理器

ntmsoprq.msc---移动存储管理员操作请求

netstat -an----(tc)命令检查接口

syncapp--------创建一个公文包

sysedit--------系统配置编辑器

sigverif-------文件签名验证程序

sndrec32-------录音机

shrpubw--------创建共享文件夹

secpol.msc-----本地安全策略

syskey---------系统加密,一旦加密就不能解开,保护windows xp系统的双重密码

services.msc---本地服务设置

sndvol32-------音量控制程序

sfc.exe--------系统文件检查器

sfc /scannow---windows文件保护(扫描错误并复原)

tsshutdn-------60秒倒计时关机命令

tourstart------xp简介(安装完成后出现的漫游xp程序)

taskmgr--------任务管理器(2000/xp/)

eventvwr-------事件查看器

eudcedit-------造字程序

explorer-------打开资源管理器

packager-------对象包装程序

perfmon.msc----计算机性能监测程序

progman--------程序管理器

regedit.exe----注册表

rsop.msc-------组策略结果集

regedt32-------注册表编辑器

rononce -p ----15秒关机

regsvr32 /u *.dll----停止dll文件运行

regsvr32 /u zipfldr.dll------取消zip支持

cmd.exe--------cmd命令提示符

chkdsk.exe-----chkdsk磁盘检查

certmgr.msc----证书管理实用程序

calc-----------启动计算器

charmap--------启动字符映射表

cliconfg-------sql server 客户端网络实用程序

clipbrd--------剪贴板查看器

conf-----------启动netmeeting

compmgmt.msc---计算机管理

cleanmgr-------垃圾整理

ciadv.msc------索引服务程序

osk------------打开屏幕键盘

odbcad32-------odbc数据源管理器

oobe/msoobe /a----检查xp是否激活

lusrmgr.msc----本机用户和组

logoff---------注销命令

iexpress-------木马捆绑工具,系统自带

fsmgmt.msc-----共享文件夹管理器

utilman--------辅助工具管理器

gpedit.msc-----组策略

4 相关帮助文档

1)可以在命令行窗口种输入help得到帮助。

2)可以在开始->帮助和支持 中输入:command shell,即可得到所有命令的帮助。

3)网络资源:见前言中参考网站。

5 常用软件安装

在windows 中,可以在系统盘中找到suptools.msi 来安装一些有用的工具,如果你是windows xp系统,你也可以到网络上下载相关的软件。

小技巧:如果你的命令行窗口不识别正确的命令,很有可能是你的系统变量path的原因啊,看看有没有这3个啊,没有的赶快加入:(ok?)

C:\Windows\System32;

C:\Windows;

C:\Windows\System32\Wbem

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。