900字范文,内容丰富有趣,生活中的好帮手!
900字范文 > windows常用cmd指令

windows常用cmd指令

时间:2018-12-03 02:01:41

相关推荐

windows常用cmd指令

打开命令行

1.在菜单栏中搜索命令行

2.在文件管理器的Path栏输入cmd,则在当前目录打开命令行

3.Windows+R,输入cmd,回车

ping(网络诊断工具)

ping是Windows、Unix和Linux系统下的一个命令

ping也属于一个通信协议,是TCP/IP协议的一部分

利用“ping”命令可以检查网络是否连通,可以很好地帮助我们分析和判定网络故障,用来作为可用性的检查

应用格式:ping空格IP地址 或者 ping空格域名

举例

C:\Users\xxx>ping Pinging [123.125.115.110] with 32 bytes of data:Request timed out.Reply from 123.125.115.110: bytes=32 time=52ms TTL=49Reply from 123.125.115.110: bytes=32 time=51ms TTL=49Reply from 123.125.115.110: bytes=32 time=52ms TTL=49Ping statistics for 123.125.115.110:Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),Approximate round trip times in milli-seconds:Minimum = 51ms, Maximum = 52ms, Average = 51msC:\Users\xxx>ping 123.125.115.110Pinging 123.125.115.110 with 32 bytes of data:Reply from 123.125.115.110: bytes=32 time=51ms TTL=49Reply from 123.125.115.110: bytes=32 time=51ms TTL=49Request timed out.Reply from 123.125.115.110: bytes=32 time=51ms TTL=49Ping statistics for 123.125.115.110:Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),Approximate round trip times in milli-seconds:Minimum = 51ms, Maximum = 51ms, Average = 51ms

原理:利用网络上机器IP地址的唯一性,给目标IP地址发送一个数据包,再要求对方返回一个同样大小的数据包来确定两台网络机器是否连接相通,时延是多少

ipconfig(查看本机ip)

举例

C:\Users\Administrator>ipconfigWindows IP ConfigurationEthernet adapter 以太网:Media State . . . . . . . . . . . : Media disconnectedConnection-specific DNS Suffix . :Ethernet adapter vEthernet (默认交换机):Connection-specific DNS Suffix . :Link-local IPv6 Address . . . . . : xxxx::xxxx:xxxx:xxxx:xxxxIPv4 Address. . . . . . . . . . . : x.x.x.xSubnet Mask . . . . . . . . . . . : x.x.x.xDefault Gateway . . . . . . . . . :Wireless LAN adapter 本地连接* 1:Media State . . . . . . . . . . . : Media disconnectedConnection-specific DNS Suffix . :Wireless LAN adapter 本地连接* 11:Media State . . . . . . . . . . . : Media disconnectedConnection-specific DNS Suffix . :Wireless LAN adapter WLAN:Connection-specific DNS Suffix . :Link-local IPv6 Address . . . . . : xxxx::xxxx:xxxx:xxxx:xxxxIPv4 Address. . . . . . . . . . . : x.x.x.xSubnet Mask . . . . . . . . . . . : x.x.x.xDefault Gateway . . . . . . . . . : x.x.x.xEthernet adapter 蓝牙网络连接:Media State . . . . . . . . . . . : Media disconnectedConnection-specific DNS Suffix . :

目录浏览

进入某个盘

D:目标盘:

在当前盘中前进

cd 目标目录

回退到上一级

cd..

举例

C:\Users\Administrator>D:D:\>cd WeChatD:\WeChat>cdD:\WeChatD:\WeChat>cd..D:\>

查看目录文件

dir

如果是需要查看隐藏文件的或者更多操作的话,可以使用dir /?来查看其它用法

D:\WeChat>dir /?Displays a list of files and subdirectories in a directory.DIR [drive:][path][filename] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N][/O[[:]sortorder]] [/P] [/Q] [/R] [/S] [/T[[:]timefield]] [/W] [/X] [/4][drive:][path][filename]Specifies drive, directory, and/or files to list./ADisplays files with specified attributes.attributes D DirectoriesR Read-only filesH Hidden filesA Files ready for archivingS System filesI Not content indexed filesL Reparse Points - Prefix meaning not/BUses bare format (no heading information or summary)./CDisplay the thousand separator in file sizes. This is thedefault. Use /-C to disable display of separator./DSame as wide but files are list sorted by column./LUses lowercase./NNew long list format where filenames are on the far right./OList by files in sorted order.sortorder N By name (alphabetic) S By size (smallest first)E By extension (alphabetic) D By date/time (oldest first)G Group directories first - Prefix to reverse order/PPauses after each screenful of information./QDisplay the owner of the file./RDisplay alternate data streams of the file./SDisplays files in specified directory and all subdirectories./TControls which time field displayed or used for sortingPress any key to continue . . .

清除屏幕

cls

查看cmd下的命令

help

找到命令之后,使用 命令+ /?来查看该命令下的其他属性

cd /?

参考资料

/LJFPHP/article/details/78818696

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