BackupPC-users

Re: [BackupPC-users] USB dongle backup

2014-03-10 21:04:06
Subject: Re: [BackupPC-users] USB dongle backup
From: Claude Gélinas <claude AT phyto.qc DOT ca>
To: backuppc-users AT lists.sourceforge DOT net
Date: Mon, 10 Mar 2014 21:02:40 -0400
Le Tue, 11 Mar 2014 00:41:30 +0100,
Arnold Krille <arnold AT arnoldarts DOT de> a écrit :

> Hi,
> 
> On Mon, 10 Mar 2014 18:43:09 -0400 Claude <claude AT phyto.qc DOT ca> wrote:
> > As I'm using BackupPC since many years for all my computers and
> > laptop I'm wondering if it is possible to setup an automated backup
> > system to catch my many usb dongle as I'm comming back to the
> > office. 
> > 
> > I want to insert these in a usb bay until next morning so backuppc
> > will detect them and make a backup
> > 
> > How to proceed. Is it possible to format these usb dongle to give
> > them a unique name so backuppc will recognise them as they are
> > plugged into the bay
> 
> I do something similar with my android phones:
> 
> I set up automount to mount the phones on fixed locations. Then I
> created a backuppc 'host' with a custom ping command of
> "sudo /var/lib/backuppc/bin/checkhandy.sh /misc/schieber" where
> checkhandy.sh is:
> 
> ===
> 
> #!/bin/bash
> 
> echo "Checking for directory of mobile phone (with arguments '$*')"
> |logger
> 
> lockfile=/tmp/backuppc-lshw.lock
> 
> sleep $[$RANDOM%3]
> 
> if [ ! -e $lockfile ]; then
>         touch $lockfile
>         lshw >& /dev/null
>         rm $lockfile
> else   
>         while [ -e $lockfile ]; do
>                 sleep 5
>         done
> fi
> 
> if [ -z $1 ]; then
>         dir=/misc/schieber;
> else   
>         dir=$1
> fi
> 
> ret=-1
> [ -d $dir ] && ret=0
> 
> echo "Will return $ret for directory $dir" |logger
> 
> exit $ret
> ===
> 
> Then its just a matter of backing up /misc/schieber in this case.
> 
> Running lshw in that script is needed on my headless server as
> otherwise it wouldn't recognise the partition-table on the mobile.
> With an usb-stick you can probably do without.
> 
Thanks Arnold,

I will give it a try. Do you need to put that script in a specific
location or can I put it in /usr/local/bin


-- 
Claude Gélinas agr.
Phyto Ressources Inc

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
BackupPC-users mailing list
BackupPC-users AT lists.sourceforge DOT net
List:    https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:    http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/
<Prev in Thread] Current Thread [Next in Thread>