バリーさんのブログ 試訳 20110212 snapmerge

'snapmergepuppy' improved
snapmergepuppyの改良

スクリプト'snapmergepuppy' は、RAMメモリ上にあるセッションをフラッシュドライブ等の物理メディア中の保存ファイルにセーブするために使用されています。

Dougalさん、Jemimahさん、そして他の人たちが数々の修正や改良を研究してきました:
http://murga-linux.com/puppy/viewtopic.php?t=64570

私はそれらのいくつかを提供してきましたし、またスクリプトがunionfsでも旧式"unionfs互換"aufsでも動くようにと努めています。Woofのなかのわたしの
/usr/sbin/snapmergepuppy :

#!/bin/ash
#2007 Lesser GPL licence v2 (http://www.fsf.org/licensing/licenses/lgpl.html)
#Barry Kauler www.puppylinux.com
#called from savepuppyd and rc.shutdown, to save tmpfs layer to permanent flash storage.
#updated 13 Sept 2007. copy-down only. flushing is done in petget.
#updated 24 Sept 2007. removed '-u' option when copy-down files.
#8 oct 2007: screen out /root/tmp when saving.
#4 nov 2007: reintroduce '-u' copy option.
#v4.01 19may2008 BK: now called from /sbin/pup_eventd daemon (savepuppyd now history).
#v4.01 19may2008 BK: if called from pup_eventd then X running: graceful exit if X shutdown.
#v409 BK: XRUNNING test should be 'pup_event_frontend_d'.
#v409 BK: save /var dir. previously screened out to save space, but prevents crontab from running.
#v412 /etc/DISTRO_SPECS, renamed pup_xxx.sfs, pup_save.2fs etc.
#w000 pup files renamed to woofr555.sfs, woofsave.2fs.
#w003 bug fix for .wh.__dir_opaque whiteout file.
#w003 screened out some dirs in /dev that should not be saved.
#v424 fix for more layers in unionfs/aufs.
#100222 shinobar: possible timezone problem with BOOTCONFIG. more file exclusions.
#100422 added ^root/ftpd exclusion.
#100429 modify 'trash' exclusion.
#100820 added /var/tmp exclusion (apparently filled by opera crashes).
#101221 yaf-splash fix.
#110206 Dougal: clean up some testing. speedup: LANG=C, also change to /bin/ash.
#110212 recent aufs: .wh.__dir_opaque name changed to .wh..wh..opq.
#110212 Jemimah: files may disappear, more efficient calc of free space, fix i/o err.

.....(訳者註: 以下省略します)

ノート:
このマイ スクリプトは、GTKダイアログをベースにした"ニュー"yaf-splash"を呼び出します。オールドヴァージョンを使用するには、あなたは usr/X11R7/bin/yaf-splash へのパスをハードコードする必要があり、プラス、エクストラなコマンドラインのパラメータが必要とされます。

私はまたinitrdの中の'init'スクリプトのコードも編集して .wh.__dir_opaque や .wh..wh..opq のような別名も取り扱うようにしました。

'snapmergepuppy' improved
Script 'snapmergepuppy' is used to save a session running in RAM to the save-file in the physical media, example Flash drive....

http://bkhome.org/blog/?viewDetailed=02139