I am using a headless Linux server in an off-site location and I access it using ssh
.
I tried upgrading to Ubuntu 18.04 LTS 64bit because of the constant nagging that Ubuntu 14.04 was outdated, yet I got a lot of error messages, afterwards. E.G. The mail server did not work any more.
Now, my provider offers a complete reinstall of a working Ubuntu 18.04 LTS 64bit at the expense of removing all data that was there previously.
Is there a diff-tool, that can tell me exactly what differentiates my system from an off-the-shelf Ubuntu 14.04, so I can easily backup only those files I need?
You can easily make a list of all the currently installed packages and you can use this list to install all of the currently installed packages at a later date.
You will need to find a way to save this list. You can email the list file or you can copy it to pastebin or download it somehow. Just make sure to save a copy of this list some place so that it can be retrieved at a later date.
Run the following command to create the list file called "INSTALLED.txt":
When the list file is in the current directory, you can install the packages on the list using the following commands:
Alternatively, you could copy and paste the list as plaintext into the terminal using
sudo apt install
and then paste the list into the terminal and then press enter.This will try to install all the current packages. However, there may be some package versions which are no longer available. There may be some other versions which have "no installation candidate" and you will have to search for these packages to see what package replaces the old one.
Source: I adapted the commands used in this blog entry at ostechnix.com.
Click here for information on performing a full backup instead.
Yes, this is possible, but you need to know what does not exist any more and what is different so:
What does not exist any more:
The above command will give you a list of files that do not exist in the new server.
grep ^deleting
because each line prints :deleting ..file..
What is different:
will give you a list of different files (including new files)
Good luck as depending on how long this server has been running you'll get thousands to millions of files that will be different, so whichever system you're going to use, it's never going to be easy as you requested.
Source