Как удалить службу в windows 10 cmd

Если по той или иной причине вы хотите не просто остановить службу Windows 10, но и удалить её, сделать это можно двумя простыми способами, о которых пойдет речь в этой инструкции. В обоих случаях для удаления потребуются права администратора.

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

Удаление служб Windows 10 в командной строке

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

  1. Нажмите клавиши Win+R, введите services.msc и нажмите Enter. В списке служб найдите ту, которую нужно удалить, дважды нажмите по имени службы, остановите её (если она останавливается) и посмотрите на имя службы вверху вкладки «Общие». 
    Имя службы Windows 10

  2. Запустите командную строку от имени Администратора. В Windows 10 для этого можно начать набирать «Командная строка» в поиске на панели задач, а затем нажать по найденному результату правой кнопкой мыши и выбрать «Запустить от имени Администратора». 
    Запуск командной строки от администратора в Windows 10

  3. В командной строке введите команду sc delete имя_службы и нажмите Enter. 
    Удаление службы в командной строке

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

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

Как удалить службу Windows 10 в редакторе реестра

Этот метод удаления служб может иметь более нежелательные последствия, поскольку вы имеете возможность удалить даже те службы, которые необходимы Windows 10 для работы. Шаги удаления службы Windows 10 в редакторе реестра:

  1. Так же, как в предыдущем случае посмотрите имя службы в services.msc
  2. Нажмите клавиши Win+R, введите regedit и нажмите Enter.
  3. В открывшемся редакторе реестра перейдите к разделу HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services
  4. Внутри этого раздела найдите подраздел с именем службы, которую нужно удалить. Удалите этот подраздел. 
    Удалить службу Windows 10 в редакторе реестра

  5. Перезагрузите компьютер.

На этом удаление службы будет завершено.

Services are kind of like the backbone of the operating system and the apps that run on it. But, sometimes you might need to remove a service. Maybe you’re troubleshooting, trying to speed up your computer a little bit, or getting rid of a service that was left behind by a program you’ve already uninstalled.

In this guide, we’ll show you how to safely delete a service in Windows 11 or Windows 10 using Command Prompt (CMD). We’ll also talk about what to watch out for and how to make sure you don’t mess things up.

How to Delete a Service in Windows 11 Using CMD

Why delete a service?

So, why would you want to delete a service sometimes?

  • Getting rid of a program that left its service behind.
  • Removing a service that’s causing problems or clashing with others.
  • Trying to make your computer run slightly faster by getting rid of services you don’t need.

You should know what a service does before you decide to delete it. If you remove something important, it can cause serious issues.

Also see: 30+ Windows 11 Services to Disable for Gaming Performance

Remove Windows 11 Service in Command Prompt

What happens if you delete a service in Windows 11 or 10?

After deleting a service, the programs or even the system itself that rely on the removed service will not be able to use the functions provided by the service. Most will stop working right away, while some will have issues with part of their features.

Some programs will automatically restore the service when it finds that it’s missing, while for the others that don’t, you will need to reinstall the app in order to bring back the service should you need to.

Therefore, please think twice before deleting a service because you might cause more harm than good if many things need that specific service to work. A smart way would be to create a system restore point first prior to removing any service in Windows. This way, if something goes south, you can still go back to how things were.

If you just want to turn the service off instead of deleting it, check out: How to disable startup services on Windows 11 or 10.

Opening Command Prompt as administrator

Before we start deleting anything, we need to open Command Prompt as an admin, because you need special permissions to delete services.

  1. Hit the Start button or press the Win key.
  2. Search for “cmd” or “Command Prompt”.
  3. Right-click Command Prompt in the results and choose Run as administrator. If it asks for permission, click Yes.

Useful tip: Run CMD, PowerShell or Regedit as SYSTEM in Windows 11

Command Prompt Run as Administrator

List services using “sc query” command

First off, we need to find the service you want to delete. We’ll use the sc query command to see all the services on your computer.

In Command Prompt, type this and hit Enter:

sc query type= service

List all services in Windows 11 using command prompt

This will show you a list of all services, with their SERVICE_NAME and DISPLAY_NAME. Note down the SERVICE_NAME of the one you want to delete.

Checking service dependencies

Before getting rid of a service, you need to see if other services rely on it. Deleting a service that other services need can cause unwanted problems.

To check a service’s dependencies, type this in Command Prompt, swapping <SERVICE_NAME> with the service’s name:

sc qc <SERVICE_NAME>

List a service dependencies in Windows 11 CMD

Look for the DEPENDENCIES section. If it’s empty, you’re good to go to the next step.

