- Windows commands
- Prerequisites
- Command shell overview
- Command-line reference A-Z
- Net Commands On Operating Systems
- Аннотация
- Дополнительные сведения
- Net Commands On Operating Systems
- Summary
- More information
- Команды Windows Windows commands
- Предварительные требования Prerequisites
- Общие сведения о командной оболочке Command shell overview
- Справочник по командной строке A-Z Command-line reference A-Z
Windows commands
All supported versions of Windows (server and client) have a set of Win32 console commands built in.
This set of documentation describes the Windows Commands you can use to automate tasks by using scripts or scripting tools.
Prerequisites
The information that is contained in this topic applies to:
- Windows Server 2019
- Windows Server (Semi-Annual Channel)
- Windows Server 2016
- Windows Server 2012 R2
- Windows Server 2012
- Windows Server 2008 R2
- Windows Server 2008
- Windows 10
- Windows 8.1
Command shell overview
The Command shell was the first shell built into Windows to automate routine tasks, like user account management or nightly backups, with batch (.bat) files. With Windows Script Host you could run more sophisticated scripts in the Command shell. For more information, see cscript or wscript. You can perform operations more efficiently by using scripts than you can by using the user interface. Scripts accept all Commands that are available at the command line.
Windows has two command shells: The Command shell and PowerShell. Each shell is a software program that provides direct communication between you and the operating system or application, providing an environment to automate IT operations.
PowerShell was designed to extend the capabilities of the Command shell to run PowerShell commands called cmdlets. Cmdlets are similar to Windows Commands but provide a more extensible scripting language. You can run Windows Commands and PowerShell cmdlets in Powershell, but the Command shell can only run Windows Commands and not PowerShell cmdlets.
For the most robust, up-to-date Windows automation, we recommend using PowerShell instead of Windows Commands or Windows Script Host for Windows automation.
You can also download and install PowerShell Core, the open source version of PowerShell.
Incorrectly editing the registry may severely damage your system. Before making the following changes to the registry, you should back up any valued data on the computer.
To enable or disable file and directory name completion in the Command shell on a computer or user logon session, run regedit.exe and set the following reg_DWOrd value:
To set the reg_DWOrd value, use the hexadecimal value of a control character for a particular function (for example, 0 9 is Tab and 0 08 is Backspace). User-specified settings take precedence over computer settings, and command-line options take precedence over registry settings.
Command-line reference A-Z
To find information about a specific command, in the following A-Z menu, click the letter that the command starts with, and then click the command name.
Net Commands On Operating Systems
В этой статье данная статья содержит некоторые сведения о net Commands on Operating Systems.
Исходная версия продукта: Windows Server 2012 R2
Исходный номер КБ: 556003
Эту статью написал Нирмал Sharma (Nirmal Sharma),microsoft MVP.
Аннотация
В следующей базе знаний объясняется использование команд Net в операционных системах Windows.
Дополнительные сведения
Net Commands On Windows Operating Systems
Следующие команды net можно использовать для выполнения операций с группами, пользователями, политиками учетных записей, доступом к данным и так далее.
УЧЕТНЫЕ ЗАПИСИ
КОМПЬЮТЕР
CONFIG
CONTINUE
FILE
GROUP
HELP
HELPMSG
LOCALGROUP
NAME
PAUSE
PRINT
Отправить
SESSION
Предоставить общий доступ
START
СТАТИСТИКА
STOP
TIME
ИСПОЛЬЗОВАНИЕ
ПОЛЬЗОВАТЕЛЬ
ВИД
Команда «Net Accounts» используется для настройки параметров политики на локальном компьютере, таких как политики учетных записей и политики паролей. Эту команду нельзя использовать на контроллере домена. Эта команда используется только на локальном компьютере.
При вводить net Accounts (Net Accounts) параметры политики блокировки учетных записей и политики паролей на локальном компьютере будут показываться как:
Принудительное истечении срока действия по истечении срока действия пользователя. Никогда
Минимальный срок (дней): 1
Максимальный срок (дней): 90
Минимальная длина пароля: 8
Длина сохраненной истории паролей: 5
Пороговое значение блокировки: 4
Продолжительность блокировки (минуты): 4
Окно наблюдения за блокировкой (минуты): 4
Роль компьютера: WORKSTATION
Вышеперечисленные параметры отображаются в качестве роли компьютера. Если компьютер присоединяется к домену, параметры домена вступает в силу, и отображаются только параметры, которые поступили из домена. Остальные параметры будут локальными, если они не приходят из GPO домена.
В параметре «Net Accounts» можно изменить следующие параметры:
Чтобы параметры, используемые с NET ACCOUNTS, вступили в силу, требуются два условия:
/FORCELOGOFF:
/MINPWLEN:length Задает минимальное количество символов для пароля. Диапазон составляет от 0 до 14 символов; значение по умолчанию — шесть символов.
/MAXPWAGE:
/MINPWAGE:days Задает минимальное количество дней, которое должно пройти, прежде чем пользователь сможет изменить пароль. Нулевое значение не задает минимальное время. Диапазон : 0–999; значение по умолчанию — ноль дней. /MINPWAGE не может быть больше/ /MAXPWAGE.\
/UNIQUEPW:number Требует, чтобы пароли пользователя были уникальными посредством указанного количества изменений паролей. Максимальное значение — 24.
/DOMAIN Выполняет операцию на контроллере домена текущего домена. В противном случае операция выполняется на локальном компьютере.
Заявление об отказе от контента решений сообщества
КОРПОРАЦИЯ МАЙКРОСОФТ И/ИЛИ ЕЕ ПОСТАВЩИКИ НЕ СОДЕРЖАТ НИКАКИХ ПРЕДСТАВЛЕНИЙ О ПРИГОДНОСТИ, НАДЕЖНОСТИ ИЛИ ТОЧНОСТИ ИНФОРМАЦИИ И СВЯЗАННОЙ С НЕЙ ГРАФИКИ. ВСЯ ТАКАЯ ИНФОРМАЦИЯ И СВЯЗАННАЯ С НЕЙ ГРАФИКА ПРЕДОСТАВЛЯЮТСЯ БЕЗ КАКИХ-ЛИБО ГАРАНТИЙ. КОРПОРАЦИЯ МАЙКРОСОФТ И/ИЛИ ЕЕ ПОСТАВЩИКИ НАСТОЯЩИМ СНИМАТЬИ ВСЕ ГАРАНТИИ И УСЛОВИЯ, ОТНОСЯЩИЕСЯ К ЭТОЙ ИНФОРМАЦИИ И СВЯЗАННЫМ ГРАФИЧЕСКИМ ГРАФИКАМ, ВКЛЮЧАЯ ВСЕ ПОДРАЗУМЕВАЕМЫЕ ГАРАНТИИ И УСЛОВИЯ ДЛЯ ОБЕСПЕЧЕНИЯ СООТВЕТСТВИЯ ТРЕБОВАНИЯМ, ПРИГОДНОСТИ ДЛЯ ОПРЕДЕЛЕННЫХ ЦЕЛЕЙ, ВОРКМАНЛИКЕ УСИЛИЯ, ДОЛЖНОСТИ И НЕНАРУШЕНИЯ ПРАВ. ВЫ ЯВНО СОГЛАСНЫ, ЧТО В СЛУЧАЕ ОТСУТСТВИЯ У КОРПОРАЦИИ МАЙКРОСОФТ И/ИЛИ ЕЕ ПОСТАВЩИКОВ НЕ НЕСЕТ ОТВЕТСТВЕННОСТИ ЗА ЛЮБЫЕ ПРЯМЫЕ, КОСВЕННЫЕ, ПУНИТИВЕ, СЛУЧАЙНЫЕ, СПЕЦИАЛЬНЫЕ УБЫТКИ, А ТАКЖЕ ЛЮБЫЕ УЩЕРБА БЕЗ ОГРАНИЧЕНИЙ, УЩЕРБА ДЛЯ ПОТЕРИ ИСПОЛЬЗОВАНИЯ, ДАННЫХ ИЛИ ПРИБЫЛИ, КОТОРЫЕ СВЯЗАНЫ С ИСПОЛЬЗОВАНИЕМ ИЛИ НЕВОЗМОЖНОСТЬЮ ИСПОЛЬЗОВАТЬ ИНФОРМАЦИЮ И СВЯЗАННУЮ С НИМИ ГРАФИКУ, В ЗАВИСИМОСТИ ОТ ДОГОВОРА, НАРУШЕНИЯМ, НЕБРЕЖНОСТЬЮ, ОГРАНИЧЕННОЙ ОТВЕТСТВЕННОСТИ ИЛИ ИНЫМ СПОСОБОМ, ДАЖЕ ЕСЛИ КОРПОРАЦИИ МАЙКРОСОФТ ИЛИ ЕЕ ПОСТАВЩИКАМ РЕКОМЕНДУЕТСЯ ВОЗДЕРЖАТЬ УЩЕРБ.
Net Commands On Operating Systems
This article provides some information about Net Commands on Operating Systems.
Original product version: В Windows Server 2012 R2
Original KB number: В 556003
This article was written by Nirmal Sharma, Microsoft MVP.
Summary
The following knowledgebase will explain the uses of Net commands in Windows Operating Systems.
More information
Net Commands On Windows Operating Systems
The following Net Commands can be used to perform operations on Groups, users, account policies, shares, and so on.
ACCOUNTS
COMPUTER
CONFIG
CONTINUE
FILE
GROUP
HELP
HELPMSG
LOCALGROUP
NAME
PAUSE
PRINT
SEND
SESSION
SHARE
START
STATISTICS
STOP
TIME
USE
USER
VIEW
The «Net Accounts» command is used to set the policy settings on local computer, such as Account policies and password policies. This command can’t be used on domain controller. This command is only used on local computer.
When you type Net Accounts, you will see the default settings of the Account Lockout policy and Password Policy in local computer show as:
Force user logoff how long after time expires?: Never
Minimum password age (days): 1
Maximum password age (days): 90
Minimum password length: 8
Length of password history maintained: 5
Lockout threshold: 4
Lockout duration (minutes): 4
Lockout observation window (minutes): 4
Computer role: WORKSTATION
The above settings displayed as per the role of the computer. If computer is joined to a domain, the domain settings will take effect and only the settings coming from domain will be displayed. The rest settings will be the local settings if it’s not coming from the Domain GPO.
You can change the following use the following options in Net Accounts option:
Two conditions are required in order for options used with NET ACCOUNTS to take effect:
/FORCELOGOFF:
/MINPWLEN:length Sets the minimum number of characters for a password. The range is 0-14 characters; the default is six characters.
/MAXPWAGE:
/MINPWAGE:days Sets the minimum number of days that must pass before a user can change a password. A value of zero sets no minimum time. The range is 0-999; the default is zero days. /MINPWAGE can’t be more than /MAXPWAGE.\
/UNIQUEPW:number Requires that a user’s passwords be unique through the specified number of password changes. The maximum value is 24.
/DOMAIN Performs the operation on a domain controller of the current domain. Otherwise, the operation is performed on the local computer.
Community Solutions Content Disclaimer
MICROSOFT CORPORATION AND/OR ITS RESPECTIVE SUPPLIERS MAKE NO REPRESENTATIONS ABOUT THE SUITABILITY, RELIABILITY, OR ACCURACY OF THE INFORMATION AND RELATED GRAPHICS CONTAINED HEREIN. ALL SUCH INFORMATION AND RELATED GRAPHICS ARE PROVIDED «AS IS» WITHOUT WARRANTY OF ANY KIND. MICROSOFT AND/OR ITS RESPECTIVE SUPPLIERS HEREBY DISCLAIM ALL WARRANTIES AND CONDITIONS WITH REGARD TO THIS INFORMATION AND RELATED GRAPHICS, INCLUDING ALL IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, WORKMANLIKE EFFORT, TITLE AND NON-INFRINGEMENT. YOU SPECIFICALLY AGREE THAT IN NO EVENT SHALL MICROSOFT AND/OR ITS SUPPLIERS BE LIABLE FOR ANY DIRECT, INDIRECT, PUNITIVE, INCIDENTAL, SPECIAL, CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF USE, DATA OR PROFITS, ARISING OUT OF OR IN ANY WAY CONNECTED WITH THE USE OF OR INABILITY TO USE THE INFORMATION AND RELATED GRAPHICS CONTAINED HEREIN, WHETHER BASED ON CONTRACT, TORT, NEGLIGENCE, STRICT LIABILITY OR OTHERWISE, EVEN IF MICROSOFT OR ANY OF ITS SUPPLIERS HAS BEEN ADVISED OF THE POSSIBILITY OF DAMAGES.
Команды Windows Windows commands
Все поддерживаемые версии Windows (сервер и клиент) имеют набор встроенных команд консоли Win32. All supported versions of Windows (server and client) have a set of Win32 console commands built in.
Этот набор документации описывает команды Windows, которые можно использовать для автоматизации задач с помощью скриптов или средств создания скриптов. This set of documentation describes the Windows Commands you can use to automate tasks by using scripts or scripting tools.
Предварительные требования Prerequisites
Сведения, содержащиеся в этом разделе, применимы к: The information that is contained in this topic applies to:
- Windows Server 2019 Windows Server 2019
- Windows Server (Semi-Annual Channel) Windows Server (Semi-Annual Channel)
- Windows Server 2016 Windows Server 2016
- Windows Server 2012 R2 Windows Server 2012 R2
- Windows Server 2012 Windows Server 2012
- Windows Server 2008 R2 Windows Server 2008 R2
- Windows Server 2008 Windows Server 2008
- Windows 10 Windows 10
- Windows 8.1 Windows 8.1
Общие сведения о командной оболочке Command shell overview
Командная оболочка была первой оболочкой, встроенной в Windows, для автоматизации стандартных задач, таких как управление учетными записями пользователей или ночное резервное копирование с пакетными файлами (bat). The Command shell was the first shell built into Windows to automate routine tasks, like user account management or nightly backups, with batch (.bat) files. С помощью сервера сценариев Windows можно выполнять более сложные сценарии в командной оболочке. With Windows Script Host you could run more sophisticated scripts in the Command shell. Дополнительные сведения см. в разделе cscript или Wscript. For more information, see cscript or wscript. С помощью скриптов можно более эффективно выполнять операции, чем с помощью пользовательского интерфейса. You can perform operations more efficiently by using scripts than you can by using the user interface. Скрипты принимают все команды, доступные в командной строке. Scripts accept all Commands that are available at the command line.
Windows имеет две командные оболочки: Командная оболочка и PowerShell. Windows has two command shells: The Command shell and PowerShell. Каждая оболочка представляет собой программную программу, обеспечивающую прямой обмен данными между вами и операционной системой или приложением, предоставляя среду для автоматизации ИТ-операций. Each shell is a software program that provides direct communication between you and the operating system or application, providing an environment to automate IT operations.
PowerShell был разработан для расширения возможностей командной оболочки для выполнения команд PowerShell, называемых командлетами. PowerShell was designed to extend the capabilities of the Command shell to run PowerShell commands called cmdlets. Командлеты похожи на команды Windows, но предоставляют более расширяемый язык сценариев. Cmdlets are similar to Windows Commands but provide a more extensible scripting language. Вы можете выполнять команды Windows и командлеты PowerShell в PowerShell, но Командная оболочка может выполнять только команды Windows, а не командлеты PowerShell. You can run Windows Commands and PowerShell cmdlets in Powershell, but the Command shell can only run Windows Commands and not PowerShell cmdlets.
Для наиболее надежной и последней версии службы автоматизации Windows рекомендуется использовать PowerShell вместо команд Windows или сервера сценариев Windows для службы автоматизации Windows. For the most robust, up-to-date Windows automation, we recommend using PowerShell instead of Windows Commands or Windows Script Host for Windows automation.
Вы также можете скачать и установить PowerShell Core, версию PowerShell с открытым исходным кодом. You can also download and install PowerShell Core, the open source version of PowerShell.
Неправильное изменение реестра может серьезно повредить систему. Incorrectly editing the registry may severely damage your system. Перед внесением следующих изменений в реестр следует создать резервную копию всех ценных данных на компьютере. Before making the following changes to the registry, you should back up any valued data on the computer.
Чтобы включить или отключить завершение имен файлов и каталогов в командной оболочке на компьютере или в сеансе входа пользователя, запустите regedit.exe и задайте следующее значение reg_DWOrd: To enable or disable file and directory name completion in the Command shell on a computer or user logon session, run regedit.exe and set the following reg_DWOrd value:
HKEY_LOCAL_MACHINE\Software\Microsoft\Command Processor\completionChar\reg_DWOrd HKEY_LOCAL_MACHINE\Software\Microsoft\Command Processor\completionChar\reg_DWOrd
Чтобы задать значение reg_DWOrd , используйте шестнадцатеричное значение управляющего символа для конкретной функции (например, 0 9 — TAB, а 0 08 — Backspace). To set the reg_DWOrd value, use the hexadecimal value of a control character for a particular function (for example, 0 9 is Tab and 0 08 is Backspace). Заданные пользователем параметры имеют приоритет над параметрами компьютера, а параметры командной строки имеют приоритет над параметрами реестра. User-specified settings take precedence over computer settings, and command-line options take precedence over registry settings.
Справочник по командной строке A-Z Command-line reference A-Z
Чтобы найти сведения о конкретной команде, в следующем меню A-Z щелкните букву, с которой начинается команда, а затем щелкните имя команды. To find information about a specific command, in the following A-Z menu, click the letter that the command starts with, and then click the command name.
Объект | Б | C | Г | Д | F | Ж | З | Я | J | Л | L | М | N | O | P | Вопросы и ответы | Язык R | С | T | U | Версия | Н | X | Y | Гармошкой A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z