Полное руководство cmd

В данной статье будут рассмотрены основы командной строки Windows, а именно:

  • Понятие командной строки;
  • Справочник по командам командной оболочки;
  • Последовательность событий при выполнение команды;
  • Создание сценариев командной строки;
  • Управление отображением текста и команд;
  • Команды для изучение системной информации;
  • Команды для использования реестра;
  • Управление системными службами;
  • Перезагрузка и выключение систем из командной строки;
  • Управление приложениями и  процессами из командной строки.

Содержание

  1. Понятие командной строки
  2. Краткий справочник по командам командной оболочки (Cmd.exe)
  3. Последовательность событий при выполнение команды
  4. Создание сценариев командной строки
  5. Управление отображением текста и команд
  6. Изучение системной информации
  7. Команды для использования реестра
  8. Управление системными службами
  9. Перезагрузка и выключение систем из командной строки
  10. Управление приложениями, процессами и производительностью

Понятие командной строки

Поддержка командной строки встроена в операционную систему Microsoft Windows и доступна через окно командной оболочки. Командная строка поддерживается во всех версиях Windows и служит для запуска встроенных команд, утилит и сценариев. Несмотря на мощь и гибкость командной строки, некоторые администраторы Windows никогда ее не используют. Если вам хватает графических средств администрирования, можно применять только их, щелкая мышью элементы пользовательского интерфейса.

Однако опытные администраторы Windows, квалифицированные специалисты по технической поддержке и «продвинутые» пользователи не могут обойтись без командной строки. Зная, как правильно применять командную строку, в частности, какие средства командной строки выбрать, как и когда их использовать, чтобы они работали эффективно, можно избежать многочисленных проблем и добиться четкого выполнения операций. Если вы занимаетесь поддержкой нескольких доменов или сетей, то для автоматизации ежедневных операций не только важно, но и необходимо иметь представление об экономящих время способах работы с командной строкой.

С каждой новой версией Windows командная строка совершенствовалась, а ее возможности расширялись. Командная строка претерпела значительные изменения, связанные не только с повышением производительности, но и с увеличением гибкости. Теперь с помощью командной строки Windows можно решать задачи, которые нельзя было решить в предыдущих версиях Windows.

Среду командной оболочки Windows запускают разными способами, в частности указывая параметры при запуске Cmd.exe или используя собственный стартовый файл, хранящийся в каталоге %SystemRoot%System32.

Кроме того, командная строка может работать в пакетном режиме для выполнения набора команд. В пакетном режиме командная строка считывает и выполняет команды одну за другой.

Работая с командной строкой Windows, Вы должны понимать, откуда берутся используемые Вами команды. «Родные» команды (встроенные в операционную систему) бывают двух видов:

  • Внутренние – существуют внутри командной оболочки, у них нет отдельных исполняемых файлов;
  • Внешние — реализованы в отдельных исполняемых файлах, которые обычно хранятся в каталоге %SystemRoot% System32.

Краткий справочник по командам командной оболочки (Cmd.exe)

  • assoc — выводит или изменяет сопоставления (associations) типов файлов;
  • break — задает точки останова при отладке
  • call — вызывает из сценария процедуру или другой сценарий;
  • cd (chdir) — показывает имя текущего каталога или выполняет смену текущего каталога;
  • cls — очищает окно командной строки и буфер экрана;
  • color — задает цвета текста и фона окна командной оболочки;
  • сору — копирует файлы или выполняет конкатенацию файлов;
  • date — показывает или устанавливает текущую дату;
  • del (erase) — удаляет заданный файл, группу файлов или каталог;
  • dir — показывает список подкаталогов и файлов в текущем или заданном каталоге;
  • echo — выводит текст в окно командной строки или задает, надо ли отображать команды на экране (on|off);
  • endlocal — отмечает конец локализации (локальной области видимости) переменных;
  • exit — выход из оболочки командной строки;
  • for — выполняет заданную команду для каждого файла в наборе;
  • ftype выводит или изменяет текущие типы файлов в сопоставлениях расширений файлов с программами;
  • goto — указывает, что интерпретатор команд должен перейти на строку с заданной меткой в пакетном сценарии;
  • if — выполняет команды по условию;
  • md (mkdir) — создает подкаталог в текущем или заданном каталоге;
  • move — перемещает файл или группу файлов из текущего или заданного исходного каталога в указанный каталог. Также может переименовывать каталог;
  • path — показывает или задает путь к командам, используемый операционной системой при поиске исполняемых файлов и сценариев;
  • pause — останавливает выполнение пакетного файла и ожидает ввода с клавиатуры;
  • popd — делает текущим каталог, имя которого было сохранено командой PUSHD;
  • prompt — указывает, какой текст должен показываться в строке приглашения;
  • pushd — сохраняет имя текущего каталога и при необходимости делает текущим заданный каталог;
  • rd (rmdir) — удаляет каталог или каталог вместе с его подкаталогами;
  • rem — помечает комментарии в пакетном сценарии или Config.nt;
  • ren (rename) — Переименовывает файл или группу файлов;
  • set — показывает текущие переменные окружения или задает временные переменные для текущей командной оболочки;
  • setlocal — отмечает начало локализации (локальной области видимости) переменных в пакетных сценариях;
  • shift — сдвигает позицию замещаемых параметров в пакетных сценариях;
  • start — запускает заданную программу или команду в отдельном окне;
  • time — показывает или устанавливает системное время;
  • title — задает заголовок окна командной оболочки;
  • type — показывает содержимое текстового файла;
  • verify — включает режим проверки файлов после записи на диск;
  • vol — показывает метку и серийный номер дискового тома.

Синтаксис любой внутренней команды (и большинства внешних) можно получить, введя в командной строке имя команды и /?, например:

   
   copy /?

Командная оболочка — весьма мощная среда работы с командами и сценариями. В командной строке можно запускать команды разных типов: встроенные команды, утилиты Windows и версии приложений, рассчитанные на командную строку. Независимо от типа каждая команда, которую вы будете использовать, должна соответствовать одним и тем же синтаксическим правилам. Согласно этим правилам, за именем команды идут обязательные или необязательные аргументы. Кроме того, аргументы могут использовать перенаправление ввода, вывода или стандартных ошибок.

Последовательность событий при выполнение команды

  • Командная оболочка заменяет любые переменные, введенные в тексте команд, их текущими — значениями;
  • Если введена группа или цепочка из нескольких команд, строка разбивается на отдельные команды, которые в свою очередь разбиваются на имя и аргументы команды. Далее команды обрабатываются по отдельности;
  • Если в имени команды указан путь, командная оболочка ищет команду по этому пути. Если в указанном каталоге такой команды нет, командная оболочка возвращает ошибку;
  • Если в имени команды не задан путь, командная оболочка сначала пытается разрешить имя команды на внутреннем уровне. Если найдена внутренняя команда с таким именем, значит, вызвана внутренняя команда, которую сразу же можно выполнить. Если внутренней команды с таким именем нет, командная оболочка сначала ищет исполняемый файл команды в текущем каталоге, а затем в каталогах, перечне в переменной окружения PATH. Если файла команды нет ни в одном из этих каталогов, командная оболочка возвращает ошибку;
  • Если команда найдена, она выполняется с заданными аргументами и при необходимости ввод считывается из источника, указанного в этих аргументах. Вывод и ошибки команд показываются в окне командной строки или направляются заданному приемнику вывода и ошибок.
  • Как видите, на выполнение команд влияют многие факторы, в том числе пути к командам, перенаправление ввода-вывода, группирование или создание цепочек команд.

При работе с командной оболочкой Вы, вероятно, запускали ее, открывая меню Start (Пуск) и выбирая Programs (Программы) или All Programs (Все программы), затем Accessories (Стандартные) и Command Prompt (Командная строка). Другие способы запуска командной строки — диалоговое окно Run (Запуск программы) или ввод cmd в другом, уже открытом окне командной оболочки. Эти способы позволяют при запуске командной строки указывать аргументы: ключи, управляющие работой командной строки, и параметры, инициирующие выполнение дополнительных команд. Например, можно запустить командную оболочку в «молчаливом» режиме (т. е. отключить эхо-вывод) командой cmd /q или сделать так, чтобы командная оболочка выполнила заданную команду и завершила свою работу, — для этого нужно ввести cmd /с, а затем текст команды в кавычках.

В следующем примере командная оболочка запускается, выполняет команду ipconfig с выводом результатов в файл и завершается:

   
   cmd /c "ipconfig > c:ipconfig.txt"

Создание сценариев командной строки

Сценарии командной строки — текстовые файлы с командами, которые вы хотите выполнить. Это те же команды, которые обычно вводятся в командной оболочке Windows. Однако вместо того чтобы вводить команды каждый раз, когда они понадобятся, можно создать соответствующий сценарий и упростить себе жизнь.

Поскольку сценарии состоят из стандартных текстовых символов, их можно создавать и редактировать в любом стандартном текстовом редакторе, скажем, в Notepad (блокнот). Вводя команды, убедитесь, что каждая команда или группа команд, которые должны выполняться совместно, разметаются с новой строки. Это обеспечит их корректное выполнение. Закончив создание сценария командной строки, сохраните файл сценария с расширением .bat или .cmd. Оба расширения работают одинаково. Например, если вам надо создать сценарий для вывода имени системы, версии Windows и конфигурации IP, включите в файл SysInfo.bat или SysInfo.cmd следующие три команды:

  
  hostname
  ver
  ipconfig -all

Управление отображением текста и команд

Команда ECHO служит двум целям: для записи текста в вывод (например, в окно командной оболочки или текстовый файл) и для включения/выключения эхо-отображения команд. Обычно при выполнении команд сценария сами команды и вывод этих команд отображаются в консольном окне. Это называется эхо-отображением команд (comand echoing).

Чтобы использовать команду ECHO для отображения текста, введите echo и текст, который надо вывести:

  
  echo The system host name Is: hostname

Чтобы с помощью ECHO управлять эхо-отображением команд, введите echo off или echo on, например:

  
  echo off
  echo The system host name is:
  hostname

Чтобы направить вывод в файл, а не в окно командной оболочки, используйте перенаправление вывода, например:

Курс по SQL для начинающих

  
  echo off
  echo The system host name is: > current.txt
  hostname » current.txt

Теперь посмотрим, как подавляется эхо-отображение команд. Запустите командную оболочку, введите echo off, затем другие команды. Вы увидите, что приглашение командной строки больше не выводится. Вместо него появляется только то, что набирается в консольном окне, и вывод выполненных команд. В сценариях команда ECHO OFF отключает эхо-отображение команд и приглашение командной строки. Добавляя в свои сценарии команду ECHO OFF, вы предотвращаете загромождение окна командной оболочки или файла текстом команд, если Вас интересует лишь вывод от этих команд.

Изучение системной информации

Часто при работе с компьютером пользователя или удаленным сервером возникает необходимость в получении базовой информации о системе вроде имени зарегистрированного в ней пользователя, текущего системного времени или местоположения определенного файла. Команды, которые позволяют собрать основную информацию о системе, включают:

  • NOW — отображает текущую системную дату и время в 24-часовом формате, например Sal May 9 12:30:45 2003. Доступна только в Windows Server 2003 Resource Kit;
  • WHOAMI — сообщает имя пользователя, зарегистрированного в системе на данный момент, например adatumadmi-nistrator;
  • WHERE — выполняет поиск файлов по шаблону поиска (search pattern) и возвращает список совпавших результатов.

Чтобы использовать NOW или WHOAMI, просто введите команду в окне командной оболочки и нажмите Enter. Наиболее распространенный синтаксис для WHERE выглядит так:

  
  where /r базовый_каталог_имя_файла