Stop a service using “sc stop” command

Before deleting a service, we need to stop it if it’s running. We’ll use the sc stop command for this. Just type the following, but use the name of the service you’re stopping instead of <SERVICE_NAME>:

sc stop <SERVICE_NAME>

For instance, to stop “SampleService”, you’d write:

sc stop SampleService

Stop a service in Windows 11 using command line

Hit Enter. If it stops successfully, you’ll get a message saying so. If it wasn’t running, it’ll tell you that too.

Note: Stopping a service could affect other things that depend on it. Make sure you know what you’re doing before you hit stop.

Delete a service using “sc delete” command

After stopping the service and checking it has no dependencies, you can delete it. Just type the following in Command Prompt. Replace <SERVICE_NAME> with the service’s name.

sc delete <SERVICE_NAME>

If you’re deleting “SampleService”, here’s what you’d type:

sc delete SampleService

SC Command line to delete service in Windows 11 10

Press Enter. If everything goes right, you’ll see a message saying the service was deleted.

Related resource: How to Delete a Ghost File or Folder in Windows 11/10

Document changes made to services

When you delete or change a service, keep a record of what you did. Write down which service you stopped, modified, or deleted and why. This can be very useful if you need to troubleshoot in the future or if you need to reverse the changes. It also helps if someone else, like your system admin, needs to know what was changed on the system.

Check with a pro if you’re not sure

If you’re not completely confident about what a service does or whether it’s safe to delete it, you should definitely ask for opinion from an expert first. Whether it’s a tech-savvy friend or a professional, getting a second opinion can prevent catastrophic mistakes that might be very difficult to fix.

Все способы:

  • Удаление служб
    • Способ 1: «Командная строка»
    • Способ 2: Реестр и файлы служб
    • Заключение
  • Вопросы и ответы: 1

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

Удаление служб

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

Способ 1: «Командная строка»

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

  1. Обращаемся к системному поиску, нажав на значок лупы возле кнопки «Пуск». Начинаем писать слово «Службы», а после того, как появится выдача, переходим к классическому приложению с соответствующим названием.
    Переход к приложению Службы из системного поиска в Windows 10

  2. Ищем целевой сервис в списке и кликаем дважды по его названию.

    Переход к свойствам системного сервиса в оснастке Службы в Windows 10

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

    Копирование имени сервиса в оснастке Службы в Windows10

  4. Если служба запущена, то ее нужно остановить. Иногда сделать это невозможно, в таком случае просто переходим к следующему шагу.

    Остановка системного сервиса в оснастке Службы в Windows 10

  5. Закрываем все окна и запускаем «Командную строку» от имени администратора.

    Подробнее: Открытие командной строки в Windows 10

  6. Вводим команду для удаления с помощью sc.exe и жмем ENTER.

    sc delete PSEXESVC

    PSEXESVC – имя сервиса, которое мы скопировали в пункте 3. Вставить его в консоль можно, нажав в ней правую кнопку мыши. Об успешном выполнении операции нам скажет соответствующее сообщение в консоли.

    Удаление системной службы с помощью Командной строки в Windows 10

На этом процедура удаления завершена. Изменения вступят в силу после перезагрузки системы.

Способ 2: Реестр и файлы служб

Случаются ситуации, когда невозможно удалить сервис приведенным выше способом: отсутствие такового в оснастке «Службы» или отказ при выполнении операции в консоли. Здесь нам поможет ручное удаление как самого файла, так и его упоминания в системном реестре.

  1. Снова обращаемся к системному поиску, но на этот раз пишем «Реестр» и открываем редактор.

    Доступ к редактору системного реестра из поиска в Windows 10

  2. Переходим в ветку

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services

    Ищем папку с тем же названием, что и наша служба.

    Переход к папке с параметрами сервиса в редактрое системного реестра в Windows 10

  3. Смотрим на параметр

    ImagePath

    Он содержит путь к файлу службы (%SystemRoot% — это переменная среды, указывающая путь к папке «Windows», то есть «C:\Windows». В вашем случае буква диска может быть другая).

    Параметр системного реестра с адресом файла службы в Windows 10

    Читайте также: Переменные среды в Windows 10

  4. Переходим по этому адресу и удаляем соответствующий файл (PSEXESVC.exe).
    Удаление файла службы из системной папки в Windows 10

    Если файл не удаляется, попробуйте сделать это в «Безопасном режиме», а в случае неудачи ознакомьтесь со статьей по ссылке ниже. Также почитайте комментарии к ней: там приведен еще один нестандартный способ.

    Подробнее:
    Как зайти в безопасный режим на Windows 10

    Если файл не отображается по указанному пути, возможно, он имеет атрибут «Скрытый» и (или) «Системный». Для отображения таких ресурсов нажимаем кнопку «Параметры» на вкладке «Вид» в меню любой директории и выбираем «Изменить параметры папок и поиска».

    Переход к настройке параметров папок и поиска из Проводника Windows 10

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

    Включение отображения скрытых и системных файлов и папок в настройках Windows 10

  5. После того, как файл будет удален, или не найден (такое бывает), или путь к нему не указан, возвращаемся в редактор реестра и целиком удаляем папку с именем службы (ПКМ – «Удалить»).

    Удаление раздела с параметрами сервиса в редакторе системного реестра в Windows 10

    Система спросит, действительно ли мы хотим выполнить данную процедуру. Подтверждаем.

    Подтверждение удаления раздела с параметрами сервиса в редакторе системного реестра в Windows 10

  6. Перезагружаем компьютер.

