====== 43 reposync リポジトリコピー ====== ===== 1.reposync install ===== yum install yum-utils createrepo ===== 2. repository 確認 ===== # yum repolist Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: ty1.mirror.newmediaexpress.com * epel: ftp.iij.ad.jp * extras: ty1.mirror.newmediaexpress.com * updates: ty1.mirror.newmediaexpress.com repo id repo name status !Ceph/x86_64 Ceph packages for x86_64 1,050 !Ceph-noarch Ceph noarch packages 184 !base/7/x86_64 CentOS-7 - Base 10,072 !ceph-source Ceph source packages 0 !epel/x86_64 Extra Packages for Enterprise Linux 7 - x86_64 13,612 !extras/7/x86_64 CentOS-7 - Extras 498 !updates/7/x86_64 CentOS-7 - Updates 2,458 ===== 3. reposync ===== Cephリポジトリを reposync -r Ceph -n -p /var/www/html/repo/ オプション ^オプション^ 意味^ |-r REPOID, --repoid=REPOID| 対象リポジトリ | | -n, --newest-only | 最新分だけ| |-p DESTDIR, --download_path=DESTDIR| ダウンロードディレクトリ| # ls -al Ceph/ total 271720 drwxr-xr-x 3 root root 4096 Jul 5 11:53 . dr-xr-x---. 6 root root 242 Jul 5 11:52 .. -rw-r--r-- 1 root root 3116 Jul 1 02:51 ceph-14.2.22-0.el7.x86_64.rpm -rw-r--r-- 1 root root 5768372 Jul 1 02:53 ceph-base-14.2.22-0.el7.x86_64.rpm -rw-r--r-- 1 root root 19871984 Jul 1 02:52 ceph-common-14.2.22-0.el7.x86_64.rpm -rw-r--r-- 1 root root 166464690 Jul 5 11:52 ceph-debuginfo-14.2.22-0.el7.x86_64.rpm -rw-r--r-- 1 root root 24552 Jul 1 02:51 cephfs-java-14.2.22-0.el7.x86_64.rpm -rw-r--r-- 1 root root 587228 Jul 1 02:51 ceph-fuse-14.2.22-0.el7.x86_64.rpm -rw-r--r-- 1 root root 1992384 Jul 1 02:50 ceph-mds-14.2.22-0.el7.x86_64.rpm ・ ・ ・ ===== 3. repocreate ===== createrepo Ceph ===== 4. yum.repo ===== 下記のように作成したローカルのリポジトリを指定して利用する # cat /etc/yum.repos.d/ceph.repo [Ceph] name=Ceph packages for $basearch baseurl=http://192.168.1.254/repo/Ceph enabled=1 gpgcheck=1 type=rpm-md gpgkey=https://download.ceph.com/keys/release.asc priority=1 {{tag>rpm yum}}