Здесь параметр /r указан для рекурсивного поиска, начиная от указанного каталога (базовый_каталог) и включая все его подкаталоги, а имя_файла — полное или частичное имя искомого файла, которое может включать символы подстановки (wildcards): знак ? заменяет один символ, а знак * — группу символов, например data???.txt или data*.*. В следующем примере в каталоге С: и всех его подкаталогах выполняется поиск всех текстовых файлов, имена которых начинаются с data.

   
  where /r C: data*.txt

Также можно найти файлы всех типов, имена которых начинаются с data:

   
  where /r C: data*.*

Иногда нужно получить информацию о конфигурации системы или о системном окружении. В критически важных системах эту информацию можно сохранить или распечатать для справки. Ниже перечислены команды, позволяющие собирать информацию о системе.

  • DRIVERQUERY — выводит список всех установленных драйверов устройств и их свойства, в том числе имя модуля (module name), отображаемое имя (display name), тип драйвера и дату сборки (driver link date). В режиме отображения всей информации (/V) сообщается статус (status) и состояние (state) драйвера, режим запуска, сведения об использовании памяти и путь в файловой системе. Параметр /V также включает вывод детальной информации обо всех неподписанных драйверах.
  • SYSTEMINFO — выдает подробную информацию о конфигурации системы, в том числе сведения о версии, типе и изготовителе операционной системы, процессоре, версии BIOS, объеме памяти, региональных стандартах, часовом поясе и конфигурации сетевого адаптера.
  • NLSINFO — отображает подробную информацию о региональных стандартах, включая язык по умолчанию (default language), кодовую страницу Windows, форматы отображения времени и чисел, часовой пояс и установленные кодовые страницы. Эта команда доступна лишь в Windows Server 2003 Resource Kit.

Чтобы использовать эти команды на локальном компьютере, просто введите имя нужной команды в окне командной оболочки и нажмите Enter.

Команды для использования реестра

Реестр Windows хранит конфигурационную информацию операционной системы, приложений, пользователей и оборудования. Эти данные содержатся в разделах (keys) и параметрах (values) реестра, которые размещаются в определенном корневом разделе (root key), который контролирует, как и когда используются разделы и параметры.

Если Вы знаете пути к разделам и понимаете допустимые типы данных в разделах, то можете использовать команду REG для просмотра разделов и параметров и манипуляций над ними самыми разнообразными способами. REG поддерживает несколько подкоманд:

  • REG add — добавляет в реестр новый подраздел или элемент;
  • REG delete — удаляет из реестра подраздел или элемент;
  • REG query — выводит список элементов раздела и имена подразделов (если они есть);
  • REG compare — сравнивает подразделы или элементы реестра;
  • REG сору — копирует элемент реестра по указанному пути раздела на локальной или удаленной системе;
  • REG restore — записывает в реестр ранее сохраненные подразделы, элементы и параметры;
  • REG save — сохраняет копию указанных подразделов, элементов и параметров реестра в файл.

Управление системными службами

Службы обеспечивают ключевые функции рабочих станций и серверов. Для управления системными службами на локальных и удаленных системах используется команда контроллера служб (service controller command) SC, имеющая набор подкоманд, ниже описывается лишь их часть:

  • SC config — настройка учетных записей регистрации и запуска служб;
  • SC query — вывод списка всех служб, настроенных на компьютере;
  • SC qc — отображение конфигурации определенной службы;
  • SC start — запуск служб;
  • SC stop — остановка служб;
  • SC pause — приостановка работы служб;
  • SC continue — возобновление работы служб;
  • SC failure — задание действий, выполняемых при сбое службы;
  • SC qfailure — просмотр действий, выполняемых при сбое службы.

Во всех командах можно указывать имя удаленного компьютера, со службами которого Вы хотите работать. Для этого вставьте UNC-имя или IP-адрес компьютера перед используемой подкомандой. Вот синтаксис:

  
  sc ИмяСервера Подкоманда

Перезагрузка и выключение систем из командной строки

Системы нередко приходится перезагружать или выключать. Один из способов — использовать для этого утилиту Shutdown, которая позволяет работать с локальной и удаленными системами. Другой способ управлять выключением или перезагрузкой системы — назначить задание для выключения. Здесь можно использовать Schtasks, чтобы указать время выключения, или создать сценарий со списком команд выключения для индивидуальных систем.

Управлять перезагрузкой и выключением локальной системы позволяют следующие команды.

Выключение локальной системы:

  
  shutdown /s /t ЗадержкаВыключения /1 /f

Перезагрузка локальной системы:

  
  shutdown /r /t ЗадержкаВыключения /1 /f

Управление приложениями, процессами и производительностью

Всякий раз, когда операционная система или пользователь запускает службу, приложение или команду, Microsoft Windows запускает один или более процессов для управления соответствующей программой. Несколько утилит командной строки упростят вам мониторинг программ и управление ими. К этим утилитам относятся:

  • Pmon (Process Resource Manager) — показывает статистические данные по производительности, включая использование памяти и процессора, а также список всех процессов, выполняемых в локальной системе. Позволяет получать детальные «снимки» задействованных ресурсов и выполняемых процессов. Pmon поставляется с Windows Resource Kit;
  • Tasklist (Task List) — перечисляет все выполняемые процессы по имени и идентификатору процесса, сообщает информацию о сеансе пользователя и занимаемой памяти;
  • Taskkill (Task Kill) — останавливает выполнение процесса, заданного по имени или идентификатору. С помощью фильтров можно останавливать процессы в зависимости от их состояния, номера сеанса, процессорного времени, занимаемой памяти, имени пользователя и других параметров.

Вот в принципе все, что я хотел рассказать об основах командной строки Windows.

