p.H wrote: ↑2021-11-23 22:35
sunrat wrote: ↑2021-11-23 21:48
That would assume all installations of packages not marked manual are identical, so no.
No, that assumes packages marked automatic were not installed by the user but by dependencies, and will be installed if needed. Anything wrong with that ?
Cool. Once again you have proved to be a veritable bitstream of knowledge and help. Thank you!
So this gets a list of manual packages which can be installed by apt on a new install, much tidier command too:
Code: Select all
$ apt-mark showmanual | awk 1 ORS=' ' >pkglist
On the new system (I would use a minimal netinstall):
Bottom line is this would be my preferred method to duplicate a Debian installation to a different computer. No need to edit boot loaders or system files like fstab. Just do a new netinstall, install packages, then copy your data over afterwards. It may even lose some unnecessary cruft.
Of course this doesn't copy over any customisations so you may need to copy config files from your backup, and if vastly customised the partition cloning method may end up easier. YMMV.