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 <tony@xxxxxxxxxxxxx> wrote: > In article <CANZsmmM6C_F+NuPdjd+mGDEXaJVcfc1bdhpWdESSbC2CR7Dz3 > g@xxxxxxxxxxxxxx>, > Felipe Westfields <felipe.westfields@xxxxxxxxx> 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: tony@xxxxxxxxxxxxx - http://www.softins.co.uk > Play: tony@xxxxxxxxxxxxxxx - http://tony.mountifield.org > _______________________________________________ > CentOS mailing list > CentOS@xxxxxxxxxx > https://lists.centos.org/mailman/listinfo/centos > _______________________________________________ CentOS mailing list CentOS@xxxxxxxxxx https://lists.centos.org/mailman/listinfo/centos