Command Description Append The append command can be used by programs to open files in another directory as if they were located in the current directory. The append command is available in MS-DOS as well as in all 32-bit versions of Windows. The append command is not available in 64-bit versions of Windows. Arp The arp command is used to display or change entries in the ARP cache. The arp command is available in all versions of Windows. Assoc The assoc command is used to display or change the file type associated with a particular file extension. The assoc command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. At The at command is used to schedule commands and other programs to run at a specific date and time. The at command is available in Windows 7, Windows Vista, and Windows XP. Beginning in Windows 8, command line task scheduling should instead be completed with the schtasks command. Atmadm The atmadm command is used to display information related to asynchronous transfer mode (ATM) connections on the system. The atmadm command is available in Windows XP. Support for ATM was removed beginning in Windows Vista, making the atmadm command unnecessary. Attrib The attrib command is used to change the attributes of a single file or a directory. The attrib command is available in all versions of Windows, as well as in MS-DOS. Auditpol The auditpol command is used to display or change audit policies. The auditpol command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Bcdboot The bcdboot command is used to copy boot files to the system partition and to create a new system BCD store. The bcdboot command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Bcdedit The bcdedit command is used to view or make changes to Boot Configuration Data. The bcdedit command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. The bcdedit command replaced the bootcfg command beginning in Windows Vista. Bdehdcfg The bdehdcfg command is used to prepare a hard drive for BitLocker Drive Encryption. The bdehdcfg command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Bitsadmin The bitsadmin command is used to create, manage, and monitor download and upload jobs. The bitsadmin command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. While the bitsadmin command is available in those versions of Windows, it is being phased out—the BITS PowerShell cmdlets should be used instead. Bootcfg The bootcfg command is used to build, modify, or view the contents of the boot.ini file, a hidden file that is used to identify in what folder, on which partition, and on which hard drive Windows is located. The bootcfg command is available in Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The bootcfg command was replaced by the bcdedit command beginning in Windows Vista. Bootcfg is still available in Windows 10, 8, 7, and Vista, but it serves no real value since boot.ini is not used in these operating systems. Bootsect The bootsect command is used to configure the master boot code to one compatible with BOOTMGR (Vista and later) or NTLDR (XP and earlier). The bootsect command is available in Windows 11, Windows 10, and Windows 8. The bootsect command is also available in Windows 7 and Windows Vista but only from the Command Prompt available in System Recovery Options. Break The break command sets or clears extended CTRL+C checking on DOS systems. The break command is available in all versions of Windows, as well as in MS-DOS. The break command is available in Windows XP and later versions of Windows to provide compatibility with MS-DOS files but it has no effect in Windows itself. Cacls The cacls command is used to display or change access control lists of files. The cacls command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The cacls command is being phased out in favor of the icacls command, which should be used instead in all versions of Windows after Windows XP. Call The call command is used to run a script or batch program from within another script or batch program. The call command is available in all versions of Windows, as well as in MS-DOS. The call command has no effect outside of a script or batch file. In other words, running the call command at the Command Prompt or MS-DOS prompt will do nothing. Cd The cd command is the shorthand version of the chdir command. The cd command is available in all versions of Windows, as well as in MS-DOS. Certreq The certreq command is used to perform various certification authority (CA) certificate functions. The certreq command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Certutil The certutil command is used to dump and display certification authority (CA) configuration information in addition to other CA functions. The certutil command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Change The change command changes various terminal server settings like install modes, COM port mappings, and logons. The change command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Chcp The chcp command displays or configures the active code page number. The chcp command is available in all versions of Windows, as well as in MS-DOS. Chdir The chdir command is used to display the drive letter and folder that you are currently in. Chdir can also be used to change the drive and/or directory that you want to work in. The chdir command is available in all versions of Windows, as well as in MS-DOS. Checknetisolation The checknetisolation command is used to test apps that require network capabilities. The checknetisolation command is available in Windows 11, Windows 10, and Windows 8. Chglogon The chglogon command enables, disables, or drains terminal server session logins. The chglogon command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Executing the chglogon command is the same as executing change logon. Chgport The chgport command can be used to display or change COM port mappings for DOS compatibility. The chgport command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Executing the chgport command is the same as executing change port. Chgusr The chgusr command is used to change the install mode for the terminal server. The chgusr command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Executing the chgusr command is the same as executing change user. Chkdsk The chkdsk command, often referred to as check disk, is used to identify and correct certain hard drive errors. The chkdsk command is available in all versions of Windows, as well as in MS-DOS. Chkntfs The chkntfs command is used to configure or display the checking of the disk drive during the Windows boot process. The chkntfs command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Choice The choice command is used within a script or batch program to provide a list of choices and return the value of that choice to the program. The choice command is available in MS-DOS and all versions of Windows except Windows XP. Use the set command with the /p switch in place of the choice command in batch files and scripts that you plan to use in Windows XP. Cipher The cipher command shows or changes the encryption status of files and folders on NTFS partitions. The cipher command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Clip The clip command is used to redirect the output from any command to the clipboard in Windows. The clip command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Cls The cls command clears the screen of all previously entered commands and other text. The cls command is available in all versions of Windows, as well as in MS-DOS. Cmd The cmd command starts a new instance of the cmd.exe command interpreter. The cmd command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Cmdkey The cmdkey command is used to show, create, and remove stored user names and passwords. The cmdkey command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Cmstp The cmstp command installs or uninstalls a Connection Manager service profile. The cmstp command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Color The color command is used to change the colors of the text and background within the Command Prompt window. The color command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Command The command command starts a new instance of the command.com command interpreter. The command command is available in MS-DOS as well as in all 32-bit versions of Windows. The command command is not available in 64-bit versions of Windows. Comp The comp command is used to compare the contents of two files or sets of files. The comp command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Compact The compact command is used to show or change the compression state of files and directories on NTFS partitions. The compact command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Convert The convert command is used to convert FAT or FAT32 formatted volumes to the NTFS format. The convert command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Copy The copy command does simply that — it copies one or more files from one location to another. The copy command is available in all versions of Windows, as well as in MS-DOS. The xcopy command is considered to be a more «powerful» version of the copy command. Cscript The cscript command is used to execute scripts via Microsoft Script Host. The cscript command is available in all versions of Windows. The cscript command is most popularly used to manage printers from the command line using scripts like prncnfg.vbs, prndrvr.vbs, prnmngr.vbs, and others. Ctty The ctty command is used to change the default input and output devices for the system. The ctty command is available in Windows 98 and 95 as well as in MS-DOS. The functions provided by the ctty command were no longer necessary beginning in Windows XP because the command.com interpreter (MS-DOS) is no longer the default command line interpreter. Date The date command is used to show or change the current date. The date command is available in all versions of Windows, as well as in MS-DOS. Dblspace The dblspace command is used to create or configure DoubleSpace compressed drives. The dblspace command is available in Windows 98 and 95, as well as in MS-DOS. DriveSpace, executed using the drvspace command, is an updated version of DoubleSpace. Windows began handling compression beginning in Windows XP. Debug The debug command starts Debug, a command line application used to test and edit programs. The debug command is available in MS-DOS as well as in all 32-bit versions of Windows. The debug command is not available in 64-bit versions of Windows. Defrag The defrag command is used to defragment a drive you specify. The defrag command is the command line version of Microsoft’s Disk Defragmenter. The defrag command is available in all versions of Windows, as well as in MS-DOS. Del The del command is used to delete one or more files. The del command is available in all versions of Windows, as well as in MS-DOS. The del command is the same as the erase command. Deltree The deltree command is used to delete a directory and all the files and subdirectories within it. The deltree command is available in Windows 98 and 95, as well as in MS-DOS. Beginning in Windows XP, a folder and its files and subfolders can be removed using the /s function of the rmdir command. Deltree was no longer needed with this new rmdir ability so the command was removed. Diantz The diantz command is used to losslessly compress one or more files. The diantz command is sometimes called Cabinet Maker. The diantz command is available in Windows 7, Windows Vista, and Windows XP. The diantz command is the same as the makecab command. Dir The dir command is used to display a list of files and folders contained inside the folder that you are currently working in. The dir command also displays other important information like the hard drive’s serial number, the total number of files listed, their combined size, the total amount of free space left on the drive, and more. The dir command is available in all versions of Windows, as well as in MS-DOS. Diskcomp The diskcomp command is used to compare the contents of two floppy disks. The diskcomp command is available in all versions of Windows, as well as in MS-DOS, with the exclusion of Windows 11 and Windows 10. Diskcopy The diskcopy command is used to copy the entire contents of one floppy disk to another. The diskcopy command is available in all versions of Windows, as well as in MS-DOS, with the exclusion of Windows 11 and Windows 10. Diskpart The diskpart command is used to create, manage, and delete hard drive partitions. The diskpart command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The diskpart command replaced the fdisk command beginning in Windows XP. Diskperf The diskperf command is used to manage disk performance counters remotely. The diskperf command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Diskraid The diskraid command starts the DiskRAID tool which is used to manage and configure RAID arrays. The diskraid command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Dism The dism command starts the Deployment Image Servicing and Management tool (DISM). The DISM tool is used to manage features in Windows images. The dism command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Dispdiag The dispdiag command is used to output a log of information about the display system. The dispdiag command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Djoin The djoin command is used to create a new computer account in a domain. The djoin command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Doskey The doskey command is used to edit command lines, create macros, and recall previously entered commands. The doskey command is available in all versions of Windows, as well as in MS-DOS. Dosshell The dosshell command starts DOS Shell, a graphical file management tool for MS-DOS. The dosshell command is available in Windows 95 (in MS-DOS mode) and also in MS-DOS version 6.0 and later MS-DOS versions that were upgraded from previous versions that contained the dosshell command. A graphical file manager, Windows Explorer, became an integrated part of the operating system beginning in Windows 95. Dosx The dosx command is used to start DOS Protected Mode Interface (DPMI), a special mode designed to give MS-DOS applications access to more than the normally allowed 640 KB. The dosx command is available in Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The dosx command is not available in 64-bit versions of Windows. The dosx command and DPMI is only available in Windows to support older MS-DOS programs. Driverquery The driverquery command is used to show a list of all installed drivers. The driverquery command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Drvspace The drvspace command is used to create or configure DriveSpace compressed drives. The drvspace command is available in Windows 98 and 95, as well as in MS-DOS. DriveSpace is an updated version of DoubleSpace, executed using the dblspace command. Windows began handling compression beginning in Windows XP. Echo The echo command is used to show messages, most commonly from within script or batch files. The echo command can also be used to turn the echoing feature on or off. The echo command is available in all versions of Windows, as well as in MS-DOS. Edit The edit command starts the MS-DOS Editor tool which is used to create and modify text files. The edit command is available in MS-DOS as well as in all 32-bit versions of Windows. The edit command is not available in 64-bit versions of Windows. Edlin The edlin command starts the Edlin tool which is used to create and modify text files from the command line. The edlin command is available in all 32-bit versions of Windows but is not available in 64-bit versions of Windows. In MS-DOS, the edlin command is only available up to MS-DOS 5.0, so unless your later version of MS-DOS was upgraded from 5.0 or prior, you won’t see the edlin command. Emm386 The emm386 command is used to give MS-DOS access to more than 640 KB of memory (RAM). The emm386 command is available in Windows 98 and 95, as well as in MS-DOS. Windows itself has access to extended and expanded memory beginning in Windows 95. Endlocal The endlocal command is used to end the localization of environment changes inside a batch or script file. The endlocal command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Erase The erase command is used to delete one or more files. The erase command is available in all versions of Windows, as well as in MS-DOS. The erase command is the same as the del command. Esentutl The esentutl command is used to manage Extensible Storage Engine databases. The esentutl command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Eventcreate The eventcreate command is used to create a custom event in an event log. The eventcreate command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Eventtriggers The eventtriggers command is used to configure and display event triggers. The eventtriggers command is available in Windows XP. Beginning in Windows Vista, event triggers are created using the Attach Task To This Event feature in Event Viewer, making the eventtriggers command unnecessary. Exe2bin The exe2bin command is used to convert a file of the EXE file type (executable file) to a binary file. The exe2bin command is available in 32-bit versions of Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The exe2bin command is not available in any 64-bit version of Windows. Exit The exit command is used to end the cmd.exe (Windows) or command.com (MS-DOS) session that you’re currently working in. The exit command is available in all versions of Windows, as well as in MS-DOS. Expand The expand command is used to extract the files and folders contained in Microsoft Cabinet (CAB) files. The expand command is available in MS-DOS as well as in all versions of Windows. The expand command is not available in the 64-bit version of Windows XP. Extrac32 The extrac32 command is used to extract the files and folders contained in Microsoft Cabinet (CAB) files. The extrac32 command is available in all versions of Windows. The extrac32 command is actually a CAB extraction program that can extract any Microsoft Cabinet file. Use the expand command instead of the extrac32 command if possible. Extract The extract command is used to extract the files and folders contained in Microsoft Cabinet (CAB) files. The extract command is available in Windows 98 and 95. The extract command was replaced by the expand command beginning in Windows XP. Fasthelp The fasthelp command provides more detailed information on any of the other MS-DOS commands. The fasthelp command is only available in MS-DOS. The help command replaced the fasthelp command beginning in Windows 95. Fastopen The fastopen command is used to add a program’s hard drive location to a special list stored in memory, potentially improving the program’s launch time by removing the need for MS-DOS to locate the application on the drive. The fastopen command is available in MS-DOS as well as in all 32-bit versions of Windows. The fastopen command is not available in 64-bit versions of Windows. Fastopen is only available in Windows 10, Windows 8, 7, Vista, and XP to support older MS-DOS files. Fc The fc command is used to compare two individual or sets of files and then show the differences between them. The fc command is available in all versions of Windows, as well as in MS-DOS. Fdisk The fdisk command is used to create, manage, and delete hard drive partitions. The fdisk command is available in Windows 98 and 95, as well as in MS-DOS. The fdisk command was replaced by the diskpart command beginning in Windows XP. Partition management is also available from Disk Management in Windows 11, 10, 8, 7, Vista, and XP. Find The find command is used to search for a specified text string in one or more files. The find command is available in all versions of Windows, as well as in MS-DOS. Findstr The findstr command is used to find text string patterns in one or more files. The findstr command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Finger The finger command is used to return information about one or more users on a remote computer that’s running the Finger service. The finger command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Fltmc The fltmc command is used to load, unload, list, and otherwise manage Filter drivers. The fltmc command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Fondue The fondue command, short for Features on Demand User Experience Tool, is used to install any of the several optional Windows features from the command line. The fondue command is available in Windows 11, Windows 10, and Windows 8. Optional Windows features can also be installed from the Programs and Features applet in Control Panel. For The for command is used to run a specified command for each file in a set of files. The for command is most often used within a batch or script file. The for command is available in all versions of Windows, as well as in MS-DOS. Forcedos The forcedos command is used to start the specified program in the MS-DOS subsystem. The forcedos command is only available in 32-bit versions of Windows XP. The forcedos command is only used for MS-DOS programs that are not recognized as such by Windows XP. Forfiles The forfiles command selects one or more files to execute a specified command on. The forfiles command is most often used within a batch or script file. The forfiles command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Format The format command is used to format a drive in the file system that you specify. The format command is available in all versions of Windows, as well as in MS-DOS. Drive formatting is also available from Disk Management in Windows 11, 10, 8, 7, Vista, and XP. Fsutil The fsutil command is used to perform various FAT and NTFS file system tasks like managing reparse points and sparse files, dismounting a volume, and extending a volume. The fsutil command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Ftp The ftp command can be used to transfer files to and from another computer. The remote computer must be operating as an FTP server. The ftp command is available in all versions of Windows. Ftype The ftype command is used to define a default program to open a specified file type. The ftype command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Getmac The getmac command is used to display the media access control (MAC) address of all the network controllers on a system. The getmac command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Goto The goto command is used in a batch or script file to direct the command process to a labeled line in the script. The goto command is available in all versions of Windows, as well as in MS-DOS. Gpresult The gpresult command is used to display Group Policy settings. The gpresult command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Gpupdate The gpupdate command is used to update Group Policy settings. The gpupdate command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Graftabl The graftabl command is used to enable the ability of Windows to display an extended character set in graphics mode. The graftabl command is available in all versions of Windows and in MS-DOS up to version 5.0. The graftabl command is not available in 64-bit versions of Windows. Graphics The graphics command is used to load a program that can print graphics. The graphics command is available in MS-DOS as well as in all 32-bit versions of Windows. The graphics command is not available in 64-bit versions of Windows. Help The help command provides more detailed information on any of the other Command Prompt or MS-DOS commands. The help command is available in all versions of Windows, as well as in MS-DOS. Hostname The hostname command displays the name of the current host. The hostname command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Hwrcomp The hwrcomp command is used to compile custom dictionaries for handwriting recognition. The hwrcomp command is available in Windows 8 and Windows 7. Hwrreg The hwrreg command is used to install a previously compiled custom dictionary for handwriting recognition. The hwrreg command is available in Windows 8 and Windows 7. Icacls The icacls command is used to display or change access control lists of files. The icacls command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. The icacls command is an updated version of the cacls command. If The if command is used to perform conditional functions in a batch file. The if command is available in all versions of Windows, as well as in MS-DOS. Interlnk The interlnk command is used to connect two computers via a serial or parallel connection to share files and printers. The interlnk command is only available in MS-DOS. The ability to directly connect two computers is handled by the networking functions in all versions of Windows. Intersvr The intersvr command is used to start the Interlnk server and to copy Interlnk files from one computer to another. The intersvr command is only available in MS-DOS. The ability to directly connect two computers is handled by the networking functions in all versions of Windows. Ipconfig The ipconfig command is used to display detailed IP information for each network adapter utilizing TCP/IP. The ipconfig command can also be used to release and renew IP addresses on systems configured to receive them via a DHCP server. The ipconfig command is available in all versions of Windows. Ipxroute The ipxroute command is used to display and change information about IPX routing tables. The ipxroute command is available in Windows XP. Microsoft removed their built-in NetWare client beginning in Windows Vista, removing the associated ipxroute command as well. Irftp The irftp command is used to transmit files over an infrared link. The irftp command is available in Windows 8, Windows 7, and Windows Vista. Iscsicli The iscsicli command starts the Microsoft iSCSI Initiator, used to manage iSCSI. The iscsicli command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Kb16 The kb16 command is used to support MS-DOS files that need to configure a keyboard for a specific language. The kb16 command is available in Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The kb16 command is not available in 64-bit versions of Windows. The kb16 command replaced the keyb command beginning in Windows XP but only exists to support older MS-DOS files. Keyb The keyb command is used to configure a keyboard for a specific language. The keyb command is available in Windows 98 and 95, as well as in MS-DOS. See the kb16 command for an equivalent command in later versions of Windows. Keyboard language settings are handled by the Region and Language or Regional and Language Options (depending on the version of Windows) Control Panel applets in Windows beginning in Windows XP. Klist The klist command is used to list Kerberos service tickets. The klist command can also be used to purge Kerberos tickets. The klist command is available in Windows 11, Windows 10, Windows 8 and Windows 7. Ksetup The ksetup command is used to configure connections to a Kerberos server. The ksetup command is available in Windows 11, Windows 10, Windows 8 and Windows 7. Ktmutil The ktmutil command starts the Kernel Transaction Manager utility. The ktmutil command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Label The label command is used to manage the volume label of a disk. The label command is available in all versions of Windows, as well as in MS-DOS. Lh The lh command is the shorthand version of the loadhigh command. The lh command is available in Windows 98 and 95, as well as in MS-DOS. Licensingdiag The licensingdiag command is a tool used to generate a text-based log and other data files that contain product activation and other Windows licensing information. The licensingdiag command is available in Windows 11, Windows 10, and Windows 8. Loadfix The loadfix command is used to load the specified program in the first 64K of memory and then runs the program. The loadfix command is available in MS-DOS as well as in all 32-bit versions of Windows. The loadfix command is not available in 64-bit versions of Windows. Loadhigh The loadhigh command is used to load a program into high memory and is usually used from within the autoexec.bat file. The loadhigh command is available in Windows 98 and 95, as well as in MS-DOS. Memory usage is handled automatically beginning in Windows XP. Lock The lock command is used to lock a drive, enabling direct disk access for a program. The lock command is only available in Windows 98 and 95. Drive locking is no longer available as of Windows XP. Lodctr The lodctr command is used to update registry values related to performance counters. The lodctr command is available in all versions of Windows. Logman The logman command is used to create and manage Event Trace Session and Performance logs. The logman command also supports many functions of Performance Monitor. The logman command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Logoff The logoff command is used to terminate a session. The logoff command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Lpq The lpq command displays the status of a print queue on a computer running Line Printer Daemon (LPD). The lpq command is available in all versions of Windows. The lpq command is not available by default in Windows 11, 10, 8, 7, or Vista, but can be enabled by turning on the LPD Print Service and LPR Port Monitor features from Programs and Features in Control Panel. Lpr The lpr command is used to send a file to a computer running Line Printer Daemon (LPD). The lpr command is available in all versions of Windows. The lpr command is not available by default in Windows 11, 10, 8, 7, or Vista, but can be enabled by turning on the LPD Print Service and LPR Port Monitor features from Programs and Features in Control Panel. Makecab The makecab command is used to losslessly compress one or more files. The makecab command is sometimes called Cabinet Maker. The makecab command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The makecab command is the same as the diantz command, a command that was removed after Windows 7. Manage-bde The manage-bde command is used to configure BitLocker Drive Encryption from the command line. The manage-bde command is available in Windows 11, Windows 10, Windows 8, and Windows 7. A script by the name of manage-bde.wsf exists in Windows Vista and can be used with the cscript command to perform BitLocker tasks from the command line in that operating system. Md The md command is the shorthand version of the mkdir command. The md command is available in all versions of Windows, as well as in MS-DOS. Mem The mem command shows information about used and free memory areas and programs that are currently loaded into memory in the MS-DOS subsystem. The mem command is available in MS-DOS as well as in all 32-bit versions of Windows. The mem command is not available in 64-bit versions of Windows. Memmaker The memmaker command is used to start MemMaker, a memory optimization tool. The memaker command is available in Windows 98 and 95, as well as in MS-DOS. Memory usage is automatically optimized beginning in Windows XP. Mkdir The mkdir command is used to create a new folder. The mkdir command is available in all versions of Windows, as well as in MS-DOS. Mklink The mklink command is used to create a symbolic link. The mklink command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Mode The mode command is used to configure system devices, most often COM and LPT ports. The mode command is available in all versions of Windows, as well as in MS-DOS. Mofcomp The mofcomp command properly displays the data within a Managed Object Format (MOF) file. The mofcomp command is available in all versions of Windows. More The more command is used to display the information contained in a text file. The more command can also be used to paginate the results of any other Command Prompt or MS-DOS command. The more command is available in all versions of Windows, as well as in MS-DOS. Mount The mount command is used to mount Network File System (NFS) network shares. The mount command is available in Windows 7 and Windows Vista. The mount command is not available by default in Windows Vista or Windows 7 but can be enabled by turning on the Services for NFS Windows feature from Programs and Features in Control Panel. The mount command is not available in Windows 11, 10, or 8 because Service for UNIX (SFU) was discontinued. Mountvol The mountvol command is used to display, create, or remove volume mount points. The mountvol command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Move The move command is used to move one or files from one folder to another. The move command is also used to rename directories. The move command is available in all versions of Windows, as well as in MS-DOS. Mrinfo The mrinfo command is used to provide information about a router’s interfaces and neighbors. The mrinfo command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Msav The msav command starts Microsoft Antivirus. The msav command is only available in MS-DOS. Microsoft Antivirus was designed for MS-DOS and Windows 3.x only. Microsoft provides an optional virus protection suite called Microsoft Security Essentials for Windows XP and later operating systems, and third party antivirus tools are available for all versions of Windows. Msbackup The msbackup command starts Microsoft Backup, a tool used to back up and restore one or more files. The msbackup command is only available in MS-DOS. The msbackup command was replaced with Microsoft Backup beginning in Windows 95 and then Backup and Restore in later versions of Windows. Mscdex The mscdex command is used to provide CD-ROM access to MS-DOS. The mscdex command is available in Windows 98 and 95, as well as in MS-DOS. Windows provides access to CD-ROM drives for the MS-DOS subsystem beginning in Windows XP, so the mscdex command is unnecessary in this and later operating systems. Msd The msd command starts Microsoft Diagnostics, a system information tool. The msd command is only available in MS-DOS. The msd command was replaced with System Information beginning in Windows 95. Msg The msg command is used to send a message to a user. The msg command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Msiexec The msiexec command is used to start Windows Installer, a tool used to install and configure software. The msiexec command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Muiunattend The muiunattend command starts the Multilanguage User Interface unattended setup process. The muiunattend command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Nbtstat The nbtstat command is used to show TCP/IP information and other statistical information about a remote computer. The nbtstat command is available in all versions of Windows. Net The net command is used to display, configure, and correct a wide variety of network settings. The net command is available in all versions of Windows. Net1 The net1 command is used to display, configure, and correct a wide variety of network settings. The net1 command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The net command should be used instead of the net1 command. The net1 command was made available in Windows NT and Windows 2000 as a temporary fix for a Y2K issue that the net command had, which was corrected before the release of Windows XP. The net1 command remains in later versions of Windows only for compatibility with older programs and scripts that utilized the command. Netcfg The netcfg command is used to install the Windows Preinstallation Environment (WinPE), a lightweight version of Windows used to deploy workstations. The netcfg command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Netsh The netsh command is used to start Network Shell, a command-line utility used to manage the network configuration of the local, or a remote, computer. The netsh command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Netstat The netstat command is most commonly used to display all open network connections and listening ports. The netstat command is available in all versions of Windows. Nfsadmin The nfsadmin command is used to manage Server for NFS or Client for NFS from the command line. The nfsadmin command is available in Windows 7 and Windows Vista. The nfsadmin command is not available by default in Windows Vista or Windows 7 but can be enabled by turning on the Services for NFS Windows feature from Programs and Features in Control Panel. The nfsadmin command is not available in Windows 11, 10, or 8 because Service for UNIX (SFU) was discontinued. Nlsfunc The nlsfunc command is used to load information specific to a particular country or region. The nlsfunc command is available in MS-DOS as well as in all 32-bit versions of Windows. The nlsfunc command is not available in 64-bit versions of Windows. Nlsfunc is only available in Windows 10, 8, 7, Vista, and XP to support older MS-DOS files. Nltest The nltest command is used to test secure channels between Windows computers in a domain and between domain controllers that are trusting other domains. The nltest command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Nslookup The nslookup is most commonly used to display the hostname of an entered IP address. The nslookup command queries your configured DNS server to discover the IP address. The nslookup command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Ntbackup The ntbackup command is used to perform various backup functions from the Command Prompt or from within a batch or script file. The ntbackup command is available in Windows XP. The ntbackup command was replaced with the wbadmin beginning in Windows Vista. Ntsd The ntsd command is used to perform certain command line debugging tasks. The ntsd command is available in Windows XP. The ntsd command was removed beginning in Windows Vista due to the addition of dump file support in Task Manager. Ocsetup The ocsetup command starts the Windows Optional Component Setup tool, used to install additional Windows features. The ocsetup command is available in Windows 8, Windows 7, and Windows Vista. Beginning in Windows 8, Microsoft is depreciating the ocsetup command in favor of the dism command. Openfiles The openfiles command is used to display and disconnect open files and folders on a system. The openfiles command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Path The path command is used to display or set a specific path available to executable files. The path command is available in all versions of Windows, as well as in MS-DOS. Pathping The pathping command functions much like the tracert command but will also report information about network latency and loss at each hop. The pathping command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Pause The pause command is used within a batch or script file to pause the processing of the file. When the pause command is used, a «Press any key to continue…» message displays in the command window. The pause command is available in all versions of Windows, as well as in MS-DOS. Pentnt The pentnt command is used to detect floating point division errors in the Intel Pentium chip. The pentnt command is also used to enable floating point emulation and disable floating point hardware. The pentnt command is available in Windows XP. The pentnt command was removed beginning in Windows Vista due to the lack of Intel Pentium CPU use at the time of this operating system release. Ping The ping command sends an Internet Control Message Protocol (ICMP) Echo Request message to a specified remote computer to verify IP-level connectivity. The ping command is available in all versions of Windows. Pkgmgr The pkgmgr command is used to start the Windows Package Manager from the Command Prompt. Package Manager installs, uninstalls, configures, and updates features and packages for Windows. The pkgmgr command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Pnpunattend The pnpunattend command is used to automate the installation of hardware device drivers. The pnpunattend command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Pnputil The pnputil command is used to start the Microsoft PnP Utility, a tool used to install a Plug and Play device from the command line. The pnputil command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Popd The popd command is used to change the current directory to the one most recently stored by the pushd command. The popd command is most often utilized from within a batch or script file. The popd command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Power The power command is used to reduce the power consumed by a computer by monitoring software and hardware devices. The power command is available in Windows 98 and 95, as well as in MS-DOS. The power command was replaced by operating system integrated power management functions beginning in Windows XP. Powercfg The powercfg command is used to manage the Windows power management settings from the command line. The powercfg command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Print The print command is used to print a specified text file to a specified printing device. The print command is available in all versions of Windows, as well as in MS-DOS. Prompt The prompt command is used to customize the appearance of the prompt text in Command Prompt or MS-DOS. The prompt command is available in all versions of Windows, as well as in MS-DOS. Pushd The pushd command is used to store a directory for use, most commonly from within a batch or script program. The pushd command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Pwlauncher The pwlauncher command is used to enable, disable, or show the status of your Windows To Go startup options. The pwlauncher command is available in Windows 11, 10, and 8. Qappsrv The qappsrv command is used to display all Remote Desktop Session Host servers available on the network. The qappsrv command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Qbasic The qbasic command starts QBasic, the MS-DOS based programming environment for the BASIC programming language. The qbasic command is available in Windows 98 and 95, as well as in MS-DOS. The qbasic command is not installed by default with Windows 98 or 95 but is available from the installation disc or disks. Qprocess The qprocess command is used to display information about running processes. The qprocess command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Query The query command is used to display the status of a specified service. The query command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Quser The quser command is used to display information about users currently logged on to the system. The quser command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Qwinsta The qwinsta command is used to display information about open Remote Desktop Sessions. The qwinsta command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Rasautou The rasautou command is used to manage Remote Access Dialer AutoDial addresses. The rasautou command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Rasdial The rasdial command is used to start or end a network connection for a Microsoft client. The rasdial command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Rcp The rcp command is used to copy files between a Windows computer and a system running the rshd daemon. The rcp command is available in Windows 7, Windows Vista, and Windows XP. The rcp command is not available by default in Windows Vista or Windows 7 but can be enabled by turning on the Subsystem for UNIX-based Applications Windows feature from Programs and Features in Control Panel and then installing the Utilities and SDK for UNIX-based Applications available here for Windows Vista and here for Windows 7. The rcp command is not available in Windows 11, 10, or 8 because Service for UNIX (SFU) was discontinued. Rd The rd command is the shorthand version of the rmdir command. The rd command is available in all versions of Windows, as well as in MS-DOS. Rdpsign The rdpsign command is used to sign a Remote Desktop Protocol (RDP) file. The rdpsign command is available in Windows 7. Reagentc The reagentc command is used to configure the Windows Recovery Environment (RE). The reagentc command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Recimg The recimg command is used to create a custom refresh image. The recimg command is available in Windows 8. Recover The recover command is used to recover readable data from a bad or defective disk. The recover command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Reg The reg command is used to manage the Windows Registry from the command line. The reg command can perform common registry functions like adding registry keys, exporting the registry, etc. The reg command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Regini The regini command is used to set or change registry permissions and registry values from the command line. The regini command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Register-cimprovider The register-cimprovider command is used to register a Common Information Model (CIM) Provider in Windows. The register-cimprovider command is available in Windows 11, Windows 10, and Windows 8. Regsvr32 The regsvr32 command is used to register a DLL file as a command component in the Windows Registry. The regsvr32 command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Relog The relog command is used to create new performance logs from data in existing performance logs. The relog command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Rem The rem command is used to record comments or remarks in a batch or script file. The rem command is available in all versions of Windows, as well as in MS-DOS. Ren The ren command is the shorthand version of the rename command. The ren command is available in all versions of Windows, as well as in MS-DOS. Rename The rename command is used to change the name of the individual file that you specify. The rename command is available in all versions of Windows, as well as in MS-DOS. Repair-bde The repair-bde command is used to repair or decrypt a damaged drive that’s been encrypted using BitLocker. The repair-bde command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Replace The replace command is used to replace one or more files with one or more other files. The replace command is available in all versions of Windows, as well as in MS-DOS. Reset The reset command, executed as reset session, is used to reset the session subsystem software and hardware to known initial values. The reset command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Restore The restore command is used to restore files that were backed up using the backup command. The restore command is only available in MS-DOS. The backup command was only available up to MS-DOS 5.00 but the restore command was included by default with later versions of MS-DOS to provide a way to restore files that were backed up in previous versions of MS-DOS. Rexec The rexec command is used to run commands on remote computers running the rexec daemon. The rexec command is available in Windows Vista and Windows XP. The rsh command is not available by default in Windows Vista but can be enabled by turning on the Subsystem for UNIX-based Applications Windows feature from Programs and Features in Control Panel and then installing the Utilities and SDK for UNIX-based Applications available here. The rexec command is not available in Windows 7 but can be executed in Windows XP via Windows XP Mode if need be. Rmdir The rmdir command is used to delete an existing or completely empty folder. The rmdir command is available in all versions of Windows, as well as in MS-DOS. Robocopy The robocopy command is used to copy files and directories from one location to another. This command is also called Robust File Copy. The robocopy command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. The robocopy command is superior to both the copy command and the xcopy command because robocopy supports many more options. Route The route command is used to manipulate network routing tables. The route command is available in all versions of Windows. Rpcinfo The rpcinfo command makes a remote procedure call (RPC) to an RPC server and reports what it finds. The rpcinfo command is available in Windows 7 and Windows Vista. The rpcinfo command is not available by default in Windows Vista or Windows 7 but can be enabled by turning on the Services for NFS Windows feature from Programs and Features in Control Panel. The rpcinfo command is not available in Windows 11, 10, or 8 because Service for UNIX (SFU) was discontinued. Rpcping The rpcping command is used to ping a server using RPC. The rpcping command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Rsh The rsh command is used to run commands on remote computers running the rsh daemon. The rsh command is available in Windows 7, Windows Vista, and Windows XP. The rsh command is not available by default in Windows Vista or Windows 7 but can be enabled by turning on the Subsystem for UNIX-based Applications Windows feature from Programs and Features in Control Panel and then installing the Utilities and SDK for UNIX-based Applications available here for Windows Vista and here for Windows 7. The rsh command is not available in Windows 11, 10, or 8 because Service for UNIX (SFU) was discontinued. Rsm The rsm command is used to manage media resources using Removable Storage. The rsm command is available in Windows Vista and Windows XP. The rsm command was optional in Windows Vista and then removed in Windows 7 due to Removable Storage Manager being removed from the operating system. Search for the rsm command in the C:Windowswinsxs folder in Windows Vista if you’re having trouble executing the command. Runas The runas command is used to execute a program using another user’s credentials. The runas command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Rwinsta The rwinsta command is the shorthand version of the reset session command. The rwinsta command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Sc The sc command is used to configure information about services. The sc command communicates with the Service Control Manager. The sc command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Scandisk The scandisk command is used to start Microsoft ScanDisk, a disk repair program. The scandisk command is available in Windows 98 and 95, as well as in MS-DOS. The scandisk command was replaced by the chkdsk command beginning in Windows XP. Scanreg The scanreg command starts Windows Registry Checker, a basic registry repair program and backup utility. The scanreg command is available in Windows 98 and Windows 95. The functions provided by the scanreg command were no longer necessary beginning in Windows XP due to changes in how the Windows Registry functions. Schtasks The schtasks command is used to schedule specified programs or commands to run at certain times. The schtasks command can be used to create, delete, query, change, run, and end scheduled tasks. The schtasks command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP.​ Sdbinst The sdbinst command is used to deploy customized SDB database files. The sdbinst command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Secedit The secedit command is used to configure and analyze system security by comparing the current security configuration to a template. The secedit command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Set The set command is used to display, enable, or disable environment variables in MS-DOS or from the Command Prompt. The set command is available in all versions of Windows, as well as in MS-DOS. Setlocal The setlocal command is used to start the localization of environment changes inside a batch or script file. The setlocal command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Setspn The setspn command is used to manage the Service Principal Names (SPN) for an Active Directory (AD) service account. The setspn command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Setver The setver command is used to set the MS-DOS version number that MS-DOS reports to a program. The setver command is available in MS-DOS as well as in all 32-bit versions of Windows. The setver command is not available in 64-bit versions of Windows. Setx The setx command is used to create or change environment variables in the user environment or the system environment. The setx command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Sfc The sfc command is used to verify and replace important Windows system files. The sfc command is also referred to as System File Checker or Windows Resource Checker, depending on the operating system. The sfc command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Shadow The shadow command is used to monitor another Remote Desktop Services session. The shadow command is available in Windows 7, Windows Vista, and Windows XP. Share The share command is used to install file locking and file sharing functions in MS-DOS. The share command is available in MS-DOS as well as in all 32-bit versions of Windows. The share command is not available in 64-bit versions of Windows. Share is only available in Windows 10, 8, 7, Vista, and XP to support older MS-DOS files. Shift The shift command is used to change the position of replaceable parameters in a batch or script file. The shift command is available in all versions of Windows, as well as in MS-DOS. Showmount The showmount command is used to display information about NFS mounted file systems. The showmount command is available in Windows 7 and Windows Vista. The showmount command is not available by default in Windows Vista or Windows 7 but can be enabled by turning on the Services for NFS Windows feature from Programs and Features in Control Panel. The showmount command is not available in Windows 11, 10, or 8 because Service for UNIX (SFU) was discontinued. Shutdown The shutdown command can be used to shut down, restart, or log off the current system or a remote computer. The shutdown command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Smartdrv The smartdrv command installs and configures SMARTDrive, a disk caching utility for MS-DOS. The smartdrv command is available in Windows 98 and 95, as well as in MS-DOS. Caching is automatic beginning in Windows XP, making the smartdrv command unnecessary. Sort The sort command is used to read data from a specified input, sort that data, and return the results of that sort to the Command Prompt screen, a file, or another output device. The sort command is available in all versions of Windows, as well as in MS-DOS. Start The start command is used to open a new command line window to run a specified program or command. The start command can also be used to start an application without creating a new window. The start command is available in all versions of Windows. Subst The subst command is used to associate a local path with a drive letter. The subst command is a lot like the net use command except a local path is used instead of a shared network path. The subst command is available in all versions of Windows, as well as in MS-DOS. The subst command replaced the assign command beginning with MS-DOS 6.0. Sxstrace The sxstrace command is used to start the WinSxs Tracing Utility, a programming diagnostic tool. The sxstrace command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Sys The sys command is used to copy the MS-DOS system files and command interpreter to a disk. The sys command is available in Windows 98 and 95, as well as in MS-DOS. The sys command is used most often to create a simple bootable disk or hard drive. The necessary system files for Windows are too large to fit on a disk, so the sys command was removed beginning in Windows XP. Systeminfo The systeminfo command is used to display basic Windows configuration information for the local or a remote computer. The systeminfo command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Takeown The takedown command is used to regain access to a file that that an administrator was denied access to when reassigning ownership of the file. The takeown command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Taskkill The taskkill command is used to terminate a running task. The taskkill command is the command line equivalent of ending a process in Task Manager in Windows. The taskkill command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tasklist Displays a list of applications, services, and the Process ID (PID) currently running on either a local or a remote computer. The tasklist command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tcmsetup The tcmsetup command is used to set up or disable the Telephony Application Programming Interface (TAPI) client. The tcmsetup command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Telnet The telnet command is used to communicate with remote computers that use the Telnet protocol. The telnet command is available in all versions of Windows. The telnet command is not available by default in Windows 11, 10, 8, 7, or Vista, but can be enabled by turning on the Telnet Client Windows feature from Programs and Features in Control Panel. Tftp The tftp command is used to transfer files to and from a remote computer that’s running the Trivial File Transfer Protocol (TFTP) service or daemon. The tftp command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The tftp command is not available by default in some versions of Windows, but can be enabled by turning on the TFTP Client Windows feature from Programs and Features in Control Panel. Time The time command is used to show or change the current time. The time command is available in all versions of Windows, as well as in MS-DOS. Timeout The timeout command is typically used in a batch or script file to provide a specified timeout value during a procedure. The timeout command can also be used to ignore keypresses. The timeout command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Title The title command is used to set the Command Prompt window title. The title command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tlntadmn The tlntadmn command is used to administer a local or remote computer running Telnet Server. The tlntadmn command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. The tlntadmn command is not available by default in some versions of Windows, but can be enabled by turning on the Telnet Server Windows feature from Programs and Features in Control Panel. Tpmvscmgr The tpmvscmgr command is used to create and destroy TPM virtual smart cards. The tpmvscmgr command is available in Windows 11, Windows 10, and Windows 8. Tracerpt The tracerpt command is used to process event trace logs or real-time data from instrumented event trace providers. The tracerpt command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tracert The tracert command sends Internet Control Message Protocol (ICMP) Echo Request messages to a specified remote computer with increasing Time to Live (TTL) field values and displays the IP address and hostname, if available, of the router interfaces between the source and destination. The tracert command is available in all versions of Windows. Tree The tree command is used to graphically display the folder structure of a specified drive or path. The tree command is available in all versions of Windows, as well as in MS-DOS. Tscon The tscon command is used to attach a user session to a Remote Desktop session. The tscon command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tsdiscon The tsdiscon command is used to disconnect a Remote Desktop session. The tsdiscon command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tskill The tskill command is used to end the specified process. The tskill command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tsshutdn The tsshutdn command is used to remotely shut down or restart a terminal server. The tsshutdn command is available in Windows XP. The ability to shut down a computer remotely is also available in the more powerful shutdown command, so tsshutdn was removed beginning in Windows Vista. Type The type command is used to display the information contained in a text file. The type command is available in all versions of Windows, as well as in MS-DOS. Typeperf The typerperf command displays performance data in the Command Prompt window or writes the data to specified log file. The typeperf command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Tzutil The tzutil command is used to display or configure the current system’s time zone. The tzutil command can also be used to enable or disable Daylight Saving Time adjustments. The tzutil command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Umount The umount command is used to remove Network File System (NFS) mounted network shares. The umount command is available in Windows 7 and Windows Vista. The umount command is not available by default in Windows Vista or Windows 7 but can be enabled by turning on the Services for NFS Windows feature from Programs and Features in Control Panel. The umount command is not available in Windows 11, 10, or 8 because Service for UNIX (SFU) was discontinued. Undelete The undelete command is used to undo a deletion performed with the MS-DOS delete command. The undelete command is only available in MS-DOS. The undelete command was removed beginning in Windows 95 due to the availability of the Recycle Bin in Windows. Additionally, free file recovery programs are available from third-party software makers. Unformat The unformat command is used to undo the formatting on a drive performed by the MS-DOS format command. The unformat command is only available in MS-DOS. The unformat command was removed beginning in Windows 95 due to file system changes. Unlock The unlock command is used to unlock a drive, disabling direct disk access for a program. The unlock command is only available in Windows 98 and 95. Drive locking is no longer available as of Windows XP. Unlodctr The unlodctr command removes Explain text and Performance counter names for a service or device driver from the Windows Registry. The unlodctr command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Vaultcmd The vaultcmd command is used to create, remove, and show stored credentials. The vaultcmd command is available in Windows 11, Windows 10, Windows 8, and Windows 7. Ver The ver command is used to display the current Windows or MS-DOS version number. The ver command is available in all versions of Windows, as well as in MS-DOS. Verify The verify command is used to enable or disable the ability of Command Prompt, or MS-DOS, to verify that files are written correctly to a disk. The verify command is available in all versions of Windows, as well as in MS-DOS. Vol The vol command shows the volume label and serial number of a specified disk, assuming this information exists. The vol command is available in all versions of Windows, as well as in MS-DOS. Vsafe The vsafe command is used to start VSafe, a basic virus protection system for MS-DOS. The vsafe command is only available in MS-DOS. VSafe was designed for MS-DOS and Windows 3.x only. Microsoft provides an optional virus protection suite called Microsoft Security Essentials for Windows XP and later operating systems, and third-party antivirus tools are available for all versions of Windows. Vssadmin The vssadmin command starts the Volume Shadow Copy Service administrative command line tool which displays current volume shadow copy backups and all installed shadow copy writers and providers. The vssadmin command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. W32tm The w32tm command is used to diagnose issues with Windows Time. The w32tm command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Waitfor The waitfor command is used to send or wait for a signal on a system. The waitfor command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Wbadmin The wbadmin command is used to start and stop backup jobs, display details about a previous backup, list the items within a backup, and report on the status of a currently running backup. The wbadmin command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. The wbadmin command replaced the ntbackup command beginning in Windows Vista. Wecutil The wecutil command is used to manage subscriptions to events that are forwarded from WS-Management supported computers. The wecutil command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Wevtutil The wevtutil command starts the Windows Events Command Line Utility which is used to manage event logs and publishers. The wevtutil command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Where The where command is used to search for files that match a specified pattern. The where command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Whoami The whoami command is used to retrieve user name and group information on a network. The whoami command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Winmgmt The winmgmt command starts the command line version of WMI, a scripting tool in Windows. The winmgmt command is available in all versions of Windows. Winrm The winrm command is used to start the command line version of Windows Remote Management, used to manage secure communications with local and remote computers using web services. The winrm command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Winrs The winrs command is used to open a secure command window with a remote host. The winrs command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Winsat The winsat command starts the Windows System Assessment Tool, a program that assesses various features, attributes, and capabilities of a computer running Windows. The winsat command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Wmic The wmic command starts the Windows Management Instrumentation Command line (WMIC), a scripting interface that simplifies the use of Windows Management Instrumentation (WMI) and systems managed via WMI. The wmic command is available in Windows 11, Windows 10, Windows 8, Windows 7, Windows Vista, and Windows XP. Wsmanhttpconfig The wsmanhttpconfig command is used to manage aspects of the Windows Remote Management (WinRM) service. The wsmanhttpconfig command is available in Windows 11, Windows 10, Windows 8, Windows 7, and Windows Vista. Xcopy The xcopy command can copy one or more files or directory trees from one location to another. The xcopy command is generally considered a more «powerful» version of the copy command through the robocopy command trumps even xcopy. The xcopy command is available in all versions of Windows, as well as in MS-DOS. A command by the name of xcopy32 existed in Windows 95 and Windows 98. To avoid a long and confusing explanation here, just know that no matter if you executed the xcopy command or the xcopy32 command, you were always executing the most updated version of the command. Xwizard The xwizard command, short for Extensible Wizard, is used to register data in Windows, often from a preconfigured XML file. The xwizard command is available in Windows 11, Windows 10, Windows 8, and Windows 7.

