您可能已经知道这一点,但是如果您想查看Windows启动时运行的所有启动程序的列表,您只需转到MSCONFIG工具并单击“启动(Startup)”选项卡!在这里,您可以轻松启用或禁用启动程序。您可以阅读我之前的文章,其中详细解释了如何使用MSCONFIG。
值得注意的是,在Windows 8和Windows 10中,启动选项卡(Startup tab)已从MSCONFIG中删除,现在包含在任务管理器(Task Manager)中。您只需右键单击Windows 8或 Windows 10中的“开始”按钮(Start button)并从列表中选择“任务管理器”即可进入(Task Manager)任务管理器。(Task Manager)
了解哪些程序在启动时运行对于调试与您的 PC 相关的各种性能问题非常有用。我总是给出的一个建议是列出在您的计算机正常运行时启用的所有启动程序。这样,如果您的计算机稍后运行缓慢,您可以随时返回MSCONFIG并取消选中最初未列出的任何内容。
此外,有时技术支持可能会要求提供启动程序列表,以诊断您的计算机问题。生成一个列表并通过电子邮件发送给他们可以节省您大量的时间,并防止有人(time and prevent someone)必须远程连接到您的计算机,我从不喜欢这种方式,因为我不相信任何(t trust anyone)其他人可以访问我的计算机。
除了任务管理器在(task manager)Windows 8和Windows 10中看起来更好更干净之外,它还放弃了复选框,并为您提供了一个名为Startup Impact的列,以帮助您衡量该启动项如何影响启动时间(boot time)。
实际上,您可以使用命令提示符或 PowerShell生成(command prompt or PowerShell)Windows中所有启动程序的列表,并将该列表保存为文本文件(text file)或HTML 文档(HTML document)。请按照以下步骤操作。
命令提示符
第 1 步:(Step 1:)通过转到Start、Run并输入CMD打开命令提示符(command prompt)。如果您对命令提示符(command prompt)不熟悉,请先阅读我的命令提示符初学者(command prompt beginner)指南。
第 2 步:(Step 2:)现在在提示符处键入以下WMI(Windows Management Instrumentation)命令,然后按(prompt and press) Enter。
wmic startup get caption,command
您现在应该会看到所有应用程序的列表及其在Windows 启动(Windows startup)时运行的路径。
如果你想了解更多信息,你也可以只输入wmic startup,你会得到一些额外的字段,比如Location、UserSID 和 User(UserSID and User)。
第 3 步:(Step 3:)如果要将列表导出为文本文件(text file),请输入以下命令:
wmic startup get caption,command > c:\StartupApps.txt
如果你想创建一个HTML 文件(HTML file),只需输入:
wmic startup get caption,command > c:\StartupApps.htm
电源外壳
如果您更喜欢使用更现代、更强大的PowerShell,下面的命令将为您提供与上面的(command below)WMI 命令(WMI command)几乎相同的结果。
Get-CimInstance Win32_StartupCommand | Select-Object Name, command, Location, User | Format-List
如果要将PowerShell 命令(PowerShell command)的输出发送到文本文件(text file),只需将以下部分附加到Format-List之后的上述命令(above command)。
| Out-File c:\scripts\test.txt
确保(Make)包含管道symbol |那是最前面的。我实际上更喜欢PowerShell的输出,因为格式更容易在文本编辑器(text editor)中查看。
就是这样。您现在应该有一个启动程序列表,您可以在以后保存和参考。如果您有任何问题,请随时发表评论。享受!
Generate a List of Startup Programs via Command Line or PowerShell
You рrobably already knew this, but if you want to see a list of all of the startup prоgrams thаt run when Windows starts, you can simply go to the MSCONFIG tool and click on the Startup tab! Here you can enable or disable startup programs easily. You can read my previous article that explains how to use MSCONFIG in detail.
It’s worth noting that in Windows 8 and Windows 10, the Startup tab has been removed from MSCONFIG and is now included in the Task Manager. You can get to the Task Manager by simply right-clicking on the Start button in Windows 8 or Windows 10 and choosing Task Manager from the list.
Knowing which programs run at startup can be very useful for debugging all sorts of performance issues related to your PC. One recommendation I always give is to make a list of all of the startup programs enabled while your computer is running normally. That way, if your computer is running slow later on, you can always go back to MSCONFIG and uncheck anything that wasn’t originally listed.
Also, there are times when technical support may request a list of startup programs in order to diagnose an issue with your computer. Generating a list and emailing them could save you a lot of time and prevent someone from having to connect remotely to your computer, which I never prefer since I don’t trust anyone else having access to my computer.
In addition to the task manager looking a bit nicer and cleaner in Windows 8 and Windows 10, it also forgoes the checkboxes and gives you a column called Startup Impact to help you gauge how that startup item affects the boot time.
You can actually generate a list of all the startup programs in Windows using the command prompt or PowerShell and save the list as a text file or an HTML document. Follow the steps below.
Command Prompt
Step 1: Open the command prompt by going to Start, Run and typing in CMD. If you are unfamiliar with the command prompt, feel free to read my command prompt beginner’s guide first.
Step 2: Now type in the following WMI (Windows Management Instrumentation) command at the prompt and press Enter.
wmic startup get caption,command
You should now see a list of all the applications along with their paths that run at Windows startup.
If you want more information, you can also just type wmic startup and you’ll get a few extra fields like Location, UserSID and User.
Step 3: If you want to export the list out as a text file, type in the following command:
wmic startup get caption,command > c:\StartupApps.txt
And if you want to create an HTML file, just type this instead:
wmic startup get caption,command > c:\StartupApps.htm
PowerShell
If you prefer to use the more modern and powerful PowerShell, the command below will give you pretty much the same results as the WMI command above.
Get-CimInstance Win32_StartupCommand | Select-Object Name, command, Location, User | Format-List
If you want to send the output of a PowerShell command to a text file, you can simply append the following part to the above command after Format-List.
| Out-File c:\scripts\test.txt
Make sure to include the pipe symbol | that is at the very front. I actually prefer the output of PowerShell because the formatting is much easier to view in a text editor.
That’s about it. You should now have a list of startup programs that you can save and reference later. If you have any questions, feel free to post a comment. Enjoy!