solydfixes README Version 5.0.0 - 6 August 2021 Contents ======== - Introduction - Installation - Contents of the tarball - Library directory - Upgrading the script - Removing the script - Functions - Upgrading a SolydXK system - Removing the dmo packages and repository - Downloading Google's public signing keys - Removing all keys from /etc/apt/trusted.gpg - Creating sources.list - Fixing non-system values of system groups - Licence and disclaimer Introduction ============ The solydfixes script provides various fixes for SolydXK systems. The first versions were created to ease processing of the SolydXK Home Editions' July 2014 Update Pack. Later versions gained several extra functions, some of which are no longer useful. The description of those earlier versions is still available from the website ( https://duinsoft.nl/solydfixes.php ). The --help option of the script currently provides this list of functions and options: Usage: solydfixes [OPTION...] ARGUMENT... General options: -c FILE use FILE as configuration file instead of solydfixes.conf -h, --help display this text and exit -l open the log in an editor after the action -ll ditto - also open the apt logs -r open the README file in an editor -y use the --yes option with apt-get (see apt-get manpage) --remove [+log] remove an installed set, optionally including the log files Arguments with related options (if any): upgrade [TARGET] upgrade a SolydXK system (and its Debian base) to version 11 or, with stable or testing as target, to (Debian) stable or testing (the latter also upgrades SolydXK to EE) hold do not 'unhold' any held packages dmo remove deb-multimedia.org (DMO) repository and packages get download the most recent version of this script google download Google's most recent public signing keys keys remove all keys from /etc/apt/trusted.gpg and hide it sources ... create sources.list -L lock sources.list -U unlock sources.list -a create without the need for further arguments -s merely simulate, but do perform (un)locking if selected sysgroups fix non-system values of system groups lpadmin, sambashare and vboxusers Installation ============ This script is not distributed in a Debian package but supplied in a tarball. That means you cannot install it using your package manager, but have to download the tarball and 'install' it yourself. Just create a directory called solydfixes anywhere you like and extract the tarball to it, keeping the layout/structure intact. Any good file manager should do that automatically if you select 'Extract here' or 'Extract to...' from its context menu. You can run the script from the terminal, open on that directory, with ./solydfixes ... or from any other directory if you use the full pathname. If you create a symlink to the main script in /usr/local/bin or ~/bin, you can call it from anywhere with just solydfixes ... Alternatively, you can 'install' the script properly, i.e. put the main script in /usr/local/bin and the rest in /usr/local/lib/solydfixes (no package manager involved means using /usr/bin and /usr/lib/solydfixes is out...). You can do that by running ./install from the directory you just created. Contents of the tarball ----------------------- The solydfixes tarball currently contains: lib/solydfixes/akm solydfixes' apt-key replacement lib/solydfixes/functions miscellaneous support functions lib/solydfixes/history some notes about the script's development lib/solydfixes/README this file lib/solydfixes/stagedata variable names for the idempotence functionality solydfixes the main script install script that takes care of installing or upgrading the set to a new version The script will create and use a scratch directory in /tmp (with a name starting with solydfixes.), a data directory (/var/local/solydfixes) and a log file (/var/log/solydfixes.log). The latter can be opened in a graphical editor with the command solydfixes -l (that's a lower case L, by the way). Be aware that the log will not show all the install/remove/upgrade info and terminal output from apt-get, as most of that can already be found in /var/log/apt/history.log and /var/log/apt/term.log (which can be opened by specifying an extra l in the above command). Library directory ----------------- The lib/solydfixes subdirectory is the library directory. This is where the script expects to find its support files. Keeping this in the unpacked solydfixes directory is fine, but it is not where the script itself would put it. Upgrading the script -------------------- The script uses a simple DNS call to check whether a new version is available. If there is one, it will tell you about it and you can download the new version from the website ( https://duinsoft.nl/solydfixes.php ) or use the command solydfixes get to make the script download it itself. The get function will download the tarball and 'install' the script and support files in the default locations (see above). If the old version of the script is running from another directory called 'bin' (e.g. in your home directory), the new version will end up there. If necessary a 'lib/solydfixes' directory will be created on the same path. Removing the script ------------------- Removing the script and associated files and directories can be done with the command solydfixes --remove If you want the log files gone as well, use solydfixes --remove +log This command will work on an installed set and also on a set which is not actually installed but stored in a directory with the name of the script. Be aware this command executes immediately (after asking for your sudo password, if necessary) and bluntly removes the entire script set. If you used its directory to store anything you want to keep, move it out of the way first. Functions ========= The available functions are: - Upgrading a SolydXK system - Removing the dmo packages and repository - Downloading Google's public signing keys - Removing all keys from /etc/apt/trusted.gpg - Creating sources.list - Fixing non-system values of system groups Most of these were already present in (much) earlier versions of the script and some are more or less outdated, but might still come in handy. Upgrade a SolydXK system ------------------------ If you run the script with the terminal command solydfixes upgrade it should upgrade your SolydXK 10 / Debian Buster system to SolydXK 11 / Debian Bullseye. The command solydfixes upgrade stable should essentially do the same, but the sources list will contain stable instead of bullseye. This will cause the system to upgrade automatically when the current testing suite becomes the new stable, so only do this if you really know what you are doing. DMO --- You can include the dmo argument to remove the deb-multimedia.org packages (see below), if your system still has that repository in its sources.list and you want to get rid of it (it is not a good idea to remove the repository and keep the packages!). Testing/EE ---------- To move to Debian Testing instead of Bullseye, run solydfixes upgrade testing You could also do this at a later date, after moving to Bullseye first. It will switch your system's sources.list and go through the whole process again, probably skipping most of it, but that should not be a problem. If you already are on Testing (Enthusiast's Edition), running the default upgrade command - or the one with testing - will 'upgrade' your system from Buster to Bullseye, by replacing the system-adjustments package with the right version (11 -> 12). The dmo argument can also be used in these cases, by the way. Held packages ------------- Because of possible issues with dependencies, keeping packages on hold during this type of upgrade is usually a bad idea. However, this is not an absolute rule. There may be packages you can safely keep at their current version, mainly ones you installed from other sources, which might end up autoremoved if you 'unhold' them. If you have any such packages and know what you are doing, you may add the hold argument to the command line. Rerun ----- The script has been tested on several different setups and never seriously bombed out. That statement alone is enough to make sure this *will* happen to someone. If it does crash, you can usually just run it again and it should skip the bits it has already handled. No interruptions ---------------- If you want the entire upgrade process to run without answering any questions, you can add the -y switch. The only question that might slip through, is one about GRUB's install destination. Even this may not happen, but if it does, do pay attention, because your system may become unbootable if you do not. Remove deb-multimedia.org ------------------------- This function uses the functionality suggested in https://forums.solydxk.com/viewtopic.php?f=14&t=4030#p37280 to replace the packages from deb-multimedia.org (DMO) with the ones provided by the main Debian repositories. Unfortunately, this is not a perfect switch as not all of the DMO packages are available there. The ones missing are listed at the end of the run and that listing is also stored in the log (/var/log/solydfixes.log). Command: solydfixes dmo Download Google's public signing keys ------------------------------------- Google has a tendency to start using new signing subkeys without telling anyone, which can be a pain if you have one of their repositories in your sources lists (e.g. for Chrome). If you enter solydfixes google the script will pick up the file containing the public keys from the URL listed on the page mentioned below and store it in /etc/apt/sources.list.d/. See the next paragraph for why using the method suggested by Google is deprecated. ----- https://www.google.com/linuxrepositories/ Remove all keys from /etc/apt/trusted.gpg ----------------------------------------- The public keys used to verify the signature of various package lists used to be stored in the file /etc/apt/trusted.gpg. Adding the keys from maintainer scripts (or directly from websites) required the tool apt-key. Because "the programatic usage [of apt-key] is strongly discouraged" (manpage quote), keys should now be stored in separate files (with .asc or .gpg extension for armoured and non-armoured keys respectively) in /etc/apt/trusted.gpg.d/. This action will move all keys in /etc/apt/trusted.gpg there, provided they are not there already. The names of the files will be the fingerprints of the respective keys, with the spaces removed. The file /etc/apt/trusted.gpg will be moved out of the way by adding the extension .obsolete. Command: solydfixes keys Create sources.list ------------------- For SolydXK's main edition the sources.list file is kept up-to-date by a python script in the solydxk-system package. This does not happen for the Enthusiast's Edition. The 'sources' function can create a suitable sources.list file for any edition. It can also lock the file so nothing can change it, not even the aforementioned python script. Run solydfixes -a sources to create a list in 'automatic' mode, i.e. let solydfixes figure out what should be in it. Add the -s switch to simulate the action without actually making any changes, so you can check the result. Lock or unlock the file with the -L or -U switch respectively. This also works if the -s option is used. If you want to fine-tune your sources list, e.g. by using local mirrors instead of the main repositories, you give the command without the -a switch and with additional arguments. In any order. argument description (some) possible values ---------------------- ------------------------------ SolydXK release number 11, 12, s-11, s-ee SolydXK testing section s-testing Debian suite name bullseye, testing Debian mirror service deb ISO3166-1 country code au, gb, hu, nl, ph, se, us, za source repository src backports repository backports, bp You need to specify 12 as release number for the Enthusiast's Edition, as ee would be interpreted as a country code. However, you can use s-ee. If you enter the code of a country that does have a Debian repository but not a SolydXK one, the main repository will be used for SolydXK only. You can specify this further by putting s: or d: before the country code. This also works for source entries you might want to add to your sources list. A full example: solydfixes -L sources 11 bullseye s:se d:de s:src bp This should create a locked sources.list file for the current stable release, using the Swedish SolydXK mirror, the German Debian mirror and a source entry for SolydXK only. The backports repository would be included. Fix non-system values of system groups -------------------------------------- Some versions of the live installer created the wrong type of group numbers for some system groups, i.e. values above instead of below 1000. This is not a problem as such, but if you create another user, its group number will not be the same as its user number, which can be. This command fixes the numbers for lpadmin, sambashare and vboxusers. It will not fix the group numbers for any users you may have created. Command: solydfixes sysgroups Licence and disclaimer ====================== This script is provided under the EUPL, version 1.2, which is a FOSS licence, compatible with GPLv2. As far as I am aware, the script does what it is supposed to do. Nevertheless, you use it entirely at your own risk. That said, if you find a bug, do get in touch with me and I will see what I can do about it. ----- EUPL: https://joinup.ec.europa.eu/collection/eupl/introduction-eupl-licence FOSS: https://en.wikipedia.org/wiki/Free_and_open-source_software GPL: https://www.gnu.org/licenses/