LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   rsync and slackware-current (https://www.linuxquestions.org/questions/slackware-14/rsync-and-slackware-current-189437/)

nikko 06-03-2004 05:43 PM

rsync and slackware-current
 
I like to keep a fairly fresh mirror of slackware-current on my network, for various reasons. I noticed that over a short period of time, the iso I create from it has gotten too big to fit on a CD. I started digging and the reason became quickly obvious. My mirror has all versions of every file since I started rsync'ing! Is there a way to update slackware-current without having to blow away my entire mirror every time I want to get in sync?

An example:
aaa_lib_2.4.26_1.tgz
aaa_lib_2.4.26_2.tgz
aaa_lib_2.4.26_3.tgz

are all updates of the same libs. How can I just update what's there to the latest, keeping only the latest file (and filename)

This would save me lots of bandwidth as well, because only the differences would be brought over with rsync vs. the entire file.

Norinett 06-05-2004 07:50 AM

Use the "--delete" option with rsync. It will clean up the old files.

nikko 06-05-2004 01:06 PM

It'll do this with files with different names? How does it know one is a replacement for the other?

zulik 06-05-2004 03:16 PM

zulik@localhost:~$ cat /home/data/skrypty/upd
#!/bin/bash
rsync -arvvP --delete ftp.slackware.at::slackware/slackware-current/slackware /home/data/swaret
ln -s /home/data/swaret/slackware/FILE_LIST /home/data/swaret/slackware/FILELIST.TXT
swaret --update

Norinett 06-06-2004 04:33 PM

With the "--delete" option, rsync simply makes it a real mirror of the site you are mirroring. Without it you are leaving old files on your hd.

It checks if there is local files that not exist on the remote site, and delete them if there is. And ofcourse otherwise.

[root@*] [~]# more /usr/local/sbin/mirrorslackware
rsync -a -v --delete rsync://rsync.slackware.no/slackware/slackware-current /home/ftp/pub/mirrors/slackware/

Works fine.

zulik 06-07-2004 12:49 AM

Quote:

Originally posted by Norinett
With the "--delete" option, rsync simply makes it a real mirror of the site you are mirroring. Without it you are leaving old files on your hd.

It checks if there is local files that not exist on the remote site, and delete them if there is. And ofcourse otherwise.

[root@*] [~]# more /usr/local/sbin/mirrorslackware
rsync -a -v --delete rsync://rsync.slackware.no/slackware/slackware-current /home/ftp/pub/mirrors/slackware/

Works fine.

Works fine !?

Trust me "ln -s" between FILE_LIST and FILELIST.TXT is necessery

AxeZ 06-07-2004 01:59 AM

Quote:

[i]
[root@*] [~]# more /usr/local/sbin/mirrorslackware
rsync -a -v --delete rsync://rsync.slackware.no/slackware/slackware-current /home/ftp/pub/mirrors/slackware/

Works fine. [/B]

Actually I am mirroring from slackware.no likewise and using --delete option and few daya ago someone on that server deleted complete slackware-current directory and rsync deleted everything from my disk also....:(
Pretty frustrating.....$@#%@#^%$#$^@...damn


I am keeping two repositories on my HD now

Norinett 06-07-2004 03:35 AM

Quote:

Originally posted by zulik
Works fine !?

Trust me "ln -s" between FILE_LIST and FILELIST.TXT is necessery

The official mirror has no "FILE_LIST", so why should I need it?

Norinett 06-07-2004 03:36 AM

Quote:

Originally posted by AxeZ
Actually I am mirroring from slackware.no likewise and using --delete option and few daya ago someone on that server deleted complete slackware-current directory and rsync deleted everything from my disk also....:(
Pretty frustrating.....$@#%@#^%$#$^@...damn


I am keeping two repositories on my HD now

Strange... I mirror it daily, and that has not happend to me..

zulik 06-07-2004 03:48 AM

Quote:

Originally posted by Norinett
The official mirror has no "FILE_LIST", so why should I need it?
ftp://ftp.slackware.at/slackware-current/slackware/

position nr 3

1: look at my script ( I'm downloading only ftp.slackware.at/slackware-current/slackware/)
not all file from ftp://ftp.slackware.at/slackware-current/

2: swaret use FILELIST.TXT

Norinett 06-07-2004 04:50 AM

Ah, but I'm mirroring the whole slackware-current :-)

zulik 06-07-2004 05:10 AM

So on seriously, why you need the whole ?

Norinett 06-07-2004 08:34 AM

I'm creating my own installcd's now and then, based on the current version, but heavy modifyed by myself.

nikko 06-07-2004 08:49 AM

Quote:

Originally posted by zulik
So on seriously, why you need the whole ?
I use it in cobination to mkisofs and cdrecord to make my own boot cd's based on slackware-current. I build new systems offline with it. I keep it current, well, to keep it current.


All times are GMT -5. The time now is 08:41 PM.