I had to change my script to use one rsync run per drive. otherwise
my player would crash, even when using swap. Now that have had
a memory upgrade, it isn't necessary anymore, but I left it the way it
is. It's probably a tad faster as well.
Code:
#!/bin/sh
rsyncserver=192.168.101.1
modulename=empegfids
set -x
killall -INT player
# only remount if drives are mounted read-only
if grep -q "/dev/hd.4.* ro " /proc/mounts
then
remount=true
else
remount=false
fi
sleep 5
test $remount = true && sh -x rwm
ifconfig lo 127.0.0.1 up
for i in 0 1
do
rsync \
$@ \
--times \
--stats \
--delete \
--verbose \
--progress \
--recursive \
--empeg-progress \
--copy-unsafe-links \
--block-size=100000 \
--exclude=rsync \
${rsyncserver}::${modulename}/drive${i} /
done
test $remount = true && sh -x rom
killall is not included on the player. I got it from debian.
rsync itself is excluded in my script; that's because I sync
all my tools from empegfids::drive0/local/bin
Pim