Q:

Backing up and restoring texlive 2011 (Linux)

Is there an easy and safe way to back up and restore an entire texlive installation, e.g. before a fresh OS (re)installation or to put onto another pc (same architecture)?
What I have in mind is to simply copy (rsync) my whole texlive directory (~/texlive) to my external HD, i.e. along with my usual home directory backup, then copy it back into my (new) home directory after doing a fresh install of Xubuntu. As far as I know, everything tex-related is in ~/texlive.
But I don't know whether tlmgr perhaps has a backup option (for entire texlive installations, not just packages), or if there's a better way. I also don't know if my proposal requires something extra, like updating tlmgr or what.

A:

Short answer: On Unix, copying the whole texlive directory is the correct way to backup and/or duplicate a whole TeX Live installation and is guaranteed to work. In TeX Live on Unix, everything lies in the texlive directory by design.
More details. If you used the "symlink" option during installation or installed symlinks later using tlmgr path add then you'll want to run this command on your new installation after restoring the files (possibly after setting the directories using tlmgr option sys_bin, sys_man and sys_info).
If you have anything in your ~/texmf, you'll obviously want to back it up too. Things in ~/.texlive2011/texmf-var are generated, you don't need to back them up. Files in ~/.texlive2011/texmf-config on the other hand hold configuration information (for example if you installed a font mapping only for your user using updmap (as opposed to updmap-sys)) so you'll probably want to back it up if it exists. Unless of course it was created by mistake (running updmap and fmtutil instead of their -sys variants is a common mistake), then you'll want to fix that before backing up.
Finally, as nplatis said, if your new architecture is different from the old one, install the new architecture before you do the backup/duplication.

A:

I have successfully duplicated a TeXLive installation simply by duplicating all the texlive folder (in my case, /usr/local/texlive).
I haven't even copied ~/.texlive2011/ folder, I believe it holds stuff that can be regenerated.
BTW, I have also been able to duplicate the TeXLive installation from an x86_64 machine to an x86 machine: before duplicating the folder I added the 32-bit architecture to texlive, then moved the folder to the new machive, and finally I removed the unneeded architectures from the two machines.

