windows - Windows 7 启动/引导的时间

标签 windows windows-7 event-viewer

<分区>

我想查看操作系统的启动时间。即最近一个月,Windows 启动的次数。这有可能查出来吗?

最佳答案

PowerShell和系统事件日志是为这项任务完美设计的。注意 id 为 12 的事件是 System Start Up 事件,而 id 13 表示 System Shutdown。以下 PowerShell 脚本将提供您的系统在一个月内的启动和关闭时间。

echo "Start time:"
Get-EventLog System -After 12/21/2011 | ? {$_.EventId -eq 12} | % {$_.TimeGenerated}
echo "Shutdown time:"
Get-EventLog System -After 12/21/2011 | ? {$_.EventId -eq 13} | % {$_.TimeGenerated}

12/21/2011 替换为您想要的任何日期。单击“开始”菜单,键入“powershell”,然后回车将启动 Windows PowerShell。

关于windows - Windows 7 启动/引导的时间,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8959193/

相关文章:

c# - 获取 Windows 7 中语言栏的当前所选语言

linux - 在 Windows 7 上设置 OpenSSH 服务器以进行基于 key 的身份验证

windows - WEVTUtil 导出特定事件

c++ - 用于 Windows 开发的 GStreamer 或 DirectShow?

windows - PhoneGap错误: EPERM: Operation not permitted (windows 10)

c++ - 使用信号情报

windows-7 - Nullsoft 安装程序,如何使 ProgramData 子文件夹可写

.net - 为什么在事件查看器中收到VB6应用程序的.NET运行时错误?

c# - 将服务器/代码升级到 TLS 1.2,事件日志中出现重复错误

windows - 如何复制/镜像文件,但仅作为文件长度为 0 的占位符?