В статье пойдет речь об инструменте командной строки в Windows, основных принципах работы с ней и наиболее полезных командах, которые способны существенно облегчить работу с операционной системой.

Оглавление

  • Командная строка в Windows: CMD и PowerShell
  • Как открыть командную строку
  • Как вводить cmd команды
    • Как вывести результат команды из CMD в текстовый файл
    • Как применить команду сразу к нескольким файлам
    • Как вызвать подсказку
  • Команды cmd с файлами
    • Стандартные действия с файлами – создание, удаление, копирование и пр.
    • Сравнить два файла – FC и COMP
    • Найти слово в файле – FIND
    • Создать файл определенного размера – FSUTIL FILE CREATENEW
    • Удалить отметку последнего открытия файла – FSUTIL BEHAVIOR SET DISABLELASTACCESS 1
  • Посмотреть информацию о компьютере, ОС и т. п.
    • Проверить свободное место на диске – FSUTIL VOLUME DISKFREE C:
    • Установленные драйверы – DRIVERQUERY
    • Все сведения об операционной системе – SYSTEMINFO
  • Выполнить диагностику Windows
    • Проверить диск на ошибки – CHKDSK
    • Проверка системных файлов – SFC
  • Поменять настройки Windows
    • Включить или отключить гибернацию – POWERCFG /H <ON|OFF>
    • Настройки конфигурации системы – MSCONFIG
    • Редактировать реестр – REGEDIT и REG
  • Сетевые команды CMD
    • Настройка протокола IP – IPCONFIG
    • Узнать имя компьютера – HOSTNAME
    • Диагностика сети: пинг и трассировка – PING, TRACERT, PATHPING

