1. 程式人生 > >linux學習筆記-如何使用secureCRT連線虛擬機器中linux

linux學習筆記-如何使用secureCRT連線虛擬機器中linux

1.使用命令:

#vi /etc/sysconfig/network-scripts/ifcfg-eth0 [編輯網絡卡的配置檔案]

2.修改檔案中的以下內容:

BOOTPROTO=static

IPADDR=192.168.100.16 PREFIX=255.255.255.0 GATEWAY=192.168.100.1 ONBOOT=yes DNS1=192.168.1.1//主DNS伺服器IP地址為windows中主機真實閘道器
3.使用命令: #service iptables stop#關閉防火牆(可選) #chkconfig iptables off#設定防火牆不自動開啟(可選) #service network restart
#重啟網路
一般來講,經過以上3步就可以連線上了。 注: 連線錯誤1:The remote system refused the connection. 解決:使用命令:#vi / etc/ssh/sshd_config 找到裡面的 #Port 22 #AddressFamily any #ListenAddress 0.0.0.0 #ListenAddress :: 把前面的註釋去掉,再使用命令:#/etc/init.d/sshd restart 連線錯誤2:Connection Timeout 解決:如果IP等已經設定正確,則使用命令:#service iptables stop

相關推薦

no