Common operations Commands and DOS commands under Windows

Source: Internet
Author: User
Tags echo command net time

Common Windows Run commands
MSTSC---Remote Desktop Connection
Regedit.exe---Open the registry
Services.msc---Open Service Manager
Rsop.msc---Group Policy result set
Taskmgr---Task Manager
EVENTVWR---Event Viewer
Gpedit.msc---Local Group Policy Editor
OSK---Open the on-screen keyboard
Calc---start Calculator
Write---open WordPad
Notepad---Open notepad
Winver---View windows versions
Msconfig.exe---System Configuration Utility
Devmgmt.msc---Open Device Manager
MSPaint---drawing board
Lusrmgr.msc---Native Users and Groups
Fsmgmt.msc---shared File Manager
Logoff---Log off the computer
DCOMCNFG---Open system Component Services
Secpol.msc---open local security policy
Compmgmt.msc---Computer Management
Perfmon.msc---computer performance monitoring program
cleanmgr---Open the Disk Cleanup tool
Diskmgmt.msc---Disk Manager
Hostname---View host name
Ipconfig---view IP configuration information
Dvdplay---DVD player
TSSHUTDN----60-second Countdown shutdown command

Shutdown-s-T---10 minutes after shutting down the computer (-s = off,-t time,-r restart,-L logoff) shutdown-a cancel the operation just now

=========================
NET user---See which users are present on the system
NET user User name---View users properties
NET start---See which services are turned on
NET time \ \ Destination IP---View specified IP times
NET share---Viewing locally-enabled shares
Netstat-an---about which windows and connections are open
Netstat-s---View usage of all protocols in use

......
========================
File and Directory Operations command
Dir---View the current directory, similar to the LS command under Linux.
MD Directory name----Create directory
CD---into the catalogue
C:\USERS\ADMINISTRATOR\DESKTOP>CD/D e:---Enter e-disk, use the CD command to add the parameter/d. The following direct input e: Enter can be.
C:\users\administrator\desktop>e:
E:\>c:----To enter a disk, direct input disk multibyte colon, enter.
C:\USERS\ADMINISTRATOR\DESKTOP>CD/D D:/app
D:\app>push f:\share----Use the pushd command directly to the F:\share directory.

Tree c \----Displays the drive or path directory structure in tree mode
Tree c:\test/f---Show the names of files in each folder
Type C:\test.txt---Display the contents of the file
====================
Microsoft Windows [version 6.1.7600]
Copyright (c) Microsoft Corporation. All rights reserved.
C:\USERS\ADMINISTRATOR>CD/D E:
E:\>dir--------------------View current directory contents
The volume in drive E is not labeled.
The serial number of the volume is 0006-5baa
E:\ The directory

2014/11/19 23:22 <DIR> DB2
2014/11/19 23:03 <DIR> LDAP data
2014/11/19 23:26 <DIR> Linux Data
......
E:\>MD test-------------------------Create test directory

E:\>CD test---------------------into the test directory

E:\test>dir--------------------Display the contents of the test directory
The volume in drive E is not labeled.
The serial number of the volume is 0006-5baa

Directory of E:\test

2014/11/23 16:14 <DIR>.
2014/11/23 16:14 <DIR>.
0 Files 0 bytes
2 Directories 89,755,025,408 bytes available

E:\test>echo This was a test of DOS cmd to > TestCreateFile.txt-------------------use the echo command to output the content to a file using the pipe.
There is no command to create a file directly under DOS, but you can use pipeline operations to create a file, such as: dir>a.txt This command writes the result of Dir and saves it to the file a.txt.

E:\test>echo test2 > Test2.txt

E:\test>echo test3 > Test3.txt

E:\test>dir
The volume in drive E is not labeled.
The serial number of the volume is 0006-5baa

Directory of 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 TestCreateFile.txt
3 files 47 bytes
2 Directories 89,755,025,408 bytes available

E:\test>type test2.txt---------------------Use the type command to view the contents of a file
Test2

E:\TEST>MD TestDir-------------------------Create a catalog TestDir

E:\test>tree/f--------------------------Tree to display the names of files in each folder
Folder PATH List
Volume serial number is 0006-5baa
E:.
│test2.txt
│test3.txt
│testcreatefile.txt

└─testdir

----------------------------go back to the previous directory and enter the specified directory
E:\test>

E:\test\testdir>e:

E:\TEST\TESTDIR>CD.

E:\TEST>CD.

E:\>CD Test/testdir

E:\test\testdir>
-------------------------------Use the pushd command or the/d parameter to enter the specified directory
E:\test\testdir>pushd F:

F:\>CD/D C:

C:\USERS\ADMINISTRATOR>CD/D E:/test

E:\test>

E:\test>rd TestDir-----------------------Use rd to delete an empty directory, you cannot delete a non-empty directory, and you cannot delete the current subdirectory.

E:\test>copy test2.txt e:\test\testdir2\--------------------Copy files using the copy command
1 files have been copied.

Directory of 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 Test3
2014/11/23 16:46 5 Test4.txt
3 files 27 bytes
2 Directories 89,755,025,408 bytes available

E:\test\testdir2>del test3 test2.txt----------------------Delete files using the del command

E:\test\testdir2>dir
The volume in drive E is not labeled.
The serial number of the volume is 0006-5baa

Directory of E:\TEST\TESTDIR2

2014/11/23 16:46 <DIR>.
2014/11/23 16:46 <DIR>.
2014/11/23 16:46 5 Test4.txt
1 Files 5 bytes
2 Directories 89,755,025,408 bytes available


E:\test\testdir2>ren test4.txt testtest.txt-------------------using the ren command to re-command files

E:\test\testdir2>dir
The volume in drive E is not labeled.
The serial number of the volume is 0006-5baa

Directory of E:\TEST\TESTDIR2

2014/11/23 16:48 <DIR>.
2014/11/23 16:48 <DIR>.
2014/11/23 16:46 5 Testtest.txt
1 Files 5 bytes
2 Directories 89,755,025,408 bytes available

E:\test\testdir2>

E:\test>xcopy testdir3 e:\test\testdir2\--------------Use the xcopy command to copy all files in the directory and its directory
Testdir3\test111.txt
1 Files Copied

E:\test>move test2.txt testdir2\---------------Use the move command to move a file (cut)
1 files were moved.

Common operations Commands and DOS commands under Windows

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.