Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Method of saving command line output information to log (valid under ubunut and arm-linux)

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/03 Report--

Use the command script

Type script xxx.log at the command line, generate the xxx.log file in the current directory, and then the output information from the command line will be saved to the xxx.log file. When you want to end the save, enter the exit command under the command line to end the save.

At this time, what is saved in the xxx.log file is the information just generated. You can view the file by cat to make it appropriate.

If you cannot use the script command on an arm-linux system, it may be that your file system does not have a configuration that enables the command at the time of production. The solution is to recompile your file system and select it when make menuconfig. Or find a bin file for the command, which is exported to the system's environment variable.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report