Log file retrieval device and method and non-transient computer readable storage medium
Through the log file retrieval device and method, the processor and memory are used to receive and filter log files in real time, which solves the problem of being unable to monitor in real time and storage waste in the existing technology. Through the log file retrieval device and method, the problem of being unable to monitor in real time and storage waste in the existing technology is solved. Through the log file retrieval device and method, the problem of being unable to monitor in real time and storage waste in the existing technology is solved, and the problem of being unable to monitor in real time and storage waste in the existing technology is solved, and real-time filtering and storage space optimization are achieved.
Patent Information
- Application Number
- CN202410291500.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-14
- Publication Date
- 2025-09-26
AI Technical Summary
Existing technologies are unable to monitor and filter log files during the operation of the operating system in real time, resulting in an inability to handle problems in a timely manner and a serious waste of storage space.
Through the log file retrieval device and method, the processor and memory are used to receive, filter and process log files in real time, and the target log files are filtered out based on the input conditions. It supports keyword matching in Boolean search and regular expression formats, supports time interval and log file category filtering, and provides streaming processing to reduce storage requirements.
It achieves real-time filtering and monitoring of operating system problems, reduces storage space requirements, and improves development efficiency and problem-solving speed.
Smart Images

Figure CN120705251A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to a log file retrieval device, method, and non-transitory computer-readable storage medium. Specifically, the present disclosure relates to a log file retrieval device, method, and non-transitory computer-readable storage medium for filtering log files based on a search condition. Background Art
[0002] Existing log file tools mainly provide functions such as recording and viewing log files to help users track and record computer events and error conditions that occur during system execution.
[0003] In the prior art, if the contents of a log file are to be retrieved, a common practice is to first record all operation traces of the system and then retrieve the stored historical log files.
[0004] However, in this scenario, administrators are unable to monitor various issues that have occurred during operation in real time, and are unable to interpret the corresponding issues in the operating system's log files of different categories / warning levels in real time during operation. Furthermore, because existing technologies require storage before review, performing specific function tests or narrowing the search scope to the desired category is not only inconvenient, but also wastes storage space and cannot achieve effective and real-time filtering.
[0005] In view of this, how to provide a log file retrieval technology that can filter log files according to retrieval conditions is a goal that the industry urgently needs to work hard on. Summary of the Invention
[0006] This disclosure provides a log file retrieval device comprising a memory, a communication interface, and a processor. The memory is configured to store operation log files. The processor is electrically connected to the communication interface and the memory and configured to perform the following operations: receiving operation log files from the memory, wherein the operation log files correspond to events occurring in an operating system and each operation log file corresponds to a log file category of the operating system; extracting target retrieval conditions based on input information; filtering target log files from the operation log files based on the target retrieval conditions; and filtering log file retrieval results from the target log files based on the log file category corresponding to the target log files.
[0007] In some embodiments, each of the at least one search conditions is in a Boolean search expression format, and the operation of filtering multiple target log files from the multiple running log files further includes the following operation: in response to the multiple target log files having at least one matching log file that meets the at least one search condition, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval results include the multiple target log files.
[0008] In some embodiments, the input information also includes a time interval, and the operation of filtering multiple target log files from the multiple operation log files also includes the following operation: based on the at least one target retrieval condition and the time interval, filtering out the multiple target log files from the multiple operation log files, wherein the multiple target log files correspond to the time interval.
[0009] In some embodiments, each of the at least one target retrieval conditions corresponds to at least one target keyword, each of the at least one target keyword is in a regular expression format, and the operation of filtering multiple target log files from the multiple operation log files also includes the following operations: comparing each of the at least one target keyword with the multiple operation log files to determine whether the multiple operation log files have at least one matching log file that meets the at least one target keyword; and in response to the multiple operation log files having at least one matching log file that meets the at least one target keyword, adding the at least one matching log file to the multiple target log files.
[0010] In some embodiments, the input information also includes a specified log file category, and the operation of filtering out a log file retrieval result from the multiple target log files also includes the following operation: in response to the multiple target log files having at least one matching log file corresponding to the specified log file category, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval result includes the multiple target log files.
[0011] In some embodiments, the multiple target log file categories correspond to a priority order, and the operation of filtering out a log file retrieval result from the multiple target log files also includes the following operation: based on the multiple target log file categories corresponding to the multiple target log files, the multiple target log files are arranged according to the priority order, wherein the log file retrieval result includes the multiple target log files arranged in order.
[0012] In some embodiments, the communication interface is communicatively connected to a display and an input interface, the display is used to display a user interface, and the input interface is used to allow the user to input the input information.
[0013] The present disclosure provides a log file retrieval method applicable to a log file retrieval device, comprising: receiving an operation log file, wherein the operation log file corresponds to an event occurring in an operating system, and each operation log file corresponds to a log file category of the operating system; extracting a target retrieval condition based on input information; filtering a target log file from the operation log file based on the target retrieval condition; and filtering a log file retrieval result from the target log file based on the log file category corresponding to the target log file.
[0014] In some embodiments, each of the at least one search conditions is in a Boolean search expression format, and the step of filtering multiple target log files from the multiple running log files further includes the following steps: in response to the multiple target log files having at least one matching log file that meets the at least one search condition, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval results include the multiple target log files.
[0015] In some embodiments, the input information also includes a time interval, and the step of filtering multiple target log files from the multiple operation log files also includes the following steps: based on the at least one target retrieval condition and the time interval, filtering out the multiple target log files from the multiple operation log files, wherein the multiple target log files correspond to the time interval.
[0016] In some embodiments, each of the at least one target retrieval conditions corresponds to at least one target keyword, each of the at least one target keyword is in a regular expression format, and the step of screening multiple target log files from the multiple operation log files further includes the following steps: comparing each of the at least one target keyword with the multiple operation log files to determine whether the multiple operation log files have at least one matching log file that meets the at least one target keyword; and in response to the multiple operation log files having at least one matching log file that meets the at least one target keyword, adding the at least one matching log file to the multiple target log files.
[0017] In some embodiments, the input information also includes a specified log file category, and the step of filtering out a log file retrieval result from the multiple target log files further includes the following steps: in response to the multiple target log files having at least one matching log file corresponding to the specified log file category, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval result includes the multiple target log files.
[0018] In some embodiments, the multiple target log file categories correspond to a priority order, and the step of filtering out a log file retrieval result from the multiple target log files further includes the following steps: based on the multiple target log file categories corresponding to the multiple target log files, the multiple target log files are arranged according to the priority order, wherein the log file retrieval result includes the multiple target log files arranged in order.
[0019] In some embodiments, the communication interface is communicatively connected to a display and an input interface, the display is used to display a user interface, and the input interface is used to allow the user to input the input information.
[0020] The present disclosure provides a non-transitory computer-readable storage medium for storing a computer program, wherein the computer program includes a plurality of program instructions. The computer program executes a method for retrieving log files after being loaded into a log file retrieval device. The log file retrieval device includes a communication interface and a processor. The method includes the following steps: receiving an operation log file, wherein the operation log file corresponds to an event occurring in an operating system, and each operation log file corresponds to a log file category of the operating system; extracting a target retrieval condition based on input information; filtering a target log file from the operation log file based on the target retrieval condition; and filtering a log file retrieval result from the target log file based on the log file category corresponding to the target log file.
[0021] In some embodiments, each of the at least one search conditions is in a Boolean search expression format, and the step of filtering multiple target log files from the multiple running log files further includes the following steps: in response to the multiple target log files having at least one matching log file that meets the at least one search condition, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval results include the multiple target log files.
[0022] In some embodiments, the input information also includes a time interval, and the step of filtering multiple target log files from the multiple operation log files also includes the following steps: based on the at least one target retrieval condition and the time interval, filtering out the multiple target log files from the multiple operation log files, wherein the multiple target log files correspond to the time interval.
[0023] In some embodiments, each of the at least one target retrieval conditions corresponds to at least one target keyword, each of the at least one target keyword is in a regular expression format, and the step of screening multiple target log files from the multiple operation log files further includes the following steps: comparing each of the at least one target keyword with the multiple operation log files to determine whether the multiple operation log files have at least one matching log file that meets the at least one target keyword; and in response to the multiple operation log files having at least one matching log file that meets the at least one target keyword, adding the at least one matching log file to the multiple target log files.
[0024] In some embodiments, the input information also includes a specified log file category, and the step of filtering out a log file retrieval result from the multiple target log files further includes the following steps: in response to the multiple target log files having at least one matching log file corresponding to the specified log file category, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval result includes the multiple target log files.
[0025] In some embodiments, the multiple target log file categories correspond to a priority order, and the step of filtering out a log file retrieval result from the multiple target log files further includes the following steps: based on the multiple target log file categories corresponding to the multiple target log files, the multiple target log files are arranged according to the priority order, wherein the log file retrieval result includes the multiple target log files arranged in order.
[0026] According to the embodiments of the present disclosure, users can view the content they are concerned about in real time and more quickly, thereby reducing the time spent on debugging and achieving the technical effect of improving development efficiency; at the same time, providing and processing operation log files in a streaming manner can not only achieve real-time filtering, but also effectively reduce the required storage space.
[0027] The following describes the detailed technology and implementation methods of the present disclosure in conjunction with the accompanying drawings, so that those skilled in the art can understand the disclosed technical features for which protection is requested. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Figure 1A FIG. 1 is a simplified functional block diagram of a log file retrieval device according to the first embodiment of the present disclosure.
[0029] Figure 1B Schematic diagram of the operating environment of a log file retrieval device according to some embodiments of the present disclosure.
[0030] Figure 2A Schematic diagram of an input page of a user interface according to some embodiments of the present disclosure.
[0031] Figure 2B Schematic diagram of an input page of a user interface according to some embodiments of the present disclosure.
[0032] Figure 2C Schematic diagram of an output page of a user interface according to some embodiments of the present disclosure.
[0033] Figure 3 FIG. 4 is a partial flow chart of a log file retrieval method according to the second embodiment of the present disclosure.
[0034] Explanation of symbols
[0035] 100: Log file retrieval device
[0036] 110: Processor
[0037] 120: Memory
[0038] 130: Communication interface
[0039] 140: Display
[0040] 150: Input interface
[0041] 200: User interface
[0042] 210a, 210b: Input page
[0043] 211: Start button
[0044] 212: Keyword condition setting block
[0045] 213: Time interval setting block
[0046] 214: Search condition input block
[0047] 220: Output page
[0048] 221: Log file category filter block
[0049] 222: Store button
[0050] 223: Search results block
[0051] 300: Method
[0052] S310~S340: Steps DETAILED DESCRIPTION
[0053] The following will explain a log file retrieval device, method and non-transitory computer-readable storage medium provided by the present disclosure through implementation methods. However, these implementation methods are not intended to limit the present disclosure to any environment, application or method as described in these implementation methods. Therefore, the description of the implementation methods is only for the purpose of illustrating the present disclosure, and is not intended to limit the scope of the present disclosure. It should be understood that in the following implementation methods and drawings, elements that are not directly related to the present disclosure have been omitted and are not shown, and the sizes of each element and the size ratios between elements are only for illustration, and are not intended to limit the scope of the present disclosure.
[0054] The first embodiment of the present disclosure provides a log file retrieval device. Figure 1A ,in Figure 1A This is a simplified functional block diagram of a log file retrieval device 100 and its environment according to the first embodiment of this disclosure. The log file retrieval device 100 includes a processor 110, a memory 120, and a communication interface 130. The processor 110 is electrically connected to the memory 120 and the communication interface 130. The memory 120 is used to store multiple operation log files.
[0055] It should be noted that the memory 120 may be a hard disk, a Universal Serial Bus (USB) disk, an optical disk, a USB flash drive, or any other storage medium or circuit known to those skilled in the art and having equivalent functionality. The communication interface 130 is an interface capable of receiving and transmitting data, or any other interface capable of receiving and transmitting data known to those skilled in the art. The processor 110 may be any processing unit, a central processing unit (CPU), a microprocessor, or any other computing device known to those skilled in the art.
[0056] In the first embodiment, the memory 120 is used to store a plurality of operation log files. In this case, the log file retrieval device 100 can first store all the operation log files generated during the operation of the operating system (eg, Android operating system, Microsoft operating system).
[0057] In some embodiments, the operating system used is the Android operating system, and each runtime log file corresponds to a log file category, where the category can be one of "error," "warning," "info," "debug," and "verbose." "Error" includes errors that occur during the runtime of the operating system; "warning" includes issues that have not yet caused errors during the runtime of the operating system; "info" includes general information; "debug" includes debugging information that is only helpful for development; and "verbose" includes more detailed records of events that occur during the runtime of the operating system.
[0058] In some embodiments, the operation log file can be streamed to the log file retrieval device for calculation. In this case, the log file retrieval device 100 does not need to store the operation log file, but receives the operation log file in a streaming manner.
[0059] In addition, in some embodiments, the log file retrieval device 100 can further output the log file to the user through an output device (eg, a display), or the processor 110 can further process the log file. Figure 1B As shown, the log file retrieval device 100 can be connected to the display 140 and the input interface 150 via the communication interface 130 in a wired or wireless communication manner, wherein the display 140 is used to display the user interface 200, and the input interface 150 is used to allow the user to provide input information.
[0060] It should be noted that the input interface 150 may include, but is not limited to, one or more of the following: a keypad, a keyboard, a mouse, a touch screen that accepts gestures, a microphone, a voice recognition device, and any other suitable device. The user can interact with the user interface 200 to set the search criteria for searching the operation log files through the input interface 150.
[0061] In the first embodiment, the log file search device 100 receives a plurality of operation log files, wherein each operation log file corresponds to an event occurring in the operating system, and each operation log file corresponds to a plurality of log file categories of the operating system.
[0062] In some embodiments, the log file retrieval device 100 can receive a plurality of operation log files from an external device. For example, the log file retrieval device 100 can be connected to a tablet computer to receive the operation log files of the system on the tablet computer.
[0063] In some embodiments, the log file retrieval device 100 can be directly installed in the device that executes the operating system, and directly obtain a plurality of operation log files from the device.
[0064] In some embodiments, the log file retrieval device 100 can be installed in another device or integrated with a device having computing capabilities (e.g., sharing a processor with the device). For example, the log file retrieval device 100 can be installed in a laptop computer, the processor 110 can be a processor built into the laptop computer, and the communication interface 130 can be a communication interface built into the laptop computer.
[0065] In some embodiments, a runtime log file corresponds to a system event and contains a history of all applications, activities, and messages, as well as additional descriptive data (eg, timestamp) for understanding the information in its entirety.
[0066] Next, in the first embodiment, the log file search device 100 can further select multiple target log files from the multiple operation log files based on the input information. Specifically, the processor 110 extracts at least one target search condition based on the input information. Then, the processor 110 selects multiple target log files from the multiple operation log files based on the at least one target search condition.
[0067] For easier understanding, please refer to Figure 2A ,in Figure 2A FIG. 2 is a schematic diagram of an input page 210 a of the user interface 200 according to an embodiment of the present disclosure. The input page 210 a includes a start button 211 , a keyword condition setting block 212 , and a time interval setting block 213 .
[0068] Keyword condition setting block 212 allows the user to enter desired keyword conditions. For example, if a user wishes to search for log files related to "gcc," the user can enter the keyword "gcc" in keyword condition setting block 212 to add this condition. To add more search conditions, for example, to search for log files related to both "gcc" and "WLAN," the user can add the keyword "WLAN" after adding the keyword "gcc." Once all keywords have been added, click Start button 211 to begin searching the log files.
[0069] In some embodiments, each log file is formatted as a string. The processor 110 can use an existing string matching algorithm to match a given keyword or regular expression on each log file. If a log file successfully matches each keyword or satisfies a given search condition, the log file is added to the set of target log files.
[0070] In some embodiments, each keyword set via the keyword condition setting block 212 may have a regular expression format. For example, if the keyword to be matched is "gray" or "grey", the regular expression "gr[ae]y" may be used to match. After the log file retrieval device 100 receives a keyword in the regular expression format, it will match all keywords that conform to the regular expression and provide all matched operation log files to the user. It should be noted that the regular expression syntax used herein is only an example and the present disclosure is not limited thereto. Any syntax that can achieve string matching falls within the scope of the present disclosure.
[0071] In some embodiments, the keywords set in keyword condition setting block 212 can be combined using Boolean expressions. A "Boolean expression" as used herein refers to a common search syntax that uses operators such as "AND," "OR," and "NOT" to combine with at least one keyword. For example, if you want to match the keyword "gray" or "grey," you can use the expression "gray OR grey." For another example, if you want to search for runtime log files related to both "gcc" and "WLAN," you can use the expression "gcc AND WLAN." Parentheses can be used to create more complex expressions. For example, if you want to search for runtime log files that meet both the conditions of "containing 'gray' or 'grey'" and "related to 'gcc' and 'WLAN'," you can use the expression "(gray OR grey) AND (gcc AND WLAN)." It should be noted that the Boolean expression syntax used here is merely an example and is not intended to be limiting. Any syntax that can express Boolean logic falls within the scope of this disclosure.
[0072] In some embodiments, the user can also specify a time interval for searching. Based on the search criteria and the time interval, the log file search device 100 filters out target log files corresponding to the time interval from the operation log files. The time interval setting block 213 allows the user to specify a specific time interval. After the keyword criteria are set, the user can further set the time interval for searching the operation log files by interacting with the time interval setting block 213.
[0073] In some embodiments, the time interval can be established by selecting two time points. In some embodiments, a time interval can be selected from a set of predetermined time intervals to filter out log files that are within the predetermined time interval from the current time point. After setting the time interval, click the start button 211, and only log files with timestamps within the time interval will be provided to the user. In this way, the user can limit the scope of the log file search to a specific time interval.
[0074] refer to Figure 2B ,in Figure 2BSchematic diagram of input page 210b of user interface 200 according to one embodiment of the present disclosure. In some embodiments, the user can also perform a search by entering a search condition using a predetermined syntax in search condition input block 214. In some embodiments, the predetermined syntax may have a format similar to a Boolean expression, but may include more fields. For example, to search for log files that meet the requirements of "related to 'gcc' and 'WLAN'" and "time range from 12:30 PM, December 31, 2023, to 12:00 AM, January 1, 2024, Taipei Standard Time, Taiwan Province," the expression "(gcc AND WLAN) AND (TIME=1703997000:1704038400)" can be entered in search condition input block 214, where the time is expressed in UNIX timestamps. It should be noted that the syntax used here is merely an example and the present disclosure is not limited thereto.
[0075] refer to Figure 2C ,in Figure 2C Schematic diagram of the output page 220 of the user interface 200 according to the first embodiment of the present disclosure. The output page 220 includes a log file category filter block (Filter) 221, a save button (Save) 222, and a search result block (Search) 223. The log file category filter block 221 is used to allow the user to check the log file category to be viewed. For example, if the user wants to view log files with categories of "error" and "debugging", the user can check the two categories of "error" and "debugging" through the log file category filter block 221. Then, the search result block 223 can filter out the content of the log files that meet the search conditions and belong to either of the two categories of "error" and "debugging" to form the log file search results.
[0076] In some embodiments, the user can also export the log file search results to a file for storage by clicking the save button 222. The log file search results can be stored in an unstructured format, such as a plain text file, or formatted and stored in a structured or semi-structured format, including but not limited to JSON, XML, or CSV.
[0077] In some embodiments, each log file category can be assigned a priority, such as "Error," "Warning," "Information," "Debug," and "Details." In this case, the user can specify how the log file search results are sorted, for example, sorting them by priority first, then by timestamp.
[0078] In some embodiments, the search result block 223 may further display different parts of the log file content in different colors, or display the log file content in a formatted manner to facilitate user browsing. This allows users to more quickly view the content they are concerned about, thereby reducing the time spent on debugging.
[0079] As can be seen from the above description, the log file retrieval device 100 provided in the first embodiment of this disclosure facilitates user retrieval of log files containing content of interest. Furthermore, by providing and processing operation log files via streaming, not only real-time filtering is achieved, but also required storage space is effectively reduced. This allows administrators to monitor various operational issues in real time and diagnose and resolve various operating system issues in real time.
[0080] The second embodiment of the present disclosure provides a log file retrieval method, the flow chart of which is as follows: Figure 3 The log file search method 300 is applicable to an electronic device, such as the log file search device 100 described in the first embodiment. The log file search method 300 filters out log file search results through steps S310 to S340.
[0081] In step S310 , a plurality of operation log files are received by the electronic device, wherein each operation log file corresponds to an event occurring in the operating system, and each operation log file corresponds to a plurality of log file categories of the operating system.
[0082] Next, in step S320 , the electronic device extracts target search conditions based on the input information.
[0083] Next, in step S330 , the electronic device filters a plurality of target log files from the plurality of operation log files based on the target search condition.
[0084] Finally, in step S340 , the electronic device filters out log file search results from the multiple target log files based on the log file category corresponding to each target log file.
[0085] In some embodiments, each of the at least one search conditions is in a Boolean search expression format, and the step of filtering multiple target log files from the multiple running log files further includes the following steps: in response to the multiple target log files having at least one matching log file that meets the at least one search condition, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval results include the multiple target log files.
[0086] In some embodiments, the input information also includes a time interval, and the step of filtering multiple target log files from the multiple operation log files also includes the following steps: based on the at least one target retrieval condition and the time interval, filtering out the multiple target log files from the multiple operation log files, wherein the multiple target log files correspond to the time interval.
[0087] In some embodiments, each of the at least one target retrieval conditions corresponds to at least one target keyword, each of the at least one target keyword is in a regular expression format, and the step of screening multiple target log files from the multiple operation log files further includes the following steps: comparing each of the at least one target keyword with the multiple operation log files to determine whether the multiple operation log files have at least one matching log file that meets the at least one target keyword; and in response to the multiple operation log files having at least one matching log file that meets the at least one target keyword, adding the at least one matching log file to the multiple target log files.
[0088] In some embodiments, the input information also includes a specified log file category, and the step of filtering out a log file retrieval result from the multiple target log files further includes the following steps: in response to the multiple target log files having at least one matching log file corresponding to the specified log file category, adding the at least one matching log file to the multiple target log files, wherein the log file retrieval result includes the multiple target log files.
[0089] In some embodiments, the multiple target log file categories correspond to a priority order, and the step of filtering out a log file retrieval result from the multiple target log files further includes the following steps: based on the multiple target log file categories corresponding to the multiple target log files, the multiple target log files are arranged according to the priority order, wherein the log file retrieval result includes the multiple target log files arranged in order.
[0090] In some embodiments, the target log files are arranged in the priority order based on the target log file categories corresponding to the target log files, wherein the log file search result includes the target log files arranged in order.
[0091] The log file retrieval method described in the second embodiment can be implemented by a computer program having multiple instructions. Each computer program can be a file that can be transmitted over a network, or can be stored in a non-transitory computer-readable storage medium. For each computer program, after the multiple instructions contained therein are loaded into an electronic device (e.g., the log file retrieval device 100), the computer program executes the tracking method described in the second embodiment. The non-transitory computer-readable storage medium can be an electronic product, such as a read-only memory (ROM), a flash memory, a floppy disk, a hard disk, a compact disk (CD), a USB flash drive, a database accessible via a network, or any other storage medium known to those skilled in the art and having the same function.
[0092] In summary, according to the multiple embodiments of the present disclosure, users can more quickly view the content they are concerned about, thereby reducing the time spent on debugging and achieving the technical effect of improving development efficiency; at the same time, providing and processing operation log files in a streaming manner can not only achieve real-time filtering, but also effectively reduce the required storage space.
[0093] The above embodiments are only used to illustrate some embodiments of the present disclosure and to illustrate the technical features of the present disclosure, and are not intended to limit the scope of protection and scope of the present disclosure. Any changes or equivalent arrangements that can be easily completed by those skilled in the art of the present disclosure are within the scope claimed by the present disclosure, and the scope of protection of the present disclosure is subject to the claims.
Claims
1. A log file retrieval device, characterized in that: Include: A communication interface: and A processor, electrically connected to the communication interface, configured to execute the following operations: receiving a plurality of operation log files, wherein the plurality of operation log files correspond to a plurality of events occurring in an operating system, and each of the plurality of operation log files corresponds to a plurality of log file categories of the operating system; Extracting at least one target search condition based on input information; Based on the at least one target search condition, screening a plurality of target log files from the plurality of operation log files; as well as A log file search result is filtered out from the plurality of target log files based on the plurality of log file categories corresponding to the plurality of target log files.
2. The log file retrieval device according to claim 1, wherein: Each of the at least one target search conditions is in a Boolean search expression format, and the operation of filtering a plurality of target log files from the plurality of operation log files further includes the following operation: In response to the plurality of target log files having at least one matching log file that meets the at least one target search condition, the at least one matching log file is added to the plurality of target log files, wherein the log file search result includes the plurality of target log files.
3. The log file retrieval device according to claim 1, wherein: The input information further includes a time interval, and the operation of filtering multiple target log files from the multiple operation log files further includes the following operation: Based on the at least one target search condition and the time interval, the target log files are screened out from the operation log files, wherein the target log files correspond to the time interval.
4. The log file retrieval device according to claim 1, wherein: Each of the at least one target search conditions corresponds to at least one target keyword, each of the at least one target keyword is in a regular expression format, and the operation of filtering a plurality of target log files from the plurality of operation log files further includes the following operation: comparing each of the at least one target keyword with the plurality of operation log files to determine whether the plurality of operation log files has at least one matching log file that matches the at least one target keyword; as well as In response to the plurality of operation log files having at least one matching log file that matches the at least one target keyword, the at least one matching log file is added to the plurality of target log files.
5. The log file retrieval device according to claim 1, wherein: The input information further includes a specified log file category, and the operation of filtering a log file search result from the plurality of target log files further includes the following operation: In response to the plurality of target log files having at least one matching log file corresponding to the specified log file category, the at least one matching log file is added to the plurality of target log files, wherein the log file search result includes the plurality of target log files.
6. The log file retrieval device according to claim 1, wherein: The plurality of target log file categories correspond to a priority order, and the operation of filtering out a log file search result from the plurality of target log files further includes the following operation: Based on a plurality of target log file categories corresponding to the plurality of target log files, the plurality of target log files are arranged in the priority order, wherein the log file search result includes the plurality of target log files arranged in order.
7. The log file retrieval device according to claim 1, wherein: The communication interface is communicatively connected to a display and an input interface. The display is used to display a user interface, and the input interface is used to allow the user to input the input information.
8. A log file retrieval method, applicable to an electronic device, characterized in that: The log file retrieval method includes the following steps: receiving a plurality of operation log files, wherein the plurality of operation log files correspond to a plurality of events occurring in an operating system, and each of the plurality of operation log files corresponds to a plurality of log file categories of the operating system; Extracting at least one target search condition based on input information; Based on the at least one target search condition, screening a plurality of target log files from the plurality of operation log files; as well as A log file search result is filtered out from the plurality of target log files based on the plurality of log file categories corresponding to the plurality of target log files.
9. The log file retrieval method according to claim 8, wherein: Each of the at least one target search conditions is in a Boolean search format, and the step of selecting a plurality of target log files from the plurality of operation log files further includes the following steps: In response to the plurality of target log files having at least one matching log file that meets the at least one target search condition, the at least one matching log file is added to the plurality of target log files, wherein the log file search result includes the plurality of target log files.
10. The log file retrieval method according to claim 8, wherein: The input information further includes a time interval, and the step of filtering a plurality of target log files from the plurality of operation log files further includes the following steps: Based on the at least one target search condition and the time interval, the target log files are screened out from the operation log files, wherein the target log files correspond to the time interval.
11. The log file retrieval method according to claim 8, wherein: Each of the at least one target search conditions corresponds to at least one target keyword, each of the at least one target keyword is in a regular expression format, and the step of filtering a plurality of target log files from the plurality of operation log files further includes the following steps: comparing each of the at least one target keyword with the plurality of operation log files to determine whether the plurality of operation log files has at least one matching log file that matches the at least one target keyword; as well as In response to the plurality of operation log files having at least one matching log file that matches the at least one target keyword, the at least one matching log file is added to the plurality of target log files.
12. The log file retrieval method according to claim 8, wherein: The input information further includes a specified log file category, and the step of filtering out a log file search result from the plurality of target log files further includes the following steps: In response to the plurality of target log files having at least one matching log file corresponding to the specified log file category, the at least one matching log file is added to the plurality of target log files, wherein the log file search result includes the plurality of target log files.
13. The log file retrieval method according to claim 8, wherein: The plurality of target log file categories correspond to a priority order, and the step of filtering out a log file search result from the plurality of target log files further includes the following steps: Based on a plurality of target log file categories corresponding to the plurality of target log files, the plurality of target log files are arranged in the priority order, wherein the log file search result includes the plurality of target log files arranged in order.
14. The log file retrieval method according to claim 8, wherein: A communication interface is communicatively connected to a display and an input interface. The display is used to display a user interface, and the input interface is used to allow the user to input the input information.
15. A non-transitory computer-readable storage medium, characterized in that: A computer program is used to store a plurality of program instructions. The computer program executes a method for retrieving log files after being loaded into a log file retrieval device. The log file retrieval device includes a communication interface and a processor. The method includes the following steps: receiving a plurality of operation log files, wherein the plurality of operation log files correspond to a plurality of events occurring in an operating system, and each of the plurality of operation log files corresponds to a plurality of log file categories of the operating system; Extracting at least one target search condition based on input information; Based on the at least one target search condition, screening a plurality of target log files from the plurality of operation log files; as well as A log file search result is filtered out from the plurality of target log files based on the plurality of log file categories corresponding to the plurality of target log files.
16. The non-transitory computer-readable storage medium of claim 15, wherein: Each of the at least one target search conditions is in a Boolean search format, and the step of selecting a plurality of target log files from the plurality of operation log files further includes the following steps: In response to the plurality of target log files having at least one matching log file that meets the at least one target search condition, the at least one matching log file is added to the plurality of target log files, wherein the log file search result includes the plurality of target log files.
17. The non-transitory computer-readable storage medium of claim 15, wherein: The input information further includes a time interval, and the step of filtering a plurality of target log files from the plurality of operation log files further includes the following steps: Based on the at least one target search condition and the time interval, the target log files are screened out from the operation log files, wherein the target log files correspond to the time interval.
18. The non-transitory computer-readable storage medium of claim 15, wherein: Each of the at least one target search conditions corresponds to at least one target keyword, each of the at least one target keyword is in a regular expression format, and the step of filtering a plurality of target log files from the plurality of operation log files further includes the following steps: comparing each of the at least one target keyword with the plurality of operation log files to determine whether the plurality of operation log files has at least one matching log file that matches the at least one target keyword; as well as In response to the plurality of operation log files having at least one matching log file that matches the at least one target keyword, the at least one matching log file is added to the plurality of target log files.
19. The non-transitory computer-readable storage medium of claim 15, wherein: The input information further includes a specified log file category, and the step of filtering out a log file search result from the plurality of target log files further includes the following steps: In response to the plurality of target log files having at least one matching log file corresponding to the specified log file category, the at least one matching log file is added to the plurality of target log files, wherein the log file search result includes the plurality of target log files.
20. The non-transitory computer-readable storage medium of claim 15, wherein: The plurality of target log file categories correspond to a priority order, and the step of filtering out a log file search result from the plurality of target log files further includes the following steps: Based on a plurality of target log file categories corresponding to the plurality of target log files, the plurality of target log files are arranged in the priority order, wherein the log file search result includes the plurality of target log files arranged in order.