什么文件可以打开大日志_什么是日志文件(以及如何打开一个文件)?

什么文件可以打开大日志

什么文件可以打开大日志

Sometimes the best way to troubleshoot and operating system, application, or service is to consult the log file(s) that app or service generates as it goes about its business. But what is a LOG file and how do you see what’s in it?

有时,对操作系统,应用程序或服务进行故障排除的最佳方法是查询应用程序或服务在开展业务时所生成的日志文件。 但是什么是LOG文件,您如何查看其中的内容?

什么是日志文件? (What Is a Log File?)

LOG is the file extension for an automatically produced file that contains a record of events from certain software and operating systems. While they can contain a number of things, log files are often used to show all events associated with the system or application that created them. For example, your backup program might keep log files showing exactly what happened (or didn’t happen) during a backup. Windows keeps all kinds of log files for its various services.

LOG是自动生成的文件的文件扩展名 ,其中包含来自某些软件和操作系统的事件的记录。 尽管它们可以包含许多内容,但日志文件通常用于显示与创建它们的系统或应用程序相关的所有事件。 例如,您的备份程序可能会保留日志文件,以准确显示备份期间发生(或未发生)的情况。 Windows为其各种服务保留各种日志文件。

The point of a log file is to keep track of what’s happening behind the scenes and if something should happen within a complex system, you have access to a detailed list of events that took place before the malfunction. Basically, whatever the application, server, or OS thinks needs to be recorded.

日志文件的目的是跟踪幕后发生的事情,如果复杂系统中应发生某些事情,则可以访问发生故障之前发生的事件的详细列表。 基本上,无论应用程序,服务器还是操作系统认为都需要记录。

While most log files contain the .log file extension, sometimes applications may use the .txt extension or a different proprietary extension, instead.

尽管大多数日志文件都包含.log文件扩展名,但有时应用程序可能会使用.txt扩展名或其他专有扩展名来代替。

我如何打开一个? (How Do I Open One?)

Because most log files are recorded in plain text, the use of any text editor will do just fine to open it. By default, Windows will use Notepad to open a LOG file when you double-click on it.

由于大多数日志文件均以纯文本格式记录,因此使用任何文本编辑器都可以很好地打开它。 默认情况下,当您双击记事本时,Windows将使用记事本打开它。

You almost certainly have an app already built-in or installed on your system for opening LOG files. To start with, if you’ve got any word processing app installed—Microsoft Word, LibreOffice, OpenOffice, Notepad++, and so on—you can open a LOG file with it.

几乎可以肯定,您的系统上已经内置或安装了一个用于打开LOG文件的应用程序。 首先,如果您安装了任何文字处理应用程序(Microsoft Word,LibreOffice,OpenOffice,Notepad ++等),则可以使用它打开LOG文件。

If you don’t have a text editor, some web browsers support viewing of log files as well. All you have to do is drag and drop the file you want to open into a new tab.

如果您没有文本编辑器,则某些Web浏览器也支持查看日志文件。 您所要做的就是将要打开的文件拖放到新选项卡中。

Your browser will then display everything contained in the file in the new tab.

然后,浏览器将在新选项卡中显示文件中包含的所有内容。

If you prefer that LOG files open with a different program than the current default, you can change it. On both Windows or macOS, just right-click the file and select the “Open With” command for picking the program you want to use.

如果您希望使用不同于当前默认设置的其他程序打开LOG文件,则可以对其进行更改。 在Windows或macOS上,只需右键单击文件,然后选择“打开方式”命令以选择要使用的程序。

Here’s the window that will pop up in Windows (macOS is similar) after you click that. All you have to do next is choose the program you want to use, select “Always Use This App To Open .LOG Files”, and click “OK”.

单击该窗口后,将在Windows中弹出该窗口(macOS与此类似)。 接下来要做的就是选择要使用的程序,选择“始终使用此应用程序打开.LOG文件”,然后单击“确定”。

Also keep in mind that some operating systems and applications have their own tools for viewing logs they generate. For example, events logged by Windows and many different Windows apps are more easily viewable in Event Viewer—a tool that lets you search your way and troubleshoot through all kinds of different Windows issues.

还请记住,某些操作系统和应用程序具有自己的工具来查看其生成的日志。 例如,在事件查看器中可以更轻松地查看Windows和许多其他Windows应用程序记录的事件 ,该工具可让您搜索自己的方式并解决各种不同的Windows问题。

翻译自: https://www.howtogeek.com/359463/what-is-a-log-file/

什么文件可以打开大日志

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值