Командная строка в Windows: CMD и PowerShell

Командная строка (она же консоль или интерпретатор команд) – это программа для управления операционной системой посредством ввода специальных текстовых команд. В Windows 10 есть два инструмента командной строки: cmd.exe и PowerShell. И если cmd была еще в самых древних версиях системы, то PowerShell появилась в Windows уже после 2005 года. Она выполняла те же функции, что и cmd, выглядела почти так же, но имела более широкие возможности. У PowerShell свой, отличный от cmd.exe язык, и она рассчитана в основном на работу с так называемыми командлетами, у которых немного другой синтаксис, и почти для каждой команды cmd есть свой аналогичный командлет у PowerShell. Однако все команды cmd можно использовать в их первоначальном виде в PowerShell.

Как открыть командную строку

Есть куча способов вызвать командную строку. Рассмотрим несколько из них. Обратите внимание, что для использования некоторых команд требуется запустить командную строку с правами Администратора, поэтому сразу наматывайте на ус, как это делается.

Вызываем CMD в Widows 10

  • Меню «Пуск» > Из списка программ выбираем «Служебные» > Жмем правой кнопкой мыши по пункту «Командная строка» > Выбираем пункт «Дополнительно», а в нем «Запуск от имени Администратора».
  • Нажмите комбинацию клавиш «Win + R» > в появившемся окне «Выполнить» вбиваем «cmd» и жмем Enter, а если хотим запустить программу с правами Админа, то жмем «Ctrl + Shift + Enter».
  • В Поиске (рядом с меню «Пуск») набираем «Командная строка» или «cmd», и в результатах выбираем вариант запуска программы от Администратора.

