Uninstalling windows services что это

How to: Install and uninstall Windows services

If you’re developing a Windows service with the .NET Framework, you can quickly install your service app by using the InstallUtil.exe command-line utility or PowerShell. Developers who want to release a Windows service that users can install and uninstall can use the free WiX Toolset or commercial tools like Advanced Installer, InstallShield, or others. For more information, see Create an installer package (Windows desktop).

If you want to uninstall a service from your computer, don’t follow the steps in this article. Instead, find out which program or software package installed the service, and then choose Apps in Settings to uninstall that program. Note that many services are integral parts of Windows; if you remove them, you might cause system instability.

To use the steps in this article, you first need to add a service installer to your Windows service. For more information, see Walkthrough: Creating a Windows service app.

You can’t run Windows service projects directly from the Visual Studio development environment by pressing F5. Before you can run the project, you must install the service in the project.

You can use Server Explorer to verify that you’ve installed or uninstalled your service.

Install using InstallUtil.exe utility

From the Start menu, select the Visual Studio directory, then select Developer Command Prompt for VS .

The Developer Command Prompt for Visual Studio appears.

Access the directory where your project’s compiled executable file is located.

Run InstallUtil.exe from the command prompt with your project’s executable as a parameter:

If you’re using the Developer Command Prompt for Visual Studio, InstallUtil.exe should be on the system path. Otherwise, you can add it to the path, or use the fully qualified path to invoke it. This tool is installed with the .NET Framework in %WINDIR%\Microsoft.NET\Framework[64]\ .

  • For the 32-bit version of the .NET Framework 4 or 4.5 and later, if your Windows installation directory is C:\Windows, the default path is C:\Windows\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe.
  • For the 64-bit version of the .NET Framework 4 or 4.5 and later, the default path is C:\Windows\Microsoft.NET\Framework64\v4.0.30319\InstallUtil.exe.

Uninstall using InstallUtil.exe utility

From the Start menu, select the Visual Studio directory, then select Developer Command Prompt for VS .

The Developer Command Prompt for Visual Studio appears.

Run InstallUtil.exe from the command prompt with your project’s output as a parameter:

After the executable for a service is deleted, the service might still be present in the registry. If that’s the case, use the command sc delete to remove the entry for the service from the registry.

Install using PowerShell

From the Start menu, select the Windows PowerShell directory, then select Windows PowerShell.

Access the directory where your project’s compiled executable file is located.

Run the New-Service cmdlet with the with your project’s output and a service name as parameters:

Uninstall using PowerShell

From the Start menu, select the Windows PowerShell directory, then select Windows PowerShell.

Run the Remove-Service cmdlet with the name of your service as parameter:

After the executable for a service is deleted, the service might still be present in the registry. If that’s the case, use the command sc delete to remove the entry for the service from the registry.

Читайте также:  Zip для linux установить

Практическое руководство. Установка и удаление служб Windows How to: Install and uninstall Windows services

Если вы разрабатываете службу Windows с помощью .NET Framework, вы можете быстро установить приложение службы с помощью служебной программы командной строки InstallUtil.exe или PowerShell. If you’re developing a Windows service with the .NET Framework, you can quickly install your service app by using the InstallUtil.exe command-line utility or PowerShell. Если вы являетесь разработчиком и хотите создать службу Windows, которую пользователи могут устанавливать и удалять, можно использовать набор инструментов WiX или коммерческие средства, такие как Advanced Installer, InstallShield или другие. Developers who want to release a Windows service that users can install and uninstall can use the free WiX Toolset or commercial tools like Advanced Installer, InstallShield, or others. См. сведения о создании пакета установщика (классическое приложение Windows). For more information, see Create an installer package (Windows desktop).

Если вы хотите удалить службу на своем компьютере, не выполняйте процедуру, описанную в этой статье. If you want to uninstall a service from your computer, don’t follow the steps in this article. Вместо этого определите, какая программа (или программный пакет) установила эту службу, а затем выберите Приложения в параметрах, чтобы удалить эту программу. Instead, find out which program or software package installed the service, and then choose Apps in Settings to uninstall that program. Следует отметить, что многие службы являются составной частью ОС Windows. Если их удалить, это может привести к нестабильной работе системы. Note that many services are integral parts of Windows; if you remove them, you might cause system instability.

Чтобы использовать процедуру, описанную в этой статье, сначала необходимо добавить установщик службы в свою службу Windows. To use the steps in this article, you first need to add a service installer to your Windows service. Дополнительные сведения см. в разделе Пошаговое руководство: создание диспетчера служб Windows. For more information, see Walkthrough: Creating a Windows service app.

Проекты служб Windows нельзя запускать непосредственно из среды разработки Visual Studio путем нажатия клавиши F5. You can’t run Windows service projects directly from the Visual Studio development environment by pressing F5. Перед запуском проекта необходимо установить службу в проекте. Before you can run the project, you must install the service in the project.

