0

I have /dev/sdc where are rescued data from VG vg_data. I need convert /dev/sdc to LVM with this data. Is it possible?

Edit1: - I formatted /dev/VG_DATA/data from xfs to ext4 - Copied from sdc1 to LVM data (I thinked)

After I run rsync from sdc1 to data lvm i got errors and /dev/sdb1 (lvm data) is gone to offline.

> 79.497864] sd 1:0:1:0: rejecting I/O to offline device [   79.497891] Aborting journal on device dm-2-8. [   79.497895] sd 1:0:1:0:
> rejecting I/O to offline device [   79.497899] JBD2: Error -5 detected
> when updating journal superblock for dm-2-8. [   79.497916] sd
> 1:0:1:0: rejecting I/O to offline device [   79.497953] sd 1:0:1:0:
> rejecting I/O to offline device [   79.497970] EXT4-fs error (device
> dm-2): ext4_journal_check_start:56: Detected aborted journal [  
> 79.497983] sd 1:0:1:0: rejecting I/O to offline device [   79.498154] sd 1:0:1:0: rejecting I/O to offline device [   79.498169] sd 1:0:1:0:
> rejecting I/O to offline device [   79.498192] sd 1:0:1:0: rejecting
> I/O to offline device [   79.498203] sd 1:0:1:0: rejecting I/O to
> offline device

What is wrong with volume group? It is virtual mach. on hyper-v 08 r2

Edit 2 - from boot log

Sep 17 17:01:23 localhost lvm: 1 logical volume(s) in volume group "VG_DATA" now active
Sep 17 17:01:23 localhost systemd: Found device /dev/mapper/VG_DATA-data.
Sep 17 17:01:23 localhost systemd: Started LVM2 PV scan on device 8:17.
Sep 17 17:01:23 localhost systemd: Mounting /data...
Sep 17 17:01:23 localhost kernel: XFS (sda1): Ending clean mount
Sep 17 17:01:23 localhost systemd: Mounted /boot.
Sep 17 17:01:23 localhost kernel: EXT4-fs (dm-2): recovery complete
Sep 17 17:01:23 localhost kernel: EXT4-fs (dm-2): mounted filesystem with ordered data mode. Opts: (null)
Sep 17 17:01:23 localhost systemd: Mounted /data.
Pavel
  • 417
  • 1
  • 7
  • 17
  • Hard to tell from the information given, but it looks like it fails mid-transfer with an offline device? This wouldn't be the first time I've seen devices drop from hyper-v 2008R2. Many people generally advise to not use this (and instead use 2012*) for this reason. How is this disk attached to the system? Directly, or with a virtual disk file? Also, what is the controller / disk emulation you are using for the VM? – Spooler Sep 18 '16 at 00:34
  • It's 2TB vmdk connected via IDE or SCSI (tried both) virt. controller. Phys. disks are 5x 7.2k in HP Smartarray with Raid5. – Pavel Sep 18 '16 at 10:17

1 Answers1

0

Make a backup, especially if this is your only copy of this data.

Scan your disks for this PV then activate the VGs it contains. You do need all the PVs for this to work, although there might only be the one.

vgscan vgchange -ay

Mount the LVs whose devices appear under /dev/vg_data/*

See your distro's documentation, such as Red Hat's Logical Volume Manager Administration manual.

John Mahowald
  • 32,050
  • 2
  • 19
  • 34