#!/bin/bash #KBytes/s KBPS="10240" syncit() { #a=rlptgoD #rsync -vv --stats --bwlimit "$KBPS" -aHSzP --numeric-ids \ #--delete --delete-after --delete-excluded ... "$SRC" "$DST" rsync -vv --stats --bwlimit "$KBPS" -rlptDHSzP \ --delete --delete-after --delete-excluded "$@" "$SRC" "$DST" chown maze.maze -Rh "$DST" chcon user_u:object_r:httpd_sys_content_t -Rh "$DST" # chcon user_u:object_r:httpd_user_content_t -Rh "$DST" } #rsync://sunsite.icm.edu.pl/pub/Linux/distributions/centos/ #rsync://ftp.pbone.net/pub/centos/ #rsync://rsync.sunsite.org.uk/sites/msync.centos.org/CentOS/ # rsync.sunsite.org.uk::sites/msync.centos.org/CentOS/ #rsync://mirrors.kernel.org/centos/ #SRC="rsync://rsync.sunsite.org.uk/sites/msync.centos.org/CentOS/" #SRC="rsync://mirrors.kernel.org/centos/" #SRC="rsync://mirrors1.kernel.org/centos/" SRC="rsync://mirrors2.kernel.org/centos/" DST="/opt/mirrors/centos" syncit \ --exclude /[23] \ --exclude /[23].[0-9] \ --exclude /RPM-GPG-KEY-CentOS-[23] \ --exclude /4.[012] \ --exclude /[234].[0-9]beta \ --exclude /*/isos/ \ --exclude /4.3/isos-dvd/SRPMS/CentOS-4.3-i386-srcDVD.iso \ --exclude /4.3/isos-dvd/i386/CentOS-4.3-i386-binDVD.iso \ --exclude /4.3/isos-dvd/x86_64/CentOS-4.3-x86_64-binDVD.iso \ --exclude /*/*/alpha/ \ --exclude /*/*/ia64/ \ --exclude /*/*/ppc/ \ --exclude /*/*/s390/ \ --exclude /*/*/s390x/ \ #--exclude /*/*/x86_64/ \ SRC="rsync://dag.freshrpms.net/pub/freshrpms/pub/dag/" DST="/opt/mirrors/dag" syncit \ --exclude /bert/ \ --exclude /dries/aurora/ \ --exclude /dries/fedora/ \ --exclude /dries/redhat/9/ \ --exclude /dries/redhat/el3/ \ --exclude /dries/packages/*/au1.9[12]-sparc/ \ --exclude /dries/packages/*/fc[12345]-i386/ \ --exclude /dries/packages/*/fc[12345]-x86_64/ \ --exclude /dries/packages/*/el[3]-i386/ \ --exclude /dries/packages/*/el[3]-x86_64/ \ --exclude /fedora/ \ --exclude /packages/*/*-*-*.rh[56789].dag.noarch.rpm \ --exclude /packages/*/*-*-*.rh[56789].dag.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rh[56789].dag.x86_64.rpm \ --exclude /packages/*/*-*-*.rh[56789][0123].dag.noarch.rpm \ --exclude /packages/*/*-*-*.rh[56789][0123].dag.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rh[56789][0123].dag.x86_64.rpm \ --exclude /packages/*/*-*-*.dag.rh[56789][0123].noarch.rpm \ --exclude /packages/*/*-*-*.dag.rh[56789][0123].i[3456]86.rpm \ --exclude /packages/*/*-*-*.dag.rh[56789][0123].x86_64.rpm \ --exclude /packages/*/*-*-*.fc[12345].dag.noarch.rpm \ --exclude /packages/*/*-*-*.fc[12345].dag.i[3456]86.rpm \ --exclude /packages/*/*-*-*.fc[12345].dag.x86_64.rpm \ --exclude /packages/*/*-*-*.rhfc[12345].dag.noarch.rpm \ --exclude /packages/*/*-*-*.rhfc[12345].dag.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rhfc[12345].dag.x86_64.rpm \ --exclude /packages/*/*-*-*.el[23].dag.noarch.rpm \ --exclude /packages/*/*-*-*.el[23].dag.i[3456]86.rpm \ --exclude /packages/*/*-*-*.el[23].dag.x86_64.rpm \ --exclude /packages/*/*-*-*.rhel[23].dag.noarch.rpm \ --exclude /packages/*/*-*-*.rhel[23].dag.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rhel[23].dag.x86_64.rpm \ --exclude /packages/*/*-*-*.rhel[23].[0123456789].dag.noarch.rpm \ --exclude /packages/*/*-*-*.rhel[23].[0123456789].dag.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rhel[23].[0123456789].dag.x86_64.rpm \ --exclude /packages/*/*-*-*.rh[56789].rf.noarch.rpm \ --exclude /packages/*/*-*-*.rh[56789].rf.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rh[56789].rf.x86_64.rpm \ --exclude /packages/*/*-*-*.rh[56789][0123].rf.noarch.rpm \ --exclude /packages/*/*-*-*.rh[56789][0123].rf.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rh[56789][0123].rf.x86_64.rpm \ --exclude /packages/*/*-*-*.rf.rh[56789][0123].noarch.rpm \ --exclude /packages/*/*-*-*.rf.rh[56789][0123].i[3456]86.rpm \ --exclude /packages/*/*-*-*.rf.rh[56789][0123].x86_64.rpm \ --exclude /packages/*/*-*-*.fc[12345].rf.noarch.rpm \ --exclude /packages/*/*-*-*.fc[12345].rf.i[3456]86.rpm \ --exclude /packages/*/*-*-*.fc[12345].rf.x86_64.rpm \ --exclude /packages/*/*-*-*.rhfc[12345].rf.noarch.rpm \ --exclude /packages/*/*-*-*.rhfc[12345].rf.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rhfc[12345].rf.x86_64.rpm \ --exclude /packages/*/*-*-*.el[23].rf.noarch.rpm \ --exclude /packages/*/*-*-*.el[23].rf.i[3456]86.rpm \ --exclude /packages/*/*-*-*.el[23].rf.x86_64.rpm \ --exclude /packages/*/*-*-*.rhel[23].rf.noarch.rpm \ --exclude /packages/*/*-*-*.rhel[23].rf.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rhel[23].rf.x86_64.rpm \ --exclude /packages/*/*-*-*.rhel[23].[0123456789].rf.noarch.rpm \ --exclude /packages/*/*-*-*.rhel[23].[0123456789].rf.i[3456]86.rpm \ --exclude /packages/*/*-*-*.rhel[23].[0123456789].rf.x86_64.rpm \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789].dag.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789].dag.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789].dag.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789][0123].dag.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789][0123].dag.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789][0123].dag.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.dag.rh[56789][0123].noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.dag.rh[56789][0123].i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.dag.rh[56789][0123].x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.fc[12345].dag.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.fc[12345].dag.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.fc[12345].dag.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhfc[12345].dag.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhfc[12345].dag.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhfc[12345].dag.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.el[23].dag.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.el[23].dag.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.el[23].dag.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].dag.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].dag.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].dag.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].[0123456789].dag.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].[0123456789].dag.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].[0123456789].dag.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789].rf.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789].rf.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789].rf.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789][0123].rf.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789][0123].rf.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rh[56789][0123].rf.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.dag.rh[56789][0123].noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.dag.rh[56789][0123].i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.dag.rh[56789][0123].x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.fc[12345].rf.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.fc[12345].rf.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.fc[12345].rf.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhfc[12345].rf.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhfc[12345].rf.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhfc[12345].rf.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.el[23].rf.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.el[23].rf.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.el[23].rf.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].rf.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].rf.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].rf.x86_64.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].[0123456789].rf.noarch.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].[0123456789].rf.i[3456]86.log.gz \ --exclude /packages/*/_buildlogs/*-*-*.rhel[23].[0123456789].rf.x86_64.log.gz \ --exclude /redhat/[45678].[0123]/ \ --exclude /redhat/9/ \ --exclude /redhat/el2.1/ \ --exclude /redhat/el3/ \ #--exclude /redhat/el4/en/x86_64/ \ ln -s i386 dries/redhat/el4/en/x86_64 #end #--exclude /packages/ \ #--exclude /rpmforge/ \ #--exclude /source/ \ exit #/packages/package-name/package-name-version-subversion.dag/rf.src.rpm #/packages/package-name/package-name-version-subversion.build.os.dag/rf.arch.rpm #/packages/package-name/package-name.spec #/packages/package-name/_buildlogs/package-name-version-subversion.build.os.dag/rf.arch.log.gz