Вызываем PowerShell в Widows 10

  • С помощью двух предыдущих способов можно также вызвать и PowerShell, если вписать его название вместо cmd.
  • Правый клик по меню «Пуск» > в выпавшем меню выбираем запуск Windows PowerShell от Администратора.

Как вводить cmd команды

Общий порядок ввода команды в строку следующий:

  1. Сначала вводим основную команду;
  2. Если у нее есть дополнительные параметры, вводим их через пробел и знак слэш — /
  3. Далее, если требуется, прописываем путь к нужному файлу, начиная с корневой директории. Если в названиях промежуточных папок этого пути встречаются пробелы, то весь путь заключаем в кавычки. Например: «C:UsersUSERNAMEDesktopСписок команд cmd.txt»
  4. После того, как мы написали команду со всеми доп. параметрами, нажимаем Enter, чтобы начать ее выполнение.

Не имеет значения, в каком регистре писать команды, но почему-то сложился обычай писать их в верхнем.

Например, чтобы посмотреть список установленных на компьютере драйверов устройств необходимо выполнить команду DRIVERQUERY. Но если вы еще хотите увидеть в этом списке подробную информацию об их состоянии, введите через пробел после команды дополнительный параметр /V. А чтобы эти данные выводились в формате таблицы, пропишите в команде еще один параметр /FO TABLE. Итоговая запись будет выглядеть так: DRIVERQUERY /V /FO TABLE

Как вывести результат команды из CMD в текстовый файл

«>» – Вывод данных результата выполнения команды в отдельный файл.

«>>» – Записать данные результата выполнения команды в конец существующего файла.

Если хотите вывести данные о драйверах не на экран консоли, а в текстовый файл, то после команды со всеми доп. параметрами пропишите знак «>» и далее пропишите путь к файлу.
Пример: DRIVERQUERY /V /FO TABLE > C:UsersLohmachDesktopДрайверы.txt

Если файла не существует, то он будет создан, если такой файл уже есть, то данные в нем перезапишутся.

