是关闭.exe有必要关闭窗户吗?

是关闭.exe在关闭Windows时是必要的,还是只是用来关闭Windows的一部分?是否使用了其他文件和/或进程?今天的超级用户问答帖子回答了一位好奇的读者的问题。...

是关闭.exe有必要关闭窗户吗?

是关闭.exe在关闭Windows时是必要的,还是只是用来关闭Windows的一部分?是否使用了其他文件和/或进程?今天的超级用户问答帖子回答了一位好奇的读者的问题。

今天的问答环节是由SuperUser提供的,SuperUser是Stack Exchange的一个分支,是一个由社区驱动的问答网站分组。

问题

超级用户读者Mukul Kumar想知道关闭.exe是关闭Windows所必需的:

Is the file C:\Windows\System32\shutdown.exe necessary to shut down or restart Windows?

是关闭.exe是否需要关闭或重新启动Windows?

答案

超级用户贡献者JdeBP为我们提供了答案:

Your question of course originates from your answer at StackExchange, in particular from kinokijuf’s comment upon the initial revision of your answer.

As kinokijuf said, Windows is not Unix. On Unices and Linux, shutdown is indeed involved in the full shut down process. It is the program that sends regular warning messages to logged-in users and that writes the /run/nologin file to prevent further logging-on a short while before the scheduled shut down time.

On Windows NT, this is not the case.

The “shut down” action on the “power button” on the Windows Explorer Start menu, the “shut down” menu option in Task Manager, REBOOT /S in TCC or Take Command, and other application programs that allow you to shut the system down all initiate shut down by directly calling one of two Win32 API calls: InitiateSystemShutdownEx() or ExitWindowsEx(). They do not do things indirectly by running the shut down program. That actually needs more code to do than just calling the Win32 API call. The shut down program, when one is doing a local shut down, calls those same Win32 API calls too.

It is actually winlogon, csrss, and **ss that are the programs that shut down Windows NT. In particular, it is winlogon that does the main work of processing deferred shut down requests.

Further Reading

  • Jonathan de Boyne Pollard (2006). The Windows NT 6 shutdown process. Frequently Given Answers.
  • Shutdown. FreeBSD 9.2 manual pages. 2013-03-19.
  • Shutdown. Systemd manual pages. 2013. Freedesktop.org.
  • Shutdown. Upstart manual pages. 2009. Canonical Ltd.
  • InitiateSystemShutdownEx. MSDN. Microsoft corporation.
  • ExitWindowsEx. MSDN. Microsoft corporation.
  • REBOOT. Take Command / TCC Help. JP Software.

有什么要补充的解释吗?在评论中发出声音。想从其他精通技术的Stack Exchange用户那里了解更多答案吗?在这里查看完整的讨论主题。

  • 发表于 2021-04-11 10:52
  • 阅读 ( 157 )
  • 分类:互联网

你可能感兴趣的文章

管理和控制windows关闭的4个工具

...将向您展示一些工具,帮助您阻止、自动化、记录和加速关闭过程。下面提供的所有程序都是免费的、轻量级的,这意味着它们不会使系统资源过载。 ...

  • 发布于 2021-03-13 02:27
  • 阅读 ( 348 )

关闭Windows10笔记本电脑屏幕的7种方法

... 但别担心,还是可以关闭笔记本电脑屏幕的。也许更令人惊讶的是,实现这一点有多种方法——实际上有七种方法。继续阅读,学习如何关闭笔记本电脑屏幕。 ...

  • 发布于 2021-03-14 02:08
  • 阅读 ( 191 )

12+自定义windows键盘快捷键,适合你的极客

... 用快捷方式关闭 ...

  • 发布于 2021-03-16 17:33
  • 阅读 ( 576 )

如何禁用microsoft office上载中心

... 如何关闭microsoft上载中心 ...

  • 发布于 2021-03-20 03:33
  • 阅读 ( 444 )

11个奇怪的窗户虫子和复活节彩蛋

...ows 10中,按Windows+Q,键入telnet,然后从结果中选择打开或关闭Windows功能。向下滚动直到看到Telnet客户机条目,选中该框,然后单击OK。等待Windows完成请求的更改,然后单击“关闭”。 ...

  • 发布于 2021-03-25 13:30
  • 阅读 ( 307 )

什么是桌面窗口管理器(dwm.exe文件)你需要吗?

...之,您不能禁用桌面窗口管理器。旧版本的Windows允许您关闭DWM,如果您不关心视觉效果的话。但由于该功能现在已成为操作系统不可或缺的一部分,因此在Windows10(或8)中不提供此选项。 ...

  • 发布于 2021-03-29 10:01
  • 阅读 ( 850 )

什么是“广播dvr服务器”,为什么它在我的电脑上运行?

...情况发生,请进入“设置”>“游戏”>“游戏DVR”。关闭“在玩游戏时在后台录制”选项,广播DVR服务器将不会使用系统资源录制任何内容,除非您手动选择从游戏栏开始录制。 我可以禁用它吗? 相关:如何禁用Windows10的...

  • 发布于 2021-04-07 04:57
  • 阅读 ( 217 )

什么是“com代理”(进程空间)为什么它在我的电脑上运行?

...器。 但是,这可能会导致问题。如果COM对象崩溃,它将关闭其主机进程。有一次,这些生成缩略图的COM对象崩溃并破坏整个Windows资源管理器进程是很常见的。 为了解决这类问题,Microsoft创建了COM代理进程。COM代理进程在请求它...

  • 发布于 2021-04-07 05:09
  • 阅读 ( 195 )

什么是客户机-服务器运行时进程(csrss.exe文件),为什么它在我的电脑上运行?

...indows内核中。然而csrss.exe文件进程仍然负责控制台窗口和关闭进程,这是windows中的关键功能。 相关:什么是conhost.exe为什么它在运行? 在Windows7之前,CSRSS进程绘制控制台(命令提示符)窗口本身。在Windows7及更高版本上,控制...

  • 发布于 2021-04-07 08:22
  • 阅读 ( 291 )

什么是桌面窗口管理器(dwm.exe文件)为什么要跑?

...关:如何在Windows8或Windows10中使用新的任务管理器 我可以关闭桌面窗口管理器吗? 不,你不能。回到Vista时代,桌面窗口管理器通过一个服务来控制,你可以关闭,然后禁用所有的视觉效果。从Windows7开始,桌面窗口管理器成为W...

  • 发布于 2021-04-07 17:11
  • 阅读 ( 239 )
gp694216746
gp694216746

0 篇文章

相关推荐