<div dir="ltr"><div class="gmail_default"><font face="georgia, serif">Here is what I use to sync CentOS and others (be sure to change your source for syncing from </font><span style="font-family:monospace,monospace">SRC_GATECH</span><font face="georgia, serif"> to something else</font><span style="font-family:monospace,monospace">)</span><font face="georgia, serif">:</font></div><div class="gmail_default" style="font-family:georgia,serif"><br></div><div class="gmail_default" style=""><div class="gmail_default" style=""><font face="monospace, monospace">#!/bin/bash</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace">lockfile="/var/lock/subsys/sync-repos/rsync_updates"</font></div><div class="gmail_default" style=""><font face="monospace, monospace">if [ -f ${lockfile} ]; then</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "Updates via rsync already running."</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "Unable to start new repo sync, one is already running."</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>exit 0</font></div><div class="gmail_default" style=""><font face="monospace, monospace">fi</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"># Global Vars</font></div><div class="gmail_default" style=""><font face="monospace, monospace">RSYNC="`which rsync`"</font></div><div class="gmail_default" style=""><font face="monospace, monospace">OPTS="--delay-updates --delete-delay --devices --hard-links --links --partial --perms --progress --recursive --sparse --specials --timeout=600 --times"</font></div><div class="gmail_default" style=""><font face="monospace, monospace">DST="/storage/www/repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"># private mirror</font></div><div class="gmail_default" style=""><font face="monospace, monospace">SRC_GATECH="rsync://<a href="http://mirror.gtlib.gatech.edu">mirror.gtlib.gatech.edu</a>"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"># Where to grab Gentoo Portage tree from</font></div><div class="gmail_default" style=""><font face="monospace, monospace">SRC_PORTAGE="rsync://<a href="http://rsync.us.gentoo.org/gentoo-portage">rsync.us.gentoo.org/gentoo-portage</a>"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"># run normal or verbose</font></div><div class="gmail_default" style=""><font face="monospace, monospace">if [ "$1" != "-v" ]; then</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>OPTS="$OPTS --quiet"</font></div><div class="gmail_default" style=""><font face="monospace, monospace">fi</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace">if [ -d ${DST}/ ] ; then</font></div><div class="gmail_default" style=""><span class="" style="white-space:pre"><font face="monospace, monospace"> </font></span></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Note that we are doing an update right now</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>touch ${lockfile}</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><span class="" style="white-space:pre"><font face="monospace, monospace"> </font></span></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># CentOS Repos</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of CentOS repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${SRC_GATECH}/centos/ ${DST}/CentOS/</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># EPEL Repos</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of EPEL repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>FEDORA_OPTS="--hard-links --numeric-ids"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${FEDORA_OPTS} ${SRC_GATECH}/fedora-epel/ ${DST}/Fedora-EPEL/</font></div><div class="gmail_default" style=""><span class="" style="white-space:pre"><font face="monospace, monospace"> </font></span></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Update Fedora Mirror Manager</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Notifying Mirror Manager of updates"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>/usr/bin/report_mirror</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># ELRepo</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of ELRepo repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} rsync://<a href="http://elrepo.reloumirrors.net/elrepo">elrepo.reloumirrors.net/elrepo</a> ${DST}/ELRepo/</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Fedora</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>#MSG="Starting sync of Fedora repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"> #echo "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"> #logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>#FEDORA_OPTS="--numeric-ids"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"> #${RSYNC} ${OPTS} ${FEDORA_OPTS} ${SRC_GATECH}/fedora-enchilada ${DST}/Fedora/</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Gentoo</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of Gentoo repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>GENTOO_OPTS="--exclude=/releases/historical"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${GENTOO_OPTS} ${SRC_GATECH}/gentoo ${DST}/Gentoo</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Gentoo Portage</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of Gentoo Portage Tree"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${SRC_PORTAGE} ${DST}/gentoo-portage</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Linux Mint</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of Linux Mint repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} rsync://<a href="http://rsync-packages.linuxmint.com/packages">rsync-packages.linuxmint.com/packages</a> ${DST}/LinuxMint/packages</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># OpenCSW setup as suggested at <a href="http://www.opencsw.org/get-it/mirrors/">http://www.opencsw.org/get-it/mirrors/</a></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of OpenCSW packages"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>OPENCSW_OPTS="--hard-links"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${OPENCSW_OPTS} rsync://<a href="http://rsync.opencsw.org/opencsw/">rsync.opencsw.org/opencsw/</a> ${DST}/OpenCSW</font></div><div class="gmail_default" style=""><span class="" style="white-space:pre"><font face="monospace, monospace"> </font></span></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># RPMforge</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of RPMforge repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${SRC_GATECH}/RPMforge/* ${DST}/RPMforge/</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Puppet Labs</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of Puppet Labs repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} rsync://<a href="http://yum.puppetlabs.com/packages/*">yum.puppetlabs.com/packages/*</a> ${DST}/PuppetLabs/</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Ubuntu</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of Ubuntu releases repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${SRC_GATECH}/ubuntu-releases/* ${DST}/Ubuntu/releases/</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Starting sync of Ubuntu archive repos"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>${RSYNC} ${OPTS} ${SRC_GATECH}/ubuntu/* ${DST}/Ubuntu/archive/</font></div><div class="gmail_default" style=""><span class="" style="white-space:pre"><font face="monospace, monospace"> </font></span></div><div class="gmail_default" style=""><font face="monospace, monospace"><br></font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span># Cleanup</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>MSG="Syncing of repos complete"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "${MSG}" </font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "${MSG}"</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>/bin/rm -f ${lockfile}</font></div><div class="gmail_default" style=""><font face="monospace, monospace">else</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>echo "Target directory ${DST}/ is not present."</font></div><div class="gmail_default" style=""><font face="monospace, monospace"><span class="" style="white-space:pre"> </span>logger -t rsync "Unable to sync repos, ${DST}/ is not present."</font></div><div class="gmail_default" style=""><font face="monospace, monospace">fi</font></div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><br></div><div><br></div><div><br></div><div><br></div><div><span style="font-family:arial,helvetica,sans-serif">--</span></div><div style="color:rgb(51,102,255);font-family:tahoma,sans-serif"><font size="4"><b>Gene Liverman</b></font></div><div style="font-family:tahoma,sans-serif">Systems Integration Architect</div><div style="font-family:tahoma,sans-serif">Information Technology Services</div><div style="font-family:tahoma,sans-serif">University of West Georgia</div><div style="font-family:tahoma,sans-serif"><a href="mailto:gliverma@westga.edu" target="_blank">gliverma@westga.edu</a></div><div style="font-family:tahoma,sans-serif"><br></div><div style="font-family:tahoma,sans-serif">ITS: Making Technology Work for You!</div><div style="font-family:tahoma,sans-serif"><br><br></div></div></div></div></div></div>
<br><div class="gmail_quote">On Mon, Mar 28, 2016 at 6:33 AM, Ben .T.George <span dir="ltr"><<a href="mailto:bentech4you@gmail.com" target="_blank">bentech4you@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">HI <div><br></div><div>thanks for the reply,</div><div><br></div><div>"<span style="color:rgb(0,0,0);font-family:'DejaVu Sans','Liberation Sans',sans-serif;font-size:13.6px;line-height:20.4px">We highly recommend the use of lock files in your cron script so that you don't spawn multiple connections which is hard on our servers and on your mirror."</span></div><div><span style="color:rgb(0,0,0);font-family:'DejaVu Sans','Liberation Sans',sans-serif;font-size:13.6px;line-height:20.4px"><br></span></div><div><span style="color:rgb(0,0,0);font-family:'DejaVu Sans','Liberation Sans',sans-serif;font-size:13.6px;line-height:20.4px">can anyone send me sample script?</span></div><div><span style="color:rgb(0,0,0);font-family:'DejaVu Sans','Liberation Sans',sans-serif;font-size:13.6px;line-height:20.4px"><br></span></div><div><span style="color:rgb(0,0,0);font-family:'DejaVu Sans','Liberation Sans',sans-serif;font-size:13.6px;line-height:20.4px">Regards,</span></div><div><span style="color:rgb(0,0,0);font-family:'DejaVu Sans','Liberation Sans',sans-serif;font-size:13.6px;line-height:20.4px">Ben</span></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Mar 23, 2016 at 9:21 AM, Andrew Yong <span dir="ltr"><<a href="mailto:me@ndoo.sg" target="_blank">me@ndoo.sg</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span><p dir="ltr"><br>
On Mar 23, 2016 14:20, "Ben .T.George" <<a href="mailto:bentech4you@gmail.com" target="_blank">bentech4you@gmail.com</a>> wrote:<br>
><br>
> HI List,<br>
><br>
> i am very new to this and we are interested in setting up country mirror from kuwait location . please anyone let me know is there any existing mirror from kuwait </p>
</span><p dir="ltr"><a href="https://www.centos.org/download/mirrors/" target="_blank">https://www.centos.org/download/mirrors/</a></p><span>
<p dir="ltr">><br>
> Also help me by sending the documents/steps for setting new one.</p>
</span><p dir="ltr"><a href="https://wiki.centos.org/HowTos/CreatePublicMirrors" target="_blank">https://wiki.centos.org/HowTos/CreatePublicMirrors</a></p>
<p dir="ltr">><br>
> Regards,<br>
> Ben.<br>
><br>
> _______________________________________________<br>
> CentOS-mirror mailing list<br>
> <a href="mailto:CentOS-mirror@centos.org" target="_blank">CentOS-mirror@centos.org</a><br>
> <a href="https://lists.centos.org/mailman/listinfo/centos-mirror" target="_blank">https://lists.centos.org/mailman/listinfo/centos-mirror</a><br>
><br>
</p>
<br>_______________________________________________<br>
CentOS-mirror mailing list<br>
<a href="mailto:CentOS-mirror@centos.org" target="_blank">CentOS-mirror@centos.org</a><br>
<a href="https://lists.centos.org/mailman/listinfo/centos-mirror" rel="noreferrer" target="_blank">https://lists.centos.org/mailman/listinfo/centos-mirror</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
CentOS-mirror mailing list<br>
<a href="mailto:CentOS-mirror@centos.org">CentOS-mirror@centos.org</a><br>
<a href="https://lists.centos.org/mailman/listinfo/centos-mirror" rel="noreferrer" target="_blank">https://lists.centos.org/mailman/listinfo/centos-mirror</a><br>
<br></blockquote></div><br></div></div>