在国产在线视频a在线视频,国产欧美一区二区三区网站,国内精产品一二二三的区别,国产日韩精品91

    <s id="gmbiu"></s>

        <sup id="gmbiu"><thead id="gmbiu"><input id="gmbiu"></input></thead></sup>
        <strike id="gmbiu"></strike>

        管理員登陸

        安全傳輸文件:SCP命令用法示例

        1、拷貝本地的檔案到遠(yuǎn)程的機(jī)器上

        1. scp /etc/lilo.conf k@net67.ee.oit.edu.tw:/home/k

        會將本地的 /etc/lilo.conf 這個檔案拷貝到 net67.ee.oit.edu.tw,使用者 k 的家目錄下。

        2、拷貝遠(yuǎn)程機(jī)器上的檔案到本地來

        1. scp k@net67.ee.oit.edu.tw:/etc/lilo.conf /etc

        會將 net67.ee.oitdu.tw 中 /etc/lilo.conf 檔案 copy 到本地的 /etc 目錄下。

        3、保持從來源 host 檔案的屬性

        1. scp –p k@net67.ee.tw:/etc/lilo.conf /etc

        4、如果想使用特定端口 使用 scp –P(大寫) 如

        1. scp –P 1234 k@net67.ee.tw:/etc/lilo.conf /etc

        5、免密碼拷貝

        必須注意使用者的權(quán)限是否可讀取遠(yuǎn)程上的檔案,若想知道更多關(guān)于 scp 的使用方法,可去看看 scp 的使用手冊。

        1. ssh-keygen

        產(chǎn)生公開鑰 (pulib key) 和私人鑰 (private key),以保障 ssh 聯(lián)機(jī)的安性, 當(dāng) ssh 連 shd 服務(wù)器,會交換公開鑰上,系統(tǒng)會檢查 /etc/ssh_know_hosts 內(nèi)儲存的 key,如果找到客戶端就用這個 key 產(chǎn)生一個隨機(jī)產(chǎn)生的session key 傳給服務(wù)器,兩端都用這個 key 來繼續(xù)完成 ssh 剩下來的階段。

        它會產(chǎn)生 identity.pub、identity 兩個檔案,私人鑰存放于identity,公開鑰 存放于 identity.pub 中,接下來使用 scp 將 identity.pub copy 到遠(yuǎn)程機(jī)器的家目錄下.ssh下的authorized_keys。 .ssh/authorized_keys(這個 authorized_keys 檔案相當(dāng)于協(xié)議的 rhosts 檔案), 之后使用者能夠不用密碼去登入。RSA的認(rèn)證絕對是比 rhosts 認(rèn)證更來的安全可靠。執(zhí)行:

        1. scp identity.pub k@linux1.ee.oit.edu.tw:.ssh/authorized_keys

        若在使用 ssh-keygen 產(chǎn)生鑰匙對時沒有輸入密碼,則如上所示不需輸入密碼即可從 net67.ee.oit.edu.tw 去登入 linux1.ee.oit.edu.tw。在此,這里輸入的密碼可以跟帳號的密碼不同,也可以不輸入密碼。

        信息科技 2012-07-16 16:27:38 通過 網(wǎng)頁 瀏覽(2743) 打印

        下一篇

        共有0條評論!

        發(fā)表評論