Заключение

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

Подробнее: Борьба с компьютерными вирусами

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

Наша группа в TelegramПолезные советы и помощь

This tutorial provides step-by-step instructions on how to delete Windows service from command line or registry. These instructions work on both Windows 10 and Windows 11 and allow you to remove orphaned or unwanted services.

Overview of Windows services

Windows services are special programs that run in the background on your computer. They start with your system and provide functions that need to run continuously and don’t need your ongoing interaction. For example, antivirus runs a service in the background that continually monitors your files for viruses, as it needs to perform this task from the moment the computer starts and doesn’t need your input (if action needs to be taken, it can communicate with an associated desktop application that asks you to review its findings, install an update, etc.).

Services are different from standard applications in that they don’t have a direct interface and do not show up in the system tray or start bar, effectively hiding them from you during day-to-day use. Most services are part of Windows itself, providing sound, networking, and audio functionality, while others are added by third-party applications like third-party antivirus, firewalls, or file sharing and networking platforms.

You may want to delete a service on Windows because it is left over from an uninstalled application, or it is wasting resources. Uninstalling services must be done correctly to prevent your system from malfunctioning.

Precautions before deleting a Windows service

Before you perform any maintenance on your Windows PC, you should take a full backup of your system. If you’re deleting a service from the Windows registry, you should also take a registry backup.

You should also make sure you understand exactly which service you are deleting and its purpose to avoid accidentally removing the wrong service (and potentially something your system relies on to operate). You should at the very least search for the service name online before you delete it to make sure it isn’t something you need.

Deleting Windows Services via the Command Line

To delete a Windows service using the command line, follow these instructions:

  • Open the Services Manager console by right-clicking on the Start menu, clicking Run, and entering services.msc.
  • Find the service you want to delete in the list, and right-click on it. If Stop is not grayed out, click it to stop the service.
  • Make a note of the service name exactly as it is spelled in the Name column.
  • Right-click on the Start menu again, and click on Terminal (Admin), or Command Prompt (Admin) if you’re on Windows 10.
  • Enter the command sc delete SERVICENAME, replacing SERVICENAME with the exact name you recorded earlier.

Deleting Windows Services via the Command Line

This will delete the service from the configured Windows services. Once this is done, you can delete any files associated with the service.

To confirm that the service has been removed, you can press the refresh button in the Services Manager to check that it has been successfully deleted.

Deleting Windows services via registry editor

Attempting to delete a Windows service using the registry should be a last resort if the above method fails, as making a mistake when editing the registry risks damaging your Windows installation. As previously mentioned, make sure you take a backup before attempting these steps:

  • Right-click on the Start menu, click Run, and enter regedit.
  • Back up the registry by selecting Export from the File menu.
  • Follow the same process as in the previous Command Line steps to open the Services Manager console to find the name of the service you want to delete, and stop it if it is running.
  • Navigate to the Services key at the path: HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServices
  • Find the service you wish to delete by scrolling through the list of registry keys in the navigation tree in the left pane, and clicking on the folder icon next to the entry will display additional information.
  • In the left pane, right-click on the folder for the service you want to remove, and click Delete.
  • Confirm the deletion, and restart your computer.

The reboot step is necessary to reload the registry. Again, you can confirm that the service was successfully removed by checking the Services Management console.

Comparing the Command Line and registry methods

You should try to use the sc delete command from the command line whenever possible. This method is far safer as it reduces the chance of mistakenly deleting the wrong registry key and doesn’t require a restart. It also handles removing other configurations such as scheduled tasks and error logging, as well as any service accounts the process used.

