ALT Linux Sisyphus discussions
 help / color / mirror / Atom feed
From: "Dmitry V. Levin" <ldv@altlinux.org>
To: ALT Linux Sisyphus discussion list <sisyphus@altlinux.ru>
Subject: Re: [sisyphus] использование rsync
Date: Sat, 25 Dec 2004 20:13:51 +0300
Message-ID: <20041225171351.GA2586@nomad.office.altlinux.org> (raw)
In-Reply-To: <41CC0463.2090201@delin.ru>

[-- Attachment #1: Type: text/plain, Size: 1613 bytes --]

Hi,

On Fri, Dec 24, 2004 at 02:58:27PM +0300, Vladimir wrote:
> Dmitry V. Levin пишет:
> >On Fri, Dec 24, 2004 at 01:02:04PM +0300, Vladimir wrote:
> >
> >>Так как в rsync после 2.6.2 несколько изменилось поведение ключей,
> >
> >Что именно в поведении rsync вас беспокоит?
> 
> У меня синхронизация репозитория настроена примерно так.
> 
> Имеются вспомогательный каталог для синхронизации и каталог рабочий.
> В "установившемся" состоянии в рабочем каталоге лежат реальные
> файлы, а в дополнительном - symlinks на них.
> 
> Раньше, при синхронизации, rsync удалял устаревшие ссылки и загружал новые
> файлы. После этого у новых файлов проверялись md5sum и gpg sign.
> Если все OK, то файлы перемещались в "рабочий" репозиторий, замещаясь
> ссылками на них. Если нет, то перемещались в "карантин".
> 
> Дополнительно, из рабочего каталога во временную "корзину" уходили
> файлы с удаленными ссылками. Это же "ядро" хорошо работает и с
> off-line синхронизацией от CD срезов Sysiphus.

Немного другую схему, реализующую описанную выше задачу, можно посмотреть
на следующем примере:

1. создаём модель:
$ mkdir src dst backup
$ touch src/same src/new dst/old
$ cp -a src/same dst/
$ echo src >src/changed
$ echo dest >dst/changed

2. готовим каталог для синхронизации:
$ cp -al dst new

3. закачиваем:
$ rsync -rt src/ new/ --partial --delete-after --backup --backup-dir=$PWD/backup

4. анализируем результат:
$ find backup -type f
backup/changed
backup/old
$ find new -type f -links 1
new/changed
new/new
$ find new -type f -not -links 1
new/same


-- 
ldv

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

  parent reply	other threads:[~2004-12-25 17:13 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-24 10:02 [sisyphus] специфика wget Vladimir
2004-12-24 10:08 ` Dmitry V. Levin
2004-12-24 11:58   ` Vladimir
2004-12-24 12:51     ` Ivan Fedorov
2004-12-24 14:19       ` Vladimir
2004-12-25  8:28         ` Ivan Fedorov
2004-12-25 17:13     ` Dmitry V. Levin [this message]
2004-12-27  7:03       ` [sisyphus] использование rsync Ivan Fedorov
2004-12-27  9:10       ` fmfm

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20041225171351.GA2586@nomad.office.altlinux.org \
    --to=ldv@altlinux.org \
    --cc=sisyphus@altlinux.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

ALT Linux Sisyphus discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
		sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
	public-inbox-index sisyphus

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.sisyphus


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git