Для того, чтобы файл не перезаписывался, а дополнялся новыми данными в конце, пропишите знак «>>» перед указанием пути к файлу. Например, выведем в конце нашего файла «Драйверы.txt» список только подписанных драйверов. Прописываем команду: DRIVERQUERY /SI >> C:UsersLohmachDesktopДрайверы.txt

Как применить команду сразу к нескольким файлам

*.* – обращение ко всем файлам каталога
*.txt – обращение ко всем файлам только формата txt

Указав знак * вместо имени конкретного файла, вы сможете одной командой сразу «убить всех зайцев». Например, чтобы переместить все файлы из папки «Работа» на диске C в папку «Все рабочие файлы» на диске D с помощью команды MOVE, сделайте запись в командной строке такого типа: move «C:UsersUSERNAMEДокументыРабота*.*» «D:Все рабочие файлы»

Как вызвать подсказку

Для работы с CMD совсем необязательно знать список всех команд и их свойств. Если ввести в консоли HELP – отобразится полный список cmd команд c их кратким описанием. А чтобы получить подсказку по конкретной команде, введите через пробел после нее /?, и на экран выведется ее описание и варианты дополнительных параметров с примерами.

Пример вызова подсказки

Пример подсказки к команде DRIVERQUERY

В PowerShell вызвать список поддерживаемых cmd команд с помощью HELP уже не получится.

Итак, посмотрим, что полезного можно сделать с командной строкой.

Команды cmd с файлами

У консоли полно команд для удаления, перемещения, копирования, открытия, создания файлов и папок. Но вряд ли они будут вам полезны, если только не накрылась ваша операционка, и с помощью обычных графических средств работать с файлами невозможно. На этот случай приведу вам списочек таких команд. Для большинства из них требуется указать пути к файлам. Рекомендую сверяться с инструкцией как вводить команды.

  • MOVE – перемещает файл из одного места в другое.
  • COPY – копирует файлы/папки в указанное место.
  • DEL или ERASE – удаляет файлы.
  • RD или RMDIR – удаляет папки.
  • DIR – показывает список файлов в заданном каталоге. Выведите подсказку /?, чтобы посмотреть все варианты сортировки файлов.
  • MD или MKDIR – создает новую папку. Если в указанном пути к папке будут отсутствовать промежуточные каталоги, то система их создаст автоматически.
  • PRINT – выведет указанный файл на печать.
  • TYPE – выведет содержимое текстового файла на экран консоли.
  • REN или RENAME – переименует файл или каталог. Команду следует прописать в таком формате: REN «путь к файлу/папке, которую следует переименовать» «новое имя указанного файла/папки».
  • REPLACE – выполняет замену файлов в каталоге. Полезно для синхронизации данных на дисках. Дополнительный параметр /U заменяет в указанном каталоге исходные файлы на новые, если время последнего изменения этих файлов будет различно. Параметр /A добавит в указанный каталог только те файлы, которых нет в другом.

Вышеперечисленные действия, безусловно, удобнее выполнять с помощью файлового проводника Windows, а теперь посмотрим на команды, которым нет аналога в графическом интерфейсе.

FC и COMP – команды сравнивают два файла или группы файлов и выводят на экран результат этого сравнения с кратким сообщением о найденных (или нет) различиях.

FIND – ищет слова/строки в указанном файле (или сразу в нескольких) и выдает строки, в которых они содержатся.

FSUTIL FILE CREATENEW «тут путь файла» [тут размер файла в байтах] – создаст новый файл строго указанного размера. Может пригодиться в разных целях: для теста скорости передачи данных, или чтобы зарезервировать место на диске, забив его файлом нужного размера.

Пример команды fsutil file createnew

Создание файла размером 1Гб командой fsutil file createnew

FSUTIL BEHAVIOR SET DISABLE LASTACCESS 1 – отключает формирование отметки о времени последнего использования файла. Полезно, если вы решили увеличить быстродействие своего компьютера: файлы и папки будут открываться быстрее. Но будьте осторожны: перестанут правильно работать программы для резервного копирования файлов, использующих такие отметки. Снова включить обновление отметок последнего доступа к файлу можно той же командой, изменив 1 на 0.

Посмотреть информацию о компьютере, ОС и т.п.

FSUTIL VOLUME DISKFREE C: – запрос свободного пространства на диске C (можно указать любой другой). Более подробную информацию о распределении пространства на указанном диске вы можете получить по команде fsutil volume allocationreport C:

DRIVERQUERY – выводит на экран список всех драйверов устройств. Наиболее интересные параметры команды:

  • /V – показать подробную информацию о состоянии драйверов.
  • /SI – покажет список только драйверов, имеющих цифровую подпись.

SYSTEMINFO – показывает всю информацию о компьютере: версию ОС, код продукта, инфу о процессоре, объем физической и виртуальной памяти, IP-адрес и прочее.

Выполнить диагностику Windows

CHKDSK (запуск от имени Администратора) – проверяет диск на ошибки. При использовании параметра /f – также исправляет их, а если еще в дополнение к нему указать параметр /r, то система найдет поврежденные сектора на диске и попытается восстановить уцелевшие данные с них. После команды через пробел укажите имя диска, а после него – дополнительные параметры. Учтите, что для проверки диска C потребуется перезагрузка системы. После введения команды CHKDSK C: /f консоль предложит вам выполнить ее.

SFC – Команда используется только в сочетании с дополнительными параметрами:

  • SFC/verifyonly – сканирует систему на предмет поврежденных системных файлов.
  • SFC/scannow – производит восстановление обнаруженных повреждений.

Пример сканирования системы

Сканирование системы командой sfc/verifyonly

Запускать команду необходимо от имени Администратора, а после сканирования перезагрузить систему. Те файлы, которые системе не удалось восстановить, можете поискать в интернете или скопировать из аналогичной ОС той же версии.

Поменять настройки Windows

POWERCFG /H ON – включить режим гибернации.
POWERCFG /H OFF – отключить режим гибернации.

Для использования команды нужны права Администратора. В режиме гибернации компьютер перед отключением системы записывает все данные из оперативной памяти на жесткий диск и при следующем включении компьютера снова загружает их в оперативную память, так что вы можете начать работу с того же места, где ее закончили. Полезно для владельцев ноутбуков, чтобы не потерять несохраненные данные из-за неожиданной разрядки устройства. Если острой необходимости в гибернации на своем компьютере вы не испытываете, то её лучше отключить, т.к. гибернация изнашивает жесткий диск и резервирует на нем значительное пространство, что замедляет работу компьютера. По умолчанию гибернация отключена.

Примечание: если после применения команды, вы не обнаружили пункта «Гибернация» в меню завершения работы компьютера, попробуйте проделать следующий финт ушами (работает в Windows 10):

Клик правой кнопкой мыши по иконке меню «Пуск» > Управление электропитанием > Питание и спящий режим > Дополнительные параметры питания > Действие кнопок питания > Изменения параметров, которые сейчас недоступны > Поставьте галочку в окошке «Режим гибернации» > Сохраните изменения и наслаждайтесь результатом.

После этих манипуляций кнопка «Гибернация» должна появиться в меню «Пуск» наряду с пунктами «спящий режим», «перезагрузка» и «завершение работы».

MSCONFIG – команда открывает окно с настройками конфигурации системы, в котором вы можете выбрать варианты запуска ОС (и определить, какую именно ОС вы хотите загружать по умолчанию, если у вас их установлено несколько), параметры загрузки (например, загрузку в безопасном режиме), управлять работой вспомогательных служб системы (возможно, отключить что-то лишнее), а через раздел «Сервис» вызвать информацию о системе, запустить устранение неполадок Windows, посмотреть и настроить параметры сети, зайти в редактор реестра, восстановить систему из точки восстановления и прочее.

REGEDIT – команда вызывает стандартный редактор реестра Windows regedit.exe. С помощью дополнительного параметра /E удобно делать бэкап всего реестра в отдельный файл. Для этого пропишите в строке regedit /E и путь для файла. Например: regedit /e D:backup.reg

REG – позволяет редактировать реестр прямо в командной строке. Используется только в сочетании с дополнительными ключами, которые пишутся после основной через пробел без слэша. Например, можно сделать бэкап раздела реестра, прописав в консоли REG SAVE или REG EXPORT, далее через пробел путь нужного раздела реестра и через пробел путь к будущему файлу. А с подкомандами RESTORE и IMPORT можно загрузить в реестр данные из файла резервной копии.

Сетевые команды CMD

IPCONFIG – вызывает на экран информацию о вашем сетевом подключении (Ipconfig /all покажет детальные сведения): ваш IP-адрес, маску подсети, основной шлюз, список сетевых адаптеров – все, что требуется для настройки роутера. А в сочетании с доп.параметрами командой можно поменять сетевые настройки и исправить некоторые проблемы подключения.

HOSTNAME – выводит имя компа.

PING – позволяет проверить доступность узла в сети. Отправляет пакет данных к IP-адресу узла и получает от него в ответ пакет тех же данных. Если пакет от узла вернулся с потерями – это может указывать на проблему соединения. Обычно команду используют при проблемах подключения к Интернету. Тогда выполняют пингование какого-нибудь популярного сайта, например Яндекс или Google, для теста качества Интернет-соединения или пингуют IP роутера, чтобы проверить, нет ли проблем в локальной сети. Для начала диагностики, вводим в строку команду, затем IP-адрес узла или имя домена (консоль распознает IP автоматически), нажать Enter, и на экран выведется результат проведенной проверки соединения.

Пример команды ping

Пример пингования сайта lohmach.info

TRACERT – команда выполняет трассировку маршрута данных (так называемых пакетов) до конечного сервера, выводит на экран IP-адреса промежуточных узлов (т.е. всех маршрутизаторов встречающихся на его пути) и время прохождения этого сигнала между ними. Трассировка проводится для диагностики неполадок в сети, т.к. помогает определить, на каком узле прерывается цепь передачи данных.

Пример трассировки

Трассировка маршрута до сайта lohmach.info

PATHPING – сочетает в себе функционал двух предыдущих команд Tracert и Ping, одновременно выполняя трассировку маршрута до конечного IP-узла с отправкой пакетов данных к каждому из промежуточных. Так вы можете увидеть на каком из них происходит больше всего потерь данных.

Три последние команды незаменимы при обнаружении проблем с интернетом. Часто техподдержка провайдера просит предоставить им результат проверок, выполняемых этими командами, особенно PATHPING.

Упражнение 1.

А напоследок давайте потренируемся вводить команды в консоль.

Запустите программу cmd.exe от имени Администратора и введите команду: «SHUTDOWN /s /f /t 30» Нажмите клавишу Enter.

Поздравляю! Вы успешно выполнили упражнение и в полной мере усвоили материал. Больше учиться вам нечему. На этом и закончим наш вводный курс.

Командная строка CMD. Учебное пособие

© Валентин Юльевич Арьков, 2021

ISBN 978-5-0055-4126-0

Создано в интеллектуальной издательской системе Ridero

Введение

В качестве введения мы обсудим так называемый «Дисклеймер» – Disclaimer – Отказ от претензий. Это модное нынче название для предупреждения читателя о последствиях чтения книги или просмотра фильма. Иногда помогает защититься от судебных претензий, особенно если у читателя напрочь отсутствует чувство юмора.

Данное произведение предназначено исключительно для изучения операционной системы. Текст составлен на основе многолетнего опыта автора по работе в самых разных вычислительных средах, начиная с больших машин серии ЕС ЭВМ и малых вычислительных машин серии СМ, далее через мини-ЭВМ и микро-ЭВМ – вплоть до наших дней с разнообразными настольными, мобильными, персональными и супер-компьютерами.

Любые совпадения с реальными людьми, корпорациями или событиями являются случайными и непреднамеренными. Все персонажи являются вымышленными. Все факты предлагается проверить читателю и убедиться в том, что переводы иностранных слов соответствуют словарным определениям, а описанные приёмы работы применимы на практике.

