Sospetto fortemente l'esclusione del /home
la directory nel tuo backup tar'd è il risultato dell'esecuzione come root (directory home directory di root /root/
). Dando un'occhiata alla pagina man (presa da http://linux.die.net/man/1/tar ), le seguenti opzioni potrebbe potenzialmente causa / risoluzione / debug della tua situazione:
Main operation mode:
-C, --directory=DIR
change to directory DIR
-p, --preserve-permissions
extract information about file permissions (default for superuser)
-v, --verbose
verbosely list files processed
Operation modifiers:
-g, --listed-incremental=FILE
handle new GNU-format incremental backup
-G, --incremental
handle old GNU-format incremental backup
Handling of file attributes:
--group=NAME
force NAME as group for added files
--mode=CHANGES
force (symbolic) mode CHANGES for added files
--no-same-owner
extract files as yourself (default for ordinary users)
--no-same-permissions
apply the user's umask when extracting permissions from the archive (default for ordinary users)
--no-xattrs
Don't extract the user/root xattrs from the archive
--numeric-owner
always use numbers for user/group names
--owner=NAME
force NAME as owner for added files
-p, --preserve-permissions, --same-permissions
extract information about file permissions (default for superuser)
--same-owner
try extracting files with the same ownership as exists in the archive (default for superuser)
--xattrs
Save the user/root xattrs to the archive
Device selection and switching:
--force-local
archive file is local even if it has a colon
Archive format selection:
-H, --format=FORMAT
create archive of the given format--FORMAT is one of the following:
gnu, oldgnu, pax, posix, ustar, v7, --old-archive, --portability,
--pax-option=keyword[[:]=value][,keyword[[:]=value]]... , --posix,
-V, --label=TEXT
<see webpage/ man page for details>
Local file selection:
--add-file=FILE
add given FILE to the archive (useful if its name starts with a dash)
-C, --directory=DIR
change to directory DIR
-h, --dereference
follow symlinks; archive and dump the files they point to
--hard-dereference
follow hard links; archive and dump the files they refer to
-K, --starting-file=MEMBER-NAME
begin at member MEMBER-NAME in the archive
--one-file-system
stay in local file system when creating archive
-P, --absolute-names
don't strip leading '/'s from file names
--recursion
recurse into directories (default)
File name transformations:
--no-anchored
patterns match after any '/' (default for exclusion)
--no-ignore-case
case sensitive matching (default)
--no-wildcards
verbatim string matching
--no-wildcards-match-slash
wildcards do not match '/'
--wildcards
use wildcards (default)
--wildcards-match-slash
wildcards match '/' (default for exclusion)
Informative output:
--index-file=FILE
send verbose output to FILE
-l, --check-links
print a message if not all links are dumped
--show-defaults
show tar defaults
--show-omitted-dirs
when listing or extracting, list each directory that does not match search criteria
--show-transformed-names, --show-stored-names
show file or archive names after transformation
-v, --verbose
verbosely list files processed
-w, --interactive, --confirmation
ask for confirmation for every action
Sicuramente MOLTO da considerare, ma i comandi di Linux non sono nulla se non flessibili e potenti. Immagino che se studi ognuna di queste opzioni usando una scatola di prova con una struttura di filesystem limitata, eseguendo la distribuzione che intendi impiegare, colpirai la combinazione esatta da includere nella sceneggiatura per produrre il risultato esatto che desideri.
Per il gusto di costruire una conoscenza comune, potresti postare con la soluzione che dà il comportamento che desideri?