精品丰满熟女一区二区三区_五月天亚洲欧美综合网_亚洲青青青在线观看_国产一区二区精选

  • <menu id="29e66"></menu>

    <bdo id="29e66"><mark id="29e66"><legend id="29e66"></legend></mark></bdo>

  • <pre id="29e66"><tt id="29e66"><rt id="29e66"></rt></tt></pre>

      <label id="29e66"></label><address id="29e66"><mark id="29e66"><strike id="29e66"></strike></mark></address>
      學(xué)習(xí)啦>學(xué)習(xí)電腦>操作系統(tǒng)>Linux教程>

      linux記錄操作命令

      時(shí)間: 佳洲1085 分享

        在linux終端下,為方便檢查操作中可能出現(xiàn)的錯(cuò)誤,我們可以把操作日志記錄下來。那么我們應(yīng)該使用那條命令才能記錄操作呢?下面由學(xué)習(xí)啦小編為大家整理了linux記錄操作命令的相關(guān)知識(shí),希望大家喜歡!

        linux記錄操作命令1. screen — screen manager with VT100/ANSI terminal emulatio

        > screen -L

        >這里是我們的操作

        > exit

        結(jié)束后會(huì)生成一個(gè)類似這樣的文件名: screenlog.0

        > more screenlog.0

        這樣可以查看你剛才進(jìn)行的操作,發(fā)現(xiàn)可能存在的問題

        linux記錄操作命令2. script — make typescript of terminal session

        > script

        >我們的操作

        > exit

        生成一個(gè)這樣的文件:typescript

        > more typescript

        這里查看我們進(jìn)行的操作

        linux記錄操作命令3. tee – read from standard input and write to standard output and files

        這個(gè)命令可以讀取終端輸入輸出到終端或者文件中,有時(shí)候可以用來記錄make等命令可能產(chǎn)生的輸出到終端的大量?jī)?nèi)容輸出到文件中去。這樣可以方便記錄這些命令的日志。

        > make 2>&1 | tee make.log

        當(dāng)然,我們也可以直接重定向到一個(gè)文件中

        > make > make.log

        PS: 2>&1是為了記錄錯(cuò)誤日志

        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

      3599525