Aufgabe: /pfad – /ordner1 – /ordner2 – usw.
Ergebnis:
/backuppfad/ordner1.tar.gz /backuppfad/ordner2.tar.gz usw.
#!/bin/sh PATH_DEST=/path/to/data PATH_BACKUP=/path/to/backup cd $PATH_DEST for d in `find . -maxdepth 1 -mindepth 1 -type d`; do i=`basename ${d}`; tar -cjf $PATH_BACKUP/$i.tar.bz2 "$i"; done