What exactly does fsck do?
It does not seem to be among the tools suggested in the Btrfs documentation.
I was currently able to send a snapshots, which I had previously saved, to the Btrfs partition.
From a live session I reinstalled the kernel and Grub. I tried to boot the system but I encounter this error:
[!!!!!!] Failed to mount API filesystems.
[ 1.451969] systemd[1]: Freezing execution.
Can this be resolved in any way?
With a view to reinstalling, do you recommend any particular configuration of Btrfs volumes and subvolumes?
The data (meaning documents, photos, etc.) are on different disks and partitions, so the /home only keeps the configuration files of the various applications and customizations.
In case there is a need to install other Linux systems on the same disk, is it advisable to have a shared /home partition taking into account what was written just now?
For snapshots management, is it okay to continue using Timeshift or would it be better to switch to Btrfs Assistant?
I would suggest NO!
Each app that writes and depends upon a config written under the users home directory may have differences in versions and needs within the differing distros. Sharing the users home directory between distros may result in very difficult to identify issues among the different apps due to the config files.
If you were to use a different user name and ensure each user on each distro had a different UID then the difficulties may be mitigated.
In the distant past before modern VM’s my work required access to multiple linux distros. Each distro had a home directory which was kept to the minimum needed, and symbolic links to the mount point of a directory with the rest of my data.
Per @computersavvy comment, I suggest looking for other ways to check your btrfs files systems.
Sorry for any confusion I may have caused on that one!
Good luck sorting out the mess!
Added nvidia
Are we sure this is BTRFS or hardware related? The initial error message was “failed checksum, tainted kernel”.
Maybe it is just a broken nvidia akmod install?
@dontech how did you install the drivers? When did you first install Fedora fresh?
I could also use a different user name to mitigate possible conflicts.
I will opt to keep the home within each partition dedicated to each distribution.
Instead, might it be useful to create a btrfs @home subvolume separate from the @root subvolume?
This could be a viable solution.
For simplicity I think I will opt for a home within the root for each distribution.
Yes, I went by exclusion and the problem is related to csum errors in the Btrfs filesystem.
Installing nvidia akmod drivers are healthy and working properly. The drivers were installed via RPMFusion and I installed Fedora over a year ago on the PC in question.
That error has been there forever but has never been a problem.
In fact, I highlighted the csum problems related to Btrfs.
Rescuezilla uses partclone.btrfs. Search for btrfs in the partclone changelog to see if your version has all the btrfs-related fixes.
Thank you for the suggestion.
Even if I found that some bugs were fixed, I still couldn’t use it because the original partition was deleted and there is only the (apparently damaged) backup of the partition.
During this time, I tried to apply various solutions.
After running the various btrfs repair commands some corruption_errors still remain, but this time they do not increase and the boot problems described in my initial post are gone.
At this point, although the btrfs filesystem having errors can I continue to use the system normally or is it recommended to delete the btrfs partition and reinstall Fedora?
Avoid trying to live with filesystem errors: a) they may create confusion if you have new errors, and b) they may interfere with btrfs maintenance operations. You should be able to use btrfs restore to backup undamaged portions of the filesystem. Then you may be able to repair Fedora or at least take advantage of the Fedora installer ability to preserve an existing /home.
I have already tried using btrfs restore but could not recover an error-free filesystem.
Regarding /home I already have a backup of all the data and configuration folders on another disk, so I would just need to copy them back to the new installation.
At this point I am just left with having to install Fedora from zero.
Regarding this point I have a few questions:
- Is there any way to export a list of packages installed by me and then reinstall them with a few terminal commands?
- Would it be useful to create
@homeand@optsubvolumes from the root volume of Btrfs? - I would like to use the netinstall version of Fedora instead of the live version of Workstation. When selecting DEs and software to install, can I choose between GNOME and Minimal Install? Are there any differences between these options?
Are there also differences between installing from the live version of Fedora Workstation and the netinstall version by choosing Gnome as the DE?
-
Yes.
dnf rq --userinstalled > filename
will give you a file (filename) containing a list of all currently installed packages that were installed by the user.
With a little tweaking (I use sed) that can be stripped from full rpm name including version and arch to just a list of packages, then that list can be used to reinstall all those packages -
Not really beneficial since fedora already creates subvolumes root and home and does not use the @home naming for subvolumes by default. I am not certain why you would consider a subvolume beneficial for /opt.
-
There are noticeable differences between the Workstation install and the netinstall. You have to configure the netinstall to provide what you feel is beneficial, while Workstation contains a standard config that is useful for most users.
A netinstall is minimal and you must add on all the packages (including a DE) that you wish to add.
One consequence if this is that many more people have the standard Workstation config so if (or when) you encounter an issue there will more people able check for the issue on a similar configuration. When I have an issue with Workstation I often find it has already been discovered by others.
-
I run the command you suggested and was able to export the list of packages. Thank you!
Now it is not clear to me how to integrate modification you are talking about (like sed). Can you give me an example of a terminal command?
Then how can I import the package list to install? -
I would like to use the
@homedesignation to make it compatible with Timeshift as well. Or is it better to use Btrfs Assistant?
I think it is advantageous to use a subvolume for/optto avoid reinstalling the programs in that folder as well in case of reinstalling the system again. -
I would like to use netinstall precisely because it is minimal and then I would like to choose which packages to add. Because usually after installing Workstation I end up having to uninstall a lot of packages that I don’t use.
But from the netinstall you can also install the Gnome Workstation version and so I would like to understand if it is the same as the version provided by default.
Surely this is a plus point being the standard version.
However, perhaps the Gnome Workstation version found in the netinstall should also be the same and allow you to uncheck any unwanted packages.
Something like this with the initial package list where each package name is of the form shown
tuned-0:2.23.0-5.fc40.noarch
usbredir-devel-0:0.13.0-4.fc40.x86_64
usbrelay-devel-0:1.2.1-2.fc40.x86_64
vim-X11-2:9.1.571-1.fc40.x86_64
vim-default-editor-2:9.1.571-1.fc40.noarch
vim-enhanced-2:9.1.571-1.fc40.x86_64
virt-install-0:4.1.0-5.fc40.noarch
virt-manager-0:4.1.0-5.fc40.noarch
vlc-1:3.0.21-3.fc40.x86_64
vlc-cli-1:3.0.21-3.fc40.x86_64
vlc-plugin-crystalhd-1:3.0.21-3.fc40.x86_64
w3m-0:0.5.3-63.git20230121.fc40.x86_64
w3m-img-0:0.5.3-63.git20230121.fc40.x86_64
wmctrl-0:1.07-36.fc40.x86_64
wodim-0:1.1.11-54.fc40.x86_64
wsjtx-0:2.7.0-3.fc40.x86_64
xdpyinfo-0:1.3.3-5.fc40.x86_64
xeyes-0:1.3.0-3.fc40.x86_64
xinput-0:1.6.4-2.fc40.x86_64
xrandr-0:1.5.2-5.fc40.x86_64
xsane-0:0.999-50.fc40.x86_64
xsane-common-0:0.999-50.fc40.x86_64
xsane-gimp-0:0.999-50.fc40.x86_64
xvinfo-0:1.1.4-5.fc40.x86_64
xwininfo-0:1.1.5-8.fc40.x86_64
xz-lzma-compat-1:5.4.6-3.fc40.x86_64
zoom-0:6.0.2.4680-1.x86_64
Note that every package has the package name then the version info that begins with something like -0:, -1:, -2:, etc.
The intent is to strip all the version info at the end so you are left with the bare package names.
That content above is a snippet from a file which I named ‘userinstalled-apps’ so to trim the excess info I used something like
cat userinstalled-apps | sed -e "s/-0:..*//g" > trimmed-list
and repeated that for every time there was a remaining version segment in the output ( the -0:, -1:, -2:, etc. that I listed above)
Once my final list was just the package names then reinstalling the packages was simple with a small script.
First update the newly installed system fully sudo dnf upgrade
then install the user added packages.
for FILE in $(cat trimmed-list) ; do sudo dnf install $FILE ; done
You must be certain that all the repos that were previously enabled are enabled before running that script.
Yes, you can (possibly) do the install script without trimming that version number, but it may fail if the version in the repo is different than what was previously installed.
Below is the result of running the sed command once to remove the versions beginning with -0:
vim-default-editor-2:9.1.571-1.fc40.noarch
vim-enhanced-2:9.1.571-1.fc40.x86_64
virt-install
virt-manager
vlc-1:3.0.21-3.fc40.x86_64
vlc-cli-1:3.0.21-3.fc40.x86_64
vlc-plugin-crystalhd-1:3.0.21-3.fc40.x86_64
w3m
w3m-img
wmctrl
wodim
wsjtx
xdpyinfo
xeyes
xinput
xrandr
xsane
xsane-common
xsane-gimp
xvinfo
xwininfo
xz-lzma-compat-1:5.4.6-3.fc40.x86_64
zoom