Запустите обозреватель сервера и убедитесь, что служба установлена или удалена. You can use Server Explorer to verify that you’ve installed or uninstalled your service.

Установка с помощью программы InstallUtil.exe Install using InstallUtil.exe utility

В меню Пуск выберите каталог Visual Studio и затем Командная строка разработчика для VS . From the Start menu, select the Visual Studio directory, then select Developer Command Prompt for VS .

Появится командная строка разработчика для Visual Studio. The Developer Command Prompt for Visual Studio appears.

Откройте каталог, где находится скомпилированный исполняемый файл вашего проекта. Access the directory where your project’s compiled executable file is located.

Запустите InstallUtil.exe из командной строки, указав исполняемый файл проекта в качестве параметра: Run InstallUtil.exe from the command prompt with your project’s executable as a parameter:

Если вы используете командную строку разработчика для Visual Studio, системный путь должен указывать на файл InstallUtil.exe. If you’re using the Developer Command Prompt for Visual Studio, InstallUtil.exe should be on the system path. Если это не так, можно добавить его в путь или использовать полный путь для его вызова. Otherwise, you can add it to the path, or use the fully qualified path to invoke it. Этот инструмент устанавливается вместе с платформой .NET Framework в папку %WINDIR%\Microsoft.NET\Framework[64]\ . This tool is installed with the .NET Framework in %WINDIR%\Microsoft.NET\Framework[64]\ .

Пример: For example:

  • Для 32-разрядной версии .NET Framework 4 или 4.5 и более поздних версий: если каталог установки Windows — C:\Windows, по умолчанию используется путь C:\Windows\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe. For the 32-bit version of the .NET Framework 4 or 4.5 and later, if your Windows installation directory is C:\Windows, the default path is C:\Windows\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe.
  • Для 64-разрядной версии .NET Framework 4 или 4.5 и более поздних версий: по умолчанию используется путь C:\Windows\Microsoft.NET\Framework64\v4.0.30319\InstallUtil.exe. For the 64-bit version of the .NET Framework 4 or 4.5 and later, the default path is C:\Windows\Microsoft.NET\Framework64\v4.0.30319\InstallUtil.exe.
Читайте также:  Windows не видит android как флешку

Удаление с помощью служебной программы InstallUtil.exe Uninstall using InstallUtil.exe utility

В меню Пуск выберите каталог Visual Studio и затем Командная строка разработчика для VS . From the Start menu, select the Visual Studio directory, then select Developer Command Prompt for VS .

Появится командная строка разработчика для Visual Studio. The Developer Command Prompt for Visual Studio appears.

Запустите InstallUtil.exe из командной строки, указав выходные данные проекта в качестве параметра: Run InstallUtil.exe from the command prompt with your project’s output as a parameter:

После удаления исполняемого файла для службы сама служба может по-прежнему присутствовать в реестре. After the executable for a service is deleted, the service might still be present in the registry. В этом случае удалить запись службы из реестра можно с помощью команды sc delete. If that’s the case, use the command sc delete to remove the entry for the service from the registry.

Установка с помощью PowerShell Install using PowerShell

В меню Пуск выберите Каталог Windows PowerShell и Windows PowerShell. From the Start menu, select the Windows PowerShell directory, then select Windows PowerShell.

Откройте каталог, где находится скомпилированный исполняемый файл вашего проекта. Access the directory where your project’s compiled executable file is located.

Выполните командлет New-Service, указав в качестве параметров выходные данные проекта и имя службы. Run the New-Service cmdlet with the with your project’s output and a service name as parameters:

Удаление с помощью PowerShell Uninstall using PowerShell

В меню Пуск выберите Каталог Windows PowerShell и Windows PowerShell. From the Start menu, select the Windows PowerShell directory, then select Windows PowerShell.

Выполните командлет Remove-Service, указав в качестве параметра имя службы. Run the Remove-Service cmdlet with the name of your service as parameter:

После удаления исполняемого файла для службы сама служба может по-прежнему присутствовать в реестре. After the executable for a service is deleted, the service might still be present in the registry. В этом случае удалить запись службы из реестра можно с помощью команды sc delete. If that’s the case, use the command sc delete to remove the entry for the service from the registry.

Удаление служб Reporting Services Uninstall Reporting Services

Применимо к: Applies to: SQL Server SQL Server (все поддерживаемые версии) SQL Server SQL Server (all supported versions) — только Windows Управляемый экземпляр SQL Azure Azure SQL Managed Instance Управляемый экземпляр SQL Azure Azure SQL Managed Instance Применимо к: Applies to: SQL Server SQL Server (все поддерживаемые версии) SQL Server SQL Server (all supported versions) — Windows only Управляемый экземпляр SQL Azure Azure SQL Managed Instance Управляемый экземпляр SQL Azure Azure SQL Managed Instance

Удаление Службы Reporting Services Reporting Services не приводит к удалению созданного содержимого или измененной конфигурации. Uninstalling Службы Reporting Services Reporting Services does not remove the content you have created or configuration you have modified. Но если имеется содержимое, которое потребуется после завершения удаления, то рекомендуется создать копии содержимого до начала процесса удаления. However, if there is content you need after the uninstall is complete, it is recommended you make copies of content before you begin the uninstallation process.