Delete Windows service from command-line FAQ

Can I recover a deleted Windows service?

You cannot recover Windows service that has been uninstalled without re-installing the original application, or restoring from a system backup.

What happens if I delete a service that Windows needs?

If you delete a service that Windows relies on, your PC may not boot, or specific functionality related to the service may fail (for example, automatic updates will stop working if you disable the Windows Update service).

Are there third-party tools for deleting Windows services that are easier to use?

NSSM (Non-Sucking Service Manager) is a free and open-source tool for managing Windows services that includes functionality for deleting Windows service.

How do I clean up after removing a Windows service?

Using the sc delete command will clean up much of the configuration for a service, but files from the original application may still be left behind in your Program Files folder and other directories. You’ll need to find these yourself and manually remove them.

Windows service management best practices for organizations

If you want to make sure that only approved software is running on your fleet of Windows devices, endpoint management software by NinjaOne helps you remotely patch and manage your Windows machines, ensuring they are not harboring malware in their hidden services, and providing full visibility over your IT infrastructure and end-user devices.

How to Delete Services in Windows 10

Windows has a lot of administrative tools to give you complete control over your system. And rightly so, many programs install additional services, telemetry tools, drivers, and more on your system to function properly. However, many times these drivers and services can end up taking precious processing power on your system. Additionally, when you remove the concerned software, the service might not be deleted from Windows.

This is one of the reasons why many people tend to manually delete leftover services in Windows 10. Leftover services tend to keep running in the background which can take a hit on your processor and RAM. If you have been experiencing performance issues and stuttering on your PC then it might be time to manually delete unwanted services on your system. Let’s take a look at how you can do this.

Find the service that you wish to delete

Deleting a service from Windows 10 is a moderately difficult process that starts by first identifying the service you wish to remove. Follow the guide below to find and identify the service you wish to remove from your PC.

Click on the ‘Start’ menu and search for ‘Services’. Click on the first app that shows up in your search results.

You will now see a list of all the services currently installed on your PC. You can sort them by various filters including name, type, status, and more by simply clicking the desired filter at the top of your screen. This should help you easily find the service that you wish to remove.

Once you have found the service, right-click on it and select ‘Properties’.

Now note down the service name given at the top of your screen.

Note: Ensure that you save/note down the service name and not its display name. 

You are now ready to remove the service from your system. Follow the guide below to remove the service.

Remove service from registry editor

We will now start by removing the service from your registry editor first. This will help us remove the service completely from your system. Additionally, cleaning the registry for the particular service will also ensure that you do not face any background errors due to leftover files.

Click on the start menu and type in ‘regedit.msc’. You should see a search result for the registry editor before you finish writing the entire name. Click on ‘Run as administrator’ in the right tab of the start menu.

Now navigate to the following directory given below.

Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services

You will now see a list of all the services currently installed on your system. Scroll the list and find the service you wish to delete. Once found, click on it and press delete on your keyboard.

Confirm your choice by clicking on ‘Yes’ in the confirmation dialog box.

The service should now be removed from the registry editor. It’s time to now remove the service from your system entirely using the command prompt.

Remove the service using CMD

Now that the concerned service has been removed from the Windows registry, we can now delete it from your system.

Start by clicking on the Start menu and search for ‘cmd’. Once the command prompt shows up in the search results, click on ‘Run as administrator’ in the right tab.

The command prompt should now open up with administrator privileges. Type in the following command given below. Replace ‘<name>’ with the name of the service you wish to delete.

sc delete <name>

Note: This is the service name that you noted down earlier and not the display name. 

Press ‘Enter’ on your keyboard to execute the command.

You should now get a confirmation stating that the command was a success. And that’s it! You have now removed the concerned service from your system. Restart your PC for good measure and you should be good to go.

I hope you were able to easily delete Windows 10 services using this method. If you face any issues or have any additional questions, reach out to us using the comments below. 

Read Next

Subscribe to Newsletter

Join me on this exciting journey as we explore the boundless world of web design together.

Понравилась статья? Поделить с друзьями:
0 0 голоса
Рейтинг статьи
Подписаться
Уведомить о
guest

0 комментариев
Старые
Новые Популярные
Межтекстовые Отзывы
Посмотреть все комментарии
  • Не отображается dvd привод в windows 10
  • Как сделать значки на панели задач меньше windows 11
  • Dexp wifi адаптер драйвер windows 7
  • Отключение энергосберегающего режима windows 10
  • Nvidia geforce 9600 gt драйвер windows 7 32bit