Local Repository 만들기

설치 dvd 다운로드
https://rhn.redhat.com/rhn/software/downloads/SupportedISOs.do
mount 할 폴더 생성
mkdir -p /root/iso
iso 를 mount 한다.
mount -o loop rhel-server-6.3-x86_64-dvd.iso /root/iso
repository 정보를 설정한다
vi /etc/yum.repos.d/local.repo
다음 repository 설정을 넣는다.
[local-repo]
name=Local Repository
baseurl=file:///root/iso/Server
enabled=1
gpgcheck=0

Web Server에 만들고 URL로 repository 에 등록하기
Repository 를 제공할 서버의 IP 는 192.168.10.10 이라 가정

192.168.10.10 에 ssh 로 연결
CentOS 및 RHEL 설치 dvd 다운로드(CDNetworks 에서 CentOS 6.4 64Bit 다운로드 하기)
mount 할 폴더를 만든다
mkdir -p /var/www/html/repos/centos/iso
mkdir -p /var/www/html/repos/rhel/iso
iso 를 mount 한다
mount -o loop rhel-server-6.3-x86_64-dvd.iso /var/www/html/repos/rhel/iso
mount -o loop CentOS-6.4-x86_64-bin-DVD1.iso /var/www/html/repos/centos/iso/
yum repository 를 생성할 수 있는 패키지를 설치한다.

yum install createrepo -y
repository index를 생성한다. (시간이 꽤 많이 걸림)
cd /var/www/html/repos/rhel
createrepo .
cd /var/www/html/repos/centos
createrepo .
repository 를 사용할 client 에 연결한다.
repository 정보를 설정한다
vi /etc/yum.repos.d/centos-internal.repo
다음 repository 설정을 넣는다.
[internal-repo]
name=Internal Repository
baseurl=http://192.168.10.10/repos/centos/iso
enabled=1
gpgcheck=0

https://www.lesstif.com/pages/viewpage.action?pageId=7634963 에서 가져옴

댓글 남기기

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Videos, Slideshows and Podcasts by Cincopa Wordpress Plugin