Удаление режима интеграции с SharePoint Uninstall SharePoint Mode

При удалении служб Службы Reporting Services Reporting Services , работающих в режиме интеграции с SharePoint, будут удалены следующие компоненты: When you uninstall Службы Reporting Services Reporting Services SharePoint mode, the following are removed:

Службы Reporting Services Reporting Services и прокси-сервер службы. service and service proxy.

Файлы, используемые для установки служб Службы Reporting Services Reporting Services . Files used for the Службы Reporting Services Reporting Services installation.

Приложения службы Службы Reporting Services Reporting Services не удаляются. The Службы Reporting Services Reporting Services service applications are not removed. Если данные приложения службы больше не требуются, удалите их с помощью центра администрирования Windows PowerShell или SharePoint. If you no longer want the service applications, delete them by using Windows PowerShell or SharePoint Central Administration.

Читайте также:  Windows 10 период лицензии

Элементы отчетов и связанные с ними метаданные не удаляются. The report items and related meta data are not removed. Эти сведения находятся в базах данных содержимого и конфигурации, связанных с приложениями служб Службы Reporting Services Reporting Services . This information is contained in the content and configuration databases related to the Службы Reporting Services Reporting Services service applications. Базы данных не удаляются, и можно вручную переместить базы данных в другую установку Службы Reporting Services Reporting Services в режиме SharePoint. The databases are not removed and you can manually migrate the databases to another installation of Службы Reporting Services Reporting Services in SharePoint mode. Если эта информация больше не требуется, удалите базы данных. If you no longer want the information, delete the databases. Дополнительные сведения см. в разделе Upgrade and Migrate Reporting Services. For more information, see Upgrade and Migrate Reporting Services.

Далее приводятся примеры имен трех баз данных служб Службы Reporting Services Reporting Services , которые не будут удалены. The following are example names of the three Службы Reporting Services Reporting Services databases that are not removed.

База данных сервера отчетов: ReportingService_7f616e2d253040e8ab5653b3c09a065e Report server database: ReportingService_7f616e2d253040e8ab5653b3c09a065e

Временная база данных сервера отчетов: ReportingService_7f616e2d253040e8ab5653b3c09a065eTempDB Report server temp database: ReportingService_7f616e2d253040e8ab5653b3c09a065eTempDB

База данных предупреждений сервера отчетов: ReportingService_7f616e2d253040e8ab5653b3c09a065e_Alerting Report server alerting database: ReportingService_7f616e2d253040e8ab5653b3c09a065e_Alerting

Удаление надстройки для продуктов SharePoint. Uninstall the Add-in for SharePoint Products.

При удалении надстройки с компьютера вы можете выбрать удаление только файлов или удаление и самого компонента Службы Reporting Services Reporting Services из фермы. When you uninstall the add-in from a computer, you can choose to only uninstall the files or to also remove the Службы Reporting Services Reporting Services feature from the farm. Сведения об удалении надстройки Службы Reporting Services Reporting Services для продуктов Microsoft см. в статье Установка или удаление надстройки служб Reporting Services для SharePoint. For information on uninstalling the Службы Reporting Services Reporting Services add-in for SharePoint products, see Install or Uninstall the Reporting Services Add-in for SharePoint.

Удаление собственного режима Uninstall Native Mode

При удалении собственного режима служб Службы Reporting Services Reporting Services все, что было создано или изменено после установки, будет сохранено. When you uninstall Службы Reporting Services Reporting Services native mode, anything that was created or modified after the installation is left in place. В качестве примера можно назвать файлы базы данных, файлы журнала, файлы конфигурации Службы Reporting Services Reporting Services и элементы содержимого, такие как отчеты и файлы источников данных. For example database files, log files, Службы Reporting Services Reporting Services configuration files, and content items such as reports and datasource files.

Службы Reporting Services Reporting Services представляет собой функцию экземпляра, поэтому не перечисляется на панели управления Windows «Программы и компоненты». is an instance feature and therefore is not listed in Windows Control Panel, Programs and Features. Удаление собственного режима Службы Reporting Services Reporting Services : To uninstall Службы Reporting Services Reporting Services Native mode:

На панели управления Windows щелкните Программы и компоненты. In Windows Control Panel, click Programs and Features.

В окне Программы и компоненты выберите Microsoft SQL Server 2016. In Programs and Features select Microsoft SQL Server 2016.

В мастере удаления выберите экземпляр, который включает функцию экземпляра Службы Reporting Services Reporting Services RS. In the uninstall wizard, select the instance that includes the Службы Reporting Services Reporting Services instance feature RS.

После выбора экземпляра выберите компонент Службы Reporting Services Reporting Services . After you select the instance, select the Службы Reporting Services Reporting Services feature.

Завершите работу мастера. Complete the wizard.

Оцените статью