I'm currently trying to figure out which directories I need if I want to download all data from my debian (9) server.
I already figured out that /dev and /proc along with /mnt don't contain any "real" files but stuff displayed as file (drives, processes, ...) but which other directories don't have real files in them?
There are a couple of directories which contain files (because everything in a Unix file system is a file), but those files are not something which can be practically archived and copied to another system:
/dev, which contains device special files and some pipes;
/proc, which contains Linux process and kernel information; and
/sys, which contains Linux kernel information.
There are other directories which you may not want to copy over, even though they do contain archivable contents:
/var/run, which contain files that are used by programs that are presently running, but will be cleared on boot;
/var/tmp, which are ephemeral temporary files;
/boot, which contains bootable materials that may be specific to this system; and
/media, which may contain additional drives which you may not (or may) want to archive.
I generally prefer to archive just
/srv and not care very much about the rest. For example, I don't need to archive the contents of
/usr because I can just download the Debian packages again.
You may also need to gracefully handle any sockets or FIFOs that get copied, since those can occasionally live under your home directory. Usually it's fine to ignore them and let them get recreated by programs that need them, though.