New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
write_protected_candidate_device called for '/sys/block/nvme0c0n1' but '/dev/nvme0c0n1' is no block device #3085
Comments
@hitrikrtek
? Details: The following excerpt from your
This looks strange because it seems in your case
fails so it seems "nvme0c0n1" is a block device By "googling" for 'nvme0c0n1' I found
which seems to explain the root cause. For comparison: The matching code is in The is_write_protected and write_protected_candidate_device So it seems we have to enhance the |
Hi @jsmeix
|
proves that the root cause is that
so we have to enhance the |
Let the is_write_protected function report candidate devices without device node as not write protected because not all /sys/block devices have a "dev" file e.g. /sys/block/nvme0c0n1 has no /dev/nvme0c0n1 device node see #3085 Because the is_write_protected function is meant to identify write-protected disks and partitions only candidate devices with a device node are considered for write protection
I cannot reproduce your issue So as an offhanded untested workaround for now
with
Perhaps with that you get other errors in other functions Alternatively (and preferred by me if you can) you could test |
Alright! I've grabbed your updated function and am creating a backup now. Will report back the result. |
@hitrikrtek
you should get nothing automatically set for |
Regarding the updated function - this seems to work now, we were able to do restore - but now we're experiencing some other issues after restore our network broke somehow... all disks and configs seem just fine, we're investigating but I don't think it's related to this device. I'll post my finding here, if we figure it out. |
@hitrikrtek |
@hitrikrtek just going over some stuff, a quick question: Your setup has NVMe multipath, correct? I'm asking because https://lore.kernel.org/all/3c725e5deaabaaf145f48f2f6fcfdae9f6d41e2e.camel@suse.de/t/ suggests that the specific I'm asking this because I'm wondering if ReaR actually correctly recognizes NVMe multipath setups as multpath setups, or if it tries to handle them are "regular" disks. Of course, a proper fix would start from access to such a NVMe multpath device... |
@schlomo it is NVMe in RAID1 configuration (two disks, but it is a HW raid controller) so I guess it is multipath yes. We've tried restore also and it works, so it seems the current fix works ok for this configuration. If you want me to send you some more info from the system, just let me know what to send. |
I need more explanatory information Therefore I have some questions: (1) https://lore.kernel.org/all/3c725e5deaabaaf145f48f2f6fcfdae9f6d41e2e.camel@suse.de/t/ (2) As far as I know in traditional multipath with a non-NVMe disk How does this look like with https://lore.kernel.org/all/3c725e5deaabaaf145f48f2f6fcfdae9f6d41e2e.camel@suse.de/t/ (3) As far as I know multipathing is about accessing (4) When "traditional" non-NVMe hardware RAID1 is used When "traditional" non-NVMe software RAID1 is used Here is seems that what is called "NVMe hardware RAID1" |
…ite protected (#3091) In lib/write-protect-functions.sh let the is_write_protected function report candidate devices without device node as not write protected because not all /sys/block devices have a "dev" file e.g. /sys/block/nvme0c0n1 has no /dev/nvme0c0n1 device node see #3085 Because the is_write_protected function is meant to identify write-protected disks and partitions, only candidate devices with a device node are considered for write protection. Additionally completely overhauled lib/write-protect-functions.sh which now contains only the is_write_protected function (the only one intended to be called by other scripts). The former helper functions are not needed as functions because all what happens is a single straightforward sequence of actions.
ReaR version ("/usr/sbin/rear -V"):
Relax-and-Recover 2.7 / 2022-07-13
If your ReaR version is not the current version, explain why you can't upgrade:
Latest version with distribution
OS version ("cat /etc/os-release" or "lsb_release -a" or "cat /etc/rear/os.conf"):
Hardware vendor/product (PC or PowerNV BareMetal or ARM) or VM (KVM guest or PowerVM LPAR):
DELL PowerEdge R860
System architecture (x86 compatible or PPC64/PPC64LE or what exact ARM device):
x86_64
Firmware (BIOS or UEFI or Open Firmware) and bootloader (GRUB or ELILO or Petitboot):
BIOS Version 1.5.6
grub2-x86_64-efi-2.06-150500.29.8.1
Storage (local disk or SSD) and/or SAN (FC or iSCSI or FCoE) and/or multipath (DM or NVMe):
NVMe in RAID configuration
When running rear recover we get this error:
Workaround, if any:
None
Attachments, as applicable ("rear -D mkrescue/mkbackup/recover" debug log files):
rear-srv-lx2013.log
See attached debug log: rear-srv-lx2013.log
The text was updated successfully, but these errors were encountered: