如何开启windows系统的操作日志记录?
在linux終端下,為方便檢查操作中可能出現的錯誤,以及避免屏幕滾屏的限制,我們可以把操作日志記錄下來。常用的工具有screen,script,以及tee等。
1。 screen — screen manager with VT100/ANSI terminal emulatio
> screen -L
>這里是我們的操作
> exit
結束后會生成一個類似這樣的文件名: screenlog。
0
> more screenlog。0
這樣可以查看你剛才進行的操作,發現可能存在的問題
2。 script — make typescript of terminal session
> script
>我們的操作
> exit
生成一個這樣的文件:typescript
> more typescript
這里查看我們進行的操作
3。
tee – read from standard input and write to standard output and files
這個命令可以讀取終端輸入輸出到終端或者文件中,有時候可以用來記錄make等命令可能產生的輸出到終端的大量內容輸出到文件中去。
這樣可以方便記錄這些命令的日志。
> make 2>&1 | tee make。log
當然,我們也可以直接重定向到一個文件中
> make > make。log
PS: 2>&1是為了記錄錯誤日志
if you want to filter the control symbols, try to use the “col” command like this:
$ cat screenlog。
0 | col -b > screenlog
or
$ cat typescript | col -b > scriptlog。
總結
以上是生活随笔為你收集整理的如何开启windows系统的操作日志记录?的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 抖音如何配音说话
- 下一篇: Linux下简单的判断目录中是否有新文件