[p900] some notes on backupping data

  • From: Alfonso Martone <a.martone@xxxxxxxxxxx>
  • To: p900@xxxxxxxxxxxxx
  • Date: Wed, 24 Dec 2003 05:52:47 +0100

Below, a little script of a script to backup some data using p3nfs. 
Currently it justs backups (keeps a copy on the PC hard disk) or 
backups+moves (moves files from P900 to local directories); the first 
case for Jotter/Agenda/etc files, the latter for images, voicenotes, 
videos, etc.

This is just a first draft, assuming that in your ~/P900/archive 
directory there are the "jpg", "wav" and "mp4" directories, while the 
P900 filesystem is already mounted on /mnt via p3nfsd driver.

Future enhancements:
- add other data files (browser URL files, etc)
- don't copy a file if it has same date and size (with exceptions)
- (maybe) an rsync-like daemon for the P900 for mirroring its disks


  echo backup: $2
  cp -a "/mnt/$1/documents/$2"  ~/"P900/backup/$1/documents/" || exit 

  cd "/mnt/$1/documents/$3"
  for a in *."$2"
    if [ "$a" != "*.$2" ]
      echo moving: "$a"
      mv -i "$a" ~/"P900/archive/$2/" || exit 2

backup C:    Agenda
backup C:    Jotter
backup C:    Cmra
backup C:    QSyncML

bmove  C:  wav  "Voice/VoiceNote"
bmove  C:  jpg  "Media files/image/unfiled"
bmove  C:  mp4  "Media files/video/unfiled"

delete C:/system/data/TMP*.\$\$\$

echo --- ok ---
exit 0

# p.s.: rcomp and uidcrc seem to run OK, wait me for more info...!

Other related posts:

  • » [p900] some notes on backupping data