[CentOS] Mirroring centos.org
Hello, I would like to mirror the centos.org repository for an offline network. I don't need the ISO images, don't need any i386 stuff, and I think I probably don't need any of the source code rpms either. Most of the clients are CentOS 6.x, so I don't want to download the CentOS 7.x tree yet either (that will come soon, but separately from this one). I tried using this command, but it still downloaded all of the i386 sub-folders anyway, and I got about 15 gigs or so of stuff I didn't want. wget -m -np --exclude-directories=i386 http://mirror.centos.org/centos-6/6/ I'm guessing there's a formatting mistake of some kind in this command. Do you need to specify the excluded sub-folders relative to the top directory you're downloading from? i.e. rather than "i386", you'd need to specify "/centos-6/6/updates/i386/"? FW ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Mirroring centos.org
On Mon, Jan 29, 2018 at 10:22:49AM -0500, Felipe Westfields wrote: > > Hello, > > I would like to mirror the centos.org repository for an offline network. I You probably should start by not mirroring mirror.centos.org, but a local mirror: https://centos.org/download/mirrors/ If you plan on regularly mirroring the CentOS repos on that site, please contact them and let them know. You should also consider using a yum-aware tool like reposync, mrepo or pulp to create your own repos, rather than using 'wget'. Many repos have rsync:// support, which means you can also use rsync to do this. -- Jonathan Billings ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Mirroring centos.org
In article , Felipe Westfields wrote: > Hello, > > I would like to mirror the centos.org repository for an offline network. I > don't need the ISO images, don't need any i386 stuff, and I think I > probably don't need any of the source code rpms either. Most of the clients > are CentOS 6.x, so I don't want to download the CentOS 7.x tree yet either > (that will come soon, but separately from this one). > > I tried using this command, but it still downloaded all of the i386 > sub-folders anyway, and I got about 15 gigs or so of stuff I didn't want. > > wget -m -np --exclude-directories=i386 http://mirror.centos.org/centos-6/6/ > > I'm guessing there's a formatting mistake of some kind in this command. Do > you need to specify the excluded sub-folders relative to the top directory > you're downloading from? i.e. rather than "i386", you'd need to specify > "/centos-6/6/updates/i386/"? Don't use wget at all. Use rsync instead, from a mirror that supports it. Here is what I use (in a nightly cron): # cd /myrepo # rsync -rltHvz --delete rsync://rsync.mirrorservice.org/mirror.centos.org/6/os/i386/ centos6/os/i386/ # rsync -rltHvz --delete rsync://rsync.mirrorservice.org/mirror.centos.org/6/updates/i386/ centos6/updates/i386/ # rsync -rltHvz --delete rsync://rsync.mirrorservice.org/mirror.centos.org/6/os/x86_64/ centos6/os/x86_64/ # rsync -rltHvz --delete rsync://rsync.mirrorservice.org/mirror.centos.org/6/updates/x86_64/ centos6/updates/x86_64/ Omit the ones you don't want. There are other ideas listed at https://wiki.centos.org/HowTos/CreateLocalMirror Cheers Tony -- Tony Mountifield Work: t...@softins.co.uk - http://www.softins.co.uk Play: t...@mountifield.org - http://tony.mountifield.org ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Mirroring centos.org
Ok, that sounds a little more elegant. Does that delete switch delete those files after download, or does it stop it from downloading at all? On Mon, Jan 29, 2018 at 10:48 AM, Tony Mountifield wrote: > In article g...@mail.gmail.com>, > Felipe Westfields wrote: > > Hello, > > > > I would like to mirror the centos.org repository for an offline > network. I > > don't need the ISO images, don't need any i386 stuff, and I think I > > probably don't need any of the source code rpms either. Most of the > clients > > are CentOS 6.x, so I don't want to download the CentOS 7.x tree yet > either > > (that will come soon, but separately from this one). > > > > I tried using this command, but it still downloaded all of the i386 > > sub-folders anyway, and I got about 15 gigs or so of stuff I didn't want. > > > > wget -m -np --exclude-directories=i386 http://mirror.centos.org/ > centos-6/6/ > > > > I'm guessing there's a formatting mistake of some kind in this command. > Do > > you need to specify the excluded sub-folders relative to the top > directory > > you're downloading from? i.e. rather than "i386", you'd need to specify > > "/centos-6/6/updates/i386/"? > > Don't use wget at all. Use rsync instead, from a mirror that supports it. > Here is what I use (in a nightly cron): > > # cd /myrepo > # rsync -rltHvz --delete rsync://rsync.mirrorservice. > org/mirror.centos.org/6/os/i386/ centos6/os/i386/ > # rsync -rltHvz --delete rsync://rsync.mirrorservice. > org/mirror.centos.org/6/updates/i386/ centos6/updates/i386/ > # rsync -rltHvz --delete rsync://rsync.mirrorservice. > org/mirror.centos.org/6/os/x86_64/ centos6/os/x86_64/ > # rsync -rltHvz --delete rsync://rsync.mirrorservice. > org/mirror.centos.org/6/updates/x86_64/ centos6/updates/x86_64/ > > Omit the ones you don't want. > > There are other ideas listed at https://wiki.centos.org/ > HowTos/CreateLocalMirror > > Cheers > Tony > -- > Tony Mountifield > Work: t...@softins.co.uk - http://www.softins.co.uk > Play: t...@mountifield.org - http://tony.mountifield.org > ___ > CentOS mailing list > CentOS@centos.org > https://lists.centos.org/mailman/listinfo/centos > ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos
Re: [CentOS] Mirroring centos.org
On 29/01/2018 16:21, Felipe Westfields wrote: > Does that delete switch delete those files after download, or does it stop > it from downloading at all? It means "remove files that aren't on the source". This would generally be older versions of packages that have been replaced. ___ CentOS mailing list CentOS@centos.org https://lists.centos.org/mailman/listinfo/centos