Любые высказывания по поводу истории разработки программного обеспечения, качества программных продуктов или уровня перевода являются оценочными суждениями автора и не призывают к каким-либо действиям, кроме как к углублённому изучению материала и большему пониманию смысла происходящего в мире информационных технологий.

Задание. Найдите в своих «интернетах» происхождение фразы «Не стреляйте в пианиста…» Выясните, как звучит эта фраза полностью и насколько она применима к компьютерному миру.

Задания

Для освоения материала студенту предстоит изучить небольшой раздел текста и рисунки. Именно изучить, а не прочитать, и не просмотреть, и не говорить: «Это я и так знаю, а это мне точно не пригодится». Узнать что-то новое. Достичь нового понимания. Увидеть, как всё в жизни связано.

Затем нужно выполнить задание. Можно выполнить его несколько раз. Можно слегка изменить действия, поработать с разными настройками, «поиграться» с командами. Научиться вызывать очередную команду. Это для тех, кто хочет просто «сдать лабы».

Задание. Выясните, что такое «знания» и «умения», что у них общего и в чём разница между «знать» и «уметь».

Кроме обычных заданий, в тексте есть творческие задания. Это задания повышенной сложности. Это для тех, кто хочет учиться. Простые задания – это как «колбаса для населения». Просто и доступно. Сложные задания заставляют человека подумать, разобраться, поэкспериментировать. Это ещё один шаг к тому, чтобы стать специалистом своего дела.

Творческое задание. Выясните, что означает выражение «колбаса для населения».

Знакомство с интерфейсом

Самый первый вид интерфейса пользователя, с которым мы познакомимся, – это командная строка – Command prompt. Здесь работа идёт в текстовом режиме.

Вот некоторые другие названия для «текстового» интерфейса:

– Command Window – командное окно

– Command Shell – командная оболочка

– Command Interpreter —интерпретатор команд

– Command Processor – командный процессор или обработчик команд

– CLI – Command Line Interface – Интерфейс командной строки

– Console – Консоль

В развитие идеи командной оболочки ОС была разработана оболочка для сисадмина – PowerShell.

Большинство перечисленных названий говорят о том, что данный интерфейс имеет отношение к вводу КОМАНД. Здесь пользователь вводит команды с клавиатуры.

Первоначально в качестве интерфейса пользователя использовалась электрическая печатная машинка с длинным рулоном бумаги. Рулон можно прокрутить вперёд и назад, чтобы просмотреть историю работы.

Затем была реализация командной строки на экране компьютера в текстовой режиме. И это действительно была СТРОКА. Это был текст – и никакого графического интерфейса.

Современная программная реализация командной строки в виде окна (в графическом режиме) тоже имеет возможность прокрутки результатов вверх и вниз – как на рулоне бумаги.

Мы будем знакомиться с интерпретатором командной строки (командным окном) на примере популярной ОС Microsoft Windows, сокращённо MS Windows, или просто Windows. Здесь мы встретим самые общие принципы и подходы, которые можно найти и в любой другой операционной системе.

Название компании, а точнее, корпорации, состоит из двух частей. Слово micro означает «маленькая». А вот что именно у них маленькое, доверяем узнать читателю самостоятельно.

Задание. Просмотрите в Википедии статью Microsoft. Выясните, сколько человек было в этой компании первоначально и что означает название этой корпорации.

Вторая часть названия имеет отношение к программному обеспечению – software. Буквально слово soft означает «мягкий», но у него есть и другие значения.

Одно из объяснений звучит так. Первые компьютеры 1940-х годов были очень большими и содержали много тяжёлых металлических деталей. За это компьютерное оборудование прозвали «железом». По-английски hardware, то есть «металлические изделия, изделия из металла». Здесь слово hard означает «металлический», хотя для нас более знакомо буквальное значение «твёрдый». Так что программы – тоже в шутку – назвали software в противоположность оборудованию hardware, обыгрывая буквальное значение этих слов. Получается, что «софт» – это «нечто, сделанное НЕ из металла».

Вокруг этих названий можно придумать много шуток, например название Microsoft Mouse можно буквально перевести как «маленькая мягкая мышка».

Для нас эта история – просто пример того, как появляются компьютерные термины и названия корпораций. Знание истории, происхождения слов помогает лучше понять значение слов и названий – и более грамотно ими пользоваться.

Запуск командного окна через [Win + R]

Командное окно можно запустить несколькими способами.

Нажимаем комбинацию клавиш [Windows + R].

Буква R – это начало слова Run – «Запуск программы на выполнение».

Клавиша Windows (или сокращённо Win) обычно расположена в левом нижнем ряду клавиатуры, см. рис. Она используется для вызова часто используемых функций ОС. Клавиша может отсутствовать на некоторых компьютерах.

Рис. Клавиша Windows

В диалоговом окне вводим название команды cmd и нажимаем клавишу Enter на клавиатуре или кнопку ОК на экране, см рис.

Рис. Запуск командной строки

Запускается командное окно. В правой части окна видна полоса прокрутки. На рисунке показаны основные элементы интерфейса.

Рис. Интерфейс CMD

VER – Версия ОС

Команды можно вызывать по-разному. В простейшем случае достаточно ввести имя (название) команды и нажать Enter.

Задание. Введите команду ver и определите версию ОС.

Как видим на рис. выше, кроме номера версии, здесь можно узнать номер сборки (Build Number). Это может говорить о том, необходимо ли вам установить обновление для работы с какой-нибудь капризной программой.

Задание. Просмотрите в Википедии статью Сборка (программирование) и выясните, что означает слово build в программировании.

Кроме версии и номера сборки, возможности ОС определяются её редакцией (Edition).

Задание. Просмотрите в Википедии статью List of Microsoft Windows versions и выясните, какая редакция ОС установлена на вашем компьютере.

Команды ОС – это сокращение английских слов. В данном случае ver – это сокращение слова version – «версия».

Творческое задание. Выясните, что такое Wndows NT и как это название связано с современной версией Windows.

Творческое задание. Выясните, что такое Windows Server и есть ли в нём командная строка.

История ввода команд

Командное окно запоминает, какие команды вводил пользователь.

Чтобы просмотреть историю команд, нажимаем на клавиатуре стрелки «вверх» и «вниз». Это помогает быстро повторить длинную команду. Когда предыдущая команда появилась в командной строке, её можно отредактировать – исправить ошибку или изменить. Совсем не обязательно вводить одну и ту же команду много раз вручную. Можно просто вызвать её из истории.

На полноценной клавиатуре можно обнаружить два набора стрелок – как отдельные клавиши и как клавиши цифрового блока. Чтобы использовать стрелки на числовом блоке клавиатуры, нужно нажать клавишу NumLock. Обычно на клавиатуре имеется индикатор нажатия этой клавиши.

Рис. Два вида стрелок

Задание. Просмотрите в Википедии статью NumLock и выясните, как расшифровывается это название.

Задание. Найдите клавишу NumLock и ознакомьтесь с её работой. Обратите внимание на индикатор NumLock.

Задание. Верните предыдущую команду и нажмите Enter. Повторите несколько раз.

Полоса прокрутки

В правой части командного окна имеется полоса прокрутки.

Этот инструмент позволяет прокрутить окно на несколько экранов назад и ознакомиться с историей работы пользователя.

Если закрыть командное окно, история ввода команд будет потеряна.

Задание. Прокрутите командное окно вверх и вниз.

Задание. Введите команду exit и нажмите Enter.

Запуск командного окна через поиск

Второй способ запустить командное окно – воспользоваться поиском. В левом нижнем углу экрана находим окно поиска [Type here to search] и вводим название команды cmd, см. рис.

Рис. Запуск через поиск (EN)

Указав на нужное приложение и нажав правую кнопку мыши, получаем контекстное меню. Как видим, оно дублирует варианты действий, предложенные в правой части окна с результатами поиска, см. рис.

Рис. Контекстное меню (RU)

Нам сразу предлагают запустить Command Prompt. Буквально это выражение означает «Приглашение к вводу команд». Здесь оно означает «Командная строка» или «Командное окно». Слово App – это сокращение от слова Application (Software) – «Прикладная программа».

В русскоязычном варианте ОС видим название Командная строка.

Задание. Просмотрите в Википедии статью Application software. Переключитесь на русскоязычную версию статьи. Обратите внимание на термины, которыми называют программы.

В данном варианте запуска у нас появляются дополнительные возможности. Можно запустить командное окно с правами системного администратора:

Запуск от имени администратора

Run as administrator

Это может быть полезно при установке или настройке некоторых программ, когда ОС ограничивает права обычного пользователя.

Творческое задание. Просмотрите в Википедии русскоязычную статью root и англоязычную статью Superuser. Выясните, какие плюсы и минусы могут быть у доступа с правами администратора.

Язык интерфейса

Windows 10 позволяет переключить язык интерфейса без переустановки ОС.

Это может быть полезно при работе с некоторыми программами. Например, автору приходилось переключаться на русскоязычный интерфейс для заполнения налоговой декларации с помощью официального приложения ФНС. Но технологии меняются очень быстро, и сейчас можно заполнить налоговую декларацию в облаке – через диалоговое окно веб-сайта – без установки программы.

Работа с англоязычным интерфейсом помогает освоить английский язык и привыкнуть к компьютерной терминологии. Как говорят программисты, «в английском языке все слова взяты из языка С++».

Кроме того, чтение справки на английском позволяет быстрее сообразить, что означают сокращённые названия команд и их параметров. Мы увидим, что это первые буквы или начало английских слов. Так будет гораздо легче освоить работу с компьютером – все названия становятся более понятными и даже очевидными.

Чтобы переключить язык интерфейса ОС, вызываем настройки: Start – Settings, см. рис.

Рис. Вызов настроек ОС

Далее в меню настроек ОС выбираем настройки языка: Time & Language, см. рис.

Рис. Меню настроек ОС

Переходим в раздел настройки языка Language и выбираем нужный язык, см. рис.

Рис. Выбор языка интерфейса ОС

После переключения языка нас предупреждают, что придётся выйти из текущей учётной записи пользователя – Sign out, см. рис. Другими словами, сейчас нас «выйдут» из системы. Поэтому желательно сохранить файлы, которые мы редактируем, чтобы не потерять информацию.

Рис. Предупреждение системы

Соглашаемся и автоматически выходим из системы.

Снова входим со своим паролем и видим новый язык интерфейса. Теперь наше командное окно (командная строка) выводит сообщения на русском языке, см. рис.

Рис. Командная строка с русскоязычным интерфейсом

Все установленные программы живы, все настройки рабочего стола сохранились, никто не пострадал. В предыдущих версиях Windows для перехода на другой язык пришлось бы заново переустанавливать всю ОС, а потом и все прикладные программы. Теперь всё стало гораздо проще и быстрее.

Осталась одна небольшая проблема. Для изменения настроек компьютера может потребоваться участие системного администратора.

Дома это легко: пользователь чаще всего сам же и является администратором.

Если же на предприятии есть всего один сисадмин на три тысячи компьютеров, то работникам можно только посочувствовать.

Компьютер может в самый неподходящий момент сообщить, что для изменения настроек ОС нужны права администратора.

Задание. Переключитесь на английский язык интерфейса. Если у вас уже настроен английский, переключитесь на русский язык, ознакомьтесь с изменениями в интерфейсе, а потом переключитесь на английский.

Понравилась статья? Поделить с друзьями:
  • Издательство легион автодата руководство по эксплуатации
  • Как из бумаги сделать парашют пошаговая инструкция
  • Сумамед для ребенка 3 лет инструкция по применению
  • Дез средство одс 17 инструкция по применению
  • Под чьим руководством изучались ресурсы центрального казахстана