亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

Ubuntu下安裝rsh實(shí)現(xiàn)無(wú)密碼訪問(wèn)詳解

 更新時(shí)間:2017年03月31日 09:11:54   作者:翟海飛  
這篇文章主要為大家詳細(xì)介紹了Ubuntu下安裝rsh實(shí)現(xiàn)無(wú)密碼訪問(wèn)的相關(guān)資料,具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下

一、環(huán)境

1.三臺(tái)服務(wù)器ubuntu14.04, 主機(jī)名分別為compute,block1和blcok2

2.兩臺(tái)主機(jī)hosts文件都為:
root@compute:~# cat /etc/hosts
127.0.0.1 localhost
192.168.4.132 compute
192.168.4.133 block1
192.168.4.134 block2

二、安裝rsh和rsh-server(三臺(tái)主機(jī)都安裝),并設(shè)置啟動(dòng)rsh和rlogin服務(wù)

1 安裝

apt-get install rsh-client rsh-server xinetd 

2 ubuntu下原來(lái)沒(méi)有/etc/xinetd.d/rsh文件,新建并添加內(nèi)容

# default: on 
# descrīption: The rshd server is the server for the rcmd(3) routine and, \ 
#    consequently, for the rsh(1) program. The server provides \ 
#    remote execution facilities with authentication based on \ 
#    privileged port numbers from trusted hosts. 
service shell 
{ 
    disable = no 
    socket_type       = stream 
    wait          = no 
    user          = root 
    log_on_success     += USERID 
    log_on_failure     += USERID 
    server         = /usr/sbin/in.rshd 
} 
 
/etc/xinetd.d/rlogin 
 
# default: on 
# descrīption: rlogind is the server for the rlogin(1) program. The server \ 
#    provides a remote login facility with authentication based on \ 
#    privileged port numbers from trusted hosts. 
service login 
{ 
    disable = no 
    socket_type       = stream 
    wait          = no 
    user          = root 
    log_on_success     += USERID 
    log_on_failure     += USERID 
    server         = /usr/sbin/in.rlogind 
} 
 
/etc/xinetd.d/rexec 
 
# default: off 
# descrīption: Rexecd is the server for the rexec(3) routine. The server \ 
#    provides remote execution facilities with authentication based \ 
#    on user names and passwords. 
service exec 
{ 
    disable = no 
    socket_type       = stream 
    wait          = no 
    user          = root 
    log_on_success     += USERID 
    log_on_failure     += USERID 
    server         = /usr/sbin/in.rexecd 
} 

3 重啟動(dòng)

root@block2:~# /etc/init.d/xinetd restart 
xinetd stop/waiting 
xinetd start/running, process 26181 

三、建立信任文件,實(shí)現(xiàn)無(wú)密碼訪問(wèn)配置

1.在root主目錄下建立.rhosts文件,并在此文件內(nèi)寫入這兩臺(tái)主機(jī)的主機(jī)名

root@block1:~# cat .rhosts  
compute root 
block1 root 
block2 root 

注:root 驗(yàn)證需要/root/.rhosts文件,普通用戶需要/etc/hosts.equiv文件

2.在/etc目錄下建立hosts.equiv文件,并在此文件內(nèi)寫入作為客戶端主機(jī)的主機(jī)名

root@block1:~# cat /etc/hosts.equiv  
# /etc/hosts.equiv: list of hosts and users that are granted "trusted" r 
#      command access to your system . 
compute 

3 在文件/etc/securetty中

加入rsh rlogin rexec

四、配置完畢,驗(yàn)證配置

1.在compute服務(wù)器上直接輸入rsh block1 date就可以在block1上無(wú)密碼執(zhí)行date命令

root@compute:~# rsh block2 date 
Thu Mar 30 16:38:42 CST 2017 

2.在compute上直接輸入rsh block1就可以無(wú)密碼登錄block1
3.普通用戶操作同root用戶
4.還有rcp命令可以遠(yuǎn)程復(fù)制文件
至此rsh無(wú)密碼訪問(wèn)配置完畢。

以上就是本文的全部?jī)?nèi)容,希望對(duì)大家的學(xué)習(xí)有所幫助,也希望大家多多支持腳本之家。

相關(guān)文章

  • Centos5給/根分區(qū)擴(kuò)容

    Centos5給/根分區(qū)擴(kuò)容

    今天在調(diào)整VPS的時(shí)候發(fā)現(xiàn)自己的/分區(qū)的空間用光了.但是還剩下一個(gè)分區(qū)hda3沒(méi)動(dòng).于是乎.想調(diào)整到根下面去.但是由于本人新手一個(gè).又不太了解linux的分區(qū)機(jī)制.
    2010-06-06
  • 圖解VMWare安裝Centos 7.3教程

    圖解VMWare安裝Centos 7.3教程

    這篇文章主要為大家詳細(xì)介紹了基于vmware workstations安裝Centos 7.3的圖文教程,具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下
    2018-09-09
  • Linux deepin 刪除多余內(nèi)核的實(shí)現(xiàn)方法

    Linux deepin 刪除多余內(nèi)核的實(shí)現(xiàn)方法

    這篇文章主要介紹了Linux deepin 刪除多余內(nèi)核的實(shí)現(xiàn)方法,文中通過(guò)示例代碼介紹的非常詳細(xì),對(duì)大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來(lái)一起學(xué)習(xí)學(xué)習(xí)吧
    2019-12-12
  • Linux常用硬盤管理相關(guān)命令介紹

    Linux常用硬盤管理相關(guān)命令介紹

    大家好,本篇文章主要講的是Linux常用硬盤管理相關(guān)命令介紹,感興趣的同學(xué)趕快來(lái)看一看吧,對(duì)你有幫助的話記得收藏一下哦,方便下次瀏覽
    2021-12-12
  • Linux 修改 etc/hosts文件詳細(xì)介紹

    Linux 修改 etc/hosts文件詳細(xì)介紹

    這篇文章主要介紹了 Linux 修改 etc/hosts文件詳細(xì)介紹的相關(guān)資料,需要的朋友可以參考下
    2016-12-12
  • 詳解Linux系統(tǒng)無(wú)法上網(wǎng)解決方案

    詳解Linux系統(tǒng)無(wú)法上網(wǎng)解決方案

    本篇文章主要介紹了詳解Linux系統(tǒng)無(wú)法上網(wǎng)解決方案,小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,也給大家做個(gè)參考。一起跟隨小編過(guò)來(lái)看看吧
    2017-06-06
  • Linux系統(tǒng)之基礎(chǔ)掃盲教程大全

    Linux系統(tǒng)之基礎(chǔ)掃盲教程大全

    本篇文章主要介紹了Linux系統(tǒng)之基礎(chǔ)掃盲大全,介紹了網(wǎng)絡(luò),系統(tǒng),cpu,內(nèi)存,硬盤,進(jìn)程等等常用的基礎(chǔ)信息查看與基礎(chǔ)功能設(shè)置,有興趣的可以了解一下。
    2017-04-04
  • 使用squid搭建http代理的方法

    使用squid搭建http代理的方法

    這篇文章主要介紹了使用squid搭建http代理的方法,需要的朋友可以參考下
    2016-11-11
  • Linux系統(tǒng)網(wǎng)卡設(shè)置教程

    Linux系統(tǒng)網(wǎng)卡設(shè)置教程

    這篇文章主要介紹了Linux系統(tǒng)網(wǎng)卡的設(shè)置教程,具有一定的參考價(jià)值,感興趣的小伙伴們可以參考一下
    2017-06-06
  • 詳解CentOS7安裝配置vsftp搭建FTP

    詳解CentOS7安裝配置vsftp搭建FTP

    這篇文章主要介紹了詳解CentOS7安裝配置vsftp搭建FTP,小編覺(jué)得挺不錯(cuò)的,現(xiàn)在分享給大家,也給大家做個(gè)參考。一起跟隨小編過(guò)來(lái)看看吧
    2017-01-01

最新評(píng)論