(4) 新建yum配置档centos6.repo
[iyunv@sam pub]# touch centos6.repo
在centos6.repo中添加:
name = This is my repo
baseurl = ftp://192.168.159.129/pub/
gpgcheck=0
enabled=1
客户端
(1) 保证网络是可以互通的
[iyunv@sam yum.repos.d]# ping 192.168.159.129
PING 192.168.159.129 (192.168.159.129) 56(84) bytes of data.
64 bytes from 192.168.159.129: icmp_seq=1 ttl=64 time=18.3 ms
64 bytes from 192.168.159.129: icmp_seq=2 ttl=64 time=0.269 ms
64 bytes from 192.168.159.129: icmp_seq=3 ttl=64 time=0.232 ms
64 bytes from 192.168.159.129: icmp_seq=4 ttl=64 time=0.228 ms
64 bytes from 192.168.159.129: icmp_seq=5 ttl=64 time=0.257 ms
--- 192.168.159.129 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4313ms
rtt min/avg/max/mdev = 0.228/3.870/18.364/7.247 ms
Total download size: 149 k
Installed size: 331 k
Is this ok [y/N]: y
Downloading Packages:
vsftpd-2.2.2-6.el6.x86_64.rpm | 149 kB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : vsftpd-2.2.2-6.el6.x86_64 1/1