Metadata Corruption detected

General support questions
jlrosssc
Posts: 8
Joined: 2024/03/23 14:39:31

Re: Metadata Corruption detected

Post by jlrosssc » 2024/03/25 03:16:02

After the mdadm --assemble command, I get sda1 has no superblock - assembly aborted. What does that mean?

Also a few other questions just for my understanding: When the drives were originally formatted, I think they had 3 partitions, /boot, /swap and /. When I run the mdadm --assemble /dev/md0 /dev/sda(x), how do I know how many partitions to specify.

Also, with the 4 drives with 3 partitions each, do I specify them all under /dev/md0? Would I command mdadm --assemble /dev/md0 /dev/sda1 /dev/sdb1 /dev/sdc1 /dev sdd1 /dev/sda2 /dev/sdb2 /dev/sdc2 /dev/sdd2 /dev/sda3 /dev/sdb3 /dev/sdc3 /dev/sdd3?

User avatar
TrevorH
Site Admin
Posts: 33215
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Metadata Corruption detected

Post by TrevorH » 2024/03/25 10:28:13

Look at the partitions and their sizes. I suspect you may have more than one array and it's likely that each array uses the same numbered partition on each disk - so array 1 uses e.g. /dev/sda1 /dev/sdb1 and possibly partition 1 on other disks as well. For mdadm the sizes of each member of each array is likely to be the same on each disk. You can also tell by using mdadm --examine on each disk partition whether they are mdadm members or not (it errors if they are not). Use that and the Array uuid line from each to find which partitions belong in which arrays.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

jlrosssc
Posts: 8
Joined: 2024/03/23 14:39:31

Re: Metadata Corruption detected

Post by jlrosssc » 2024/04/02 17:22:46

Following up on this. I had 2 hard drives fail and scramble the RAID so I had to reinstall. I also added a USB external hard drive (backup_hd) and am attempting to back up the system to it. I have the following command
sudo rsync -aAXv / --delete --exclude={‘/dev/‘,’/proc/‘,’/sys/‘,’/tmp/‘,’/run/‘,’/mnt/‘,’/media/‘,’/lost+found’, ‘var/lib/bluecherry/recordings/‘, ‘/backup_hd/‘} /backup_hd

When I do this, even though I've told it to exclude several locations like /proc and the /backup_hd itself, it backs them up. I keep having a recursive backup of the backup_hd as well as the /proc/ location. What am I missing in the command to prevent the indicated locations from being included?

Whoever
Posts: 1361
Joined: 2013/09/06 03:12:10

Re: Metadata Corruption detected

Post by Whoever » 2024/04/02 17:47:52

You are missing the "-x" (lowercase) option. Also can be specified as "--one-file-system" .

User avatar
TrevorH
Site Admin
Posts: 33215
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Metadata Corruption detected

Post by TrevorH » 2024/04/02 17:48:32

I don't think that's a valid syntax for --exclude=. Perhaps use --exclude-from=file and put your exclude patterns in that file, one per line.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Whoever
Posts: 1361
Joined: 2013/09/06 03:12:10

Re: Metadata Corruption detected

Post by Whoever » 2024/04/03 00:39:22

TrevorH wrote:
2024/04/02 17:48:32
I don't think that's a valid syntax for --exclude=. Perhaps use --exclude-from=file and put your exclude patterns in that file, one per line.
I suspect that using the "-x" option will eliminate the need for all, or almost all those exclusions.

I usually use multiple "--exclude=" options, such as '--exclude=/media --exclude=/backups_hd'.

User avatar
jlehtone
Posts: 4530
Joined: 2007/12/11 08:17:33
Location: Finland

Re: Metadata Corruption detected

Post by jlehtone » 2024/04/03 06:18:14

Whoever wrote:
2024/04/02 17:47:52
You are missing the "-x" (lowercase) option. Also can be specified as "--one-file-system" .
If the intent is to include other filesystems too, e.g. /home, then "--one-file-system" is not the solution.

How many things are in / that are not any of the {‘/dev/‘,’/proc/‘,’/sys/‘,’/tmp/‘,’/run/‘,’/mnt/‘,’/media/‘,’/lost+found’, ‘/backup_hd/‘}?
Perhaps they would be the shorter list?
--exclude=var/lib/bluecherry/recordings/ /etc /var /home /root /backup_hd/

Or perhaps even store the command(s) as a script file (that you also back up):

Code: Select all

#!/usr/bin/bash
for D in /etc /var /home /root
do
  rsync -aAXivP --stats --delete --exclude=var/lib/bluecherry/recordings/ "${D}/" "/backup_hd/${D}/"
done

Post Reply