LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 03-05-2020, 09:29 AM   #1
hgoles
LQ Newbie
 
Registered: Mar 2020
Posts: 5

Rep: Reputation: Disabled
Moving a non-RAID disk to a server with Hardware RAID Controller


I have a disk with data on it used on a Supermicro server which has no RAID controller, I've put it into an HP server, and I can see the disk and it's containing data but while I'm trying to mount it this errors happen:

Code:
mount: wrong fs type, bad option, bad superblock on /dev/sda1,
       missing codepage or helper program, or other error

       In some cases useful info is found in syslog - try
       dmesg | tail or so.
And using fsck /dev/sda1 leads to an other error indicating the physical disk size is 8KB short:

Code:
e2fsck 1.42.13 (17-May-2015)
The filesystem size (according to the superblock) is 244190390 blocks
The physical size of the device is 244182198 blocks
Either the superblock or the partition table is likely to be corrupt!


It's the output of `hpacucli ctrl all show config detail`

Code:

Smart Array P420i in Slot 0 (Embedded)
   Bus Interface: PCI
   Slot: 0
   Serial Number: 0014380350DA6C0
   Cache Serial Number: PBKUA0BRH8M91T
   RAID 6 (ADG) Status: Enabled
   Controller Status: OK
   Hardware Revision: B
   Firmware Version: 8.00
   Rebuild Priority: Medium
   Expand Priority: Medium
   Surface Scan Delay: 15 secs
   Surface Scan Mode: Idle
   Queue Depth: Automatic
   Monitor and Performance Delay: 60  min
   Elevator Sort: Enabled
   Degraded Performance Optimization: Disabled
   Inconsistency Repair Policy: Disabled
   Wait for Cache Room: Disabled
   Surface Analysis Inconsistency Notification: Disabled
   Post Prompt Timeout: 0 secs
   Cache Board Present: True
   Cache Status: OK
   Cache Ratio: 25% Read / 75% Write
   Drive Write Cache: Disabled
   Total Cache Size: 512 MB
   Total Cache Memory Available: 304 MB
   No-Battery Write Cache: Disabled
   Cache Backup Power Source: Capacitors
   Battery/Capacitor Count: 1
   Battery/Capacitor Status: OK
   SATA NCQ Supported: True
   Spare Activation Mode: Activate on drive failure
   Controller Temperature (C): 80
   Cache Module Temperature (C): 41
   Capacitor Temperature  (C): 33

   Array: A
      Interface Type: SATA
      Unused Space: 0  MB
      Status: OK
      Array Type: Data



      Logical Drive: 1
         Size: 931.5 GB
         Fault Tolerance: 0
         Heads: 255
         Sectors Per Track: 32
         Cylinders: 65535
         Strip Size: 256 KB
         Full Stripe Size: 256 KB
         Status: OK
         Caching:  Enabled
         Unique Identifier: 600508B1001CEA10DE41CCBBC5381E77
         Disk Name: /dev/sda
         Mount Points: None
         Logical Drive Label: AE60E98C0014380350DA6C0CF0F
         Drive Type: Data

      physicaldrive 1I:1:12
         Port: 1I
         Box: 1
         Bay: 12
         Status: OK
         Drive Type: Data Drive
         Interface Type: SATA
         Size: 1 TB
         Rotational Speed: 7200
         Firmware Revision: CC43
         Serial Number:             Z9A2441W
         Model: ATA     ST1000DM003-1SB1
         SATA NCQ Capable: True
         SATA NCQ Enabled: True
         Current Temperature (C): 38
         Maximum Temperature (C): 38
         PHY Count: 1
         PHY Transfer Rate: 6.0Gbps
         Drive Authentication Status: OK
         Carrier Application Version: 11
         Carrier Bootloader Version: 6



   Enclosure SEP (Vendor ID HP, Model Gen8 ServBP 12+2) 378
      Device Number: 378
      Firmware Version: 3.30
      WWID: 50014380355F89B9
      Port: 1I
      Box: 1
      Vendor ID: HP
      Model: Gen8 ServBP 12+2

   Expander 380
      Device Number: 380
      Firmware Version: 3.30
      WWID: 50014380355F89A0
      Port: 1I
      Box: 1
      Vendor ID: HP

   SEP (Vendor ID PMCSIERA, Model SRCv8x6G) 379
      Device Number: 379
      Firmware Version: RevB
      WWID: 50014380350DA6CF
      Vendor ID: PMCSIERA
      Model: SRCv8x6G


Any idea on how to fix this issue? maybe changing a parameter on raid array?
 
Old 03-05-2020, 03:32 PM   #2
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,010

Rep: Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629
Guess the drive or data could be the problem.

Do you have a drive to usb adapter or another older computer to boot to some live media to double check?
 
Old 03-05-2020, 04:12 PM   #3
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,153

Rep: Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265Reputation: 1265
The RAID controller needs to use some of the disk to store metadata and information it would need to do RAID rebuild. When you insert a new disk with no RAID information on it, it will most likely overwrite that area of the disk.
 
Old 03-05-2020, 05:16 PM   #4
uteck
Senior Member
 
Registered: Oct 2003
Location: Elgin,IL,USA
Distribution: Ubuntu based stuff for the most part
Posts: 1,177

Rep: Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501
You can try disabling the hardware raid to enable passthru, https://systemausfall.org/wikis/howt...0Hardware-RAID
I have not tried this, so not sure how it work for you.
 
Old 03-05-2020, 06:43 PM   #5
hgoles
LQ Newbie
 
Registered: Mar 2020
Posts: 5

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by uteck View Post
You can try disabling the hardware raid to enable passthru, https://systemausfall.org/wikis/howt...0Hardware-RAID
I have not tried this, so not sure how it work for you.
HBA mode is not an option because we need raid 1 for other disks, would you please offer other solutions?
 
Old 03-05-2020, 09:58 PM   #6
jefro
Moderator
 
Registered: Mar 2008
Posts: 22,010

Rep: Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629Reputation: 3629
Most hardware raid controllers have the ability to make a jbod or single drive run without raid usually.
 
Old 03-05-2020, 10:32 PM   #7
uteck
Senior Member
 
Registered: Oct 2003
Location: Elgin,IL,USA
Distribution: Ubuntu based stuff for the most part
Posts: 1,177

Rep: Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501Reputation: 501
Are you sure that the disk is mounted at /dev/sda? From the output you posted the disk is named /dev/sda, but no reference to a mount point.
If sda is correct, what does "fdisk -l /dev/sda" report?
 
Old 03-06-2020, 12:36 AM   #8
hgoles
LQ Newbie
 
Registered: Mar 2020
Posts: 5

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by uteck View Post
Are you sure that the disk is mounted at /dev/sda? From the output you posted the disk is named /dev/sda, but no reference to a mount point.
If sda is correct, what does "fdisk -l /dev/sda" report?
No it's not mounted, the issue happens when I want to mount it. but parition table is there and fsck also sees most of file system, the only trouble is 8 KB physical size shortage.
Code:
fdisk -l /dev/sda
Disk /dev/sda: 931.5 GiB, 1000171331584 bytes, 1953459632 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 262144 bytes / 262144 bytes
Disklabel type: dos
Disk identifier: 0xc8200c4b

Device     Boot Start        End    Sectors   Size Id Type
/dev/sda1        2048 1953525167 1953523120 931.5G 83 Linux
 
Old 03-06-2020, 02:33 AM   #9
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,147

Rep: Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124
Have a read of this thread.
 
Old 03-06-2020, 07:33 PM   #10
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,147

Rep: Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124
hgoles, as indicated by your resp[onse in that other thread please mark this as solved ("thread tools" at the top).
 
Old 03-08-2020, 12:20 PM   #11
hgoles
LQ Newbie
 
Registered: Mar 2020
Posts: 5

Original Poster
Rep: Reputation: Disabled
Final work flow:
As i'm writing this post now, G8 servers didn't get firmware update to be able to use mixed mode ( hba + raid ) on p420i

But with help of this amazing guide , I was able to created a padded device and mount the partition without any data loss ( I guess the partition shouldn't be full so last blocks should not contain data )
Code:
let PSIZE=`blockdev --getsz /dev/sda1`
echo -e "0 $PSIZE linear /dev/sdd1 0 \n $PSIZE 100000 zero" | dmsetup create padded
mkdir /a
mount /dev/mapper/padded /a
After making sure that data is fine we can umount and with help of resize2fs decrease the partition size and mount the actual partition instead of padded one, or just continue use padded device while prevent to make the partition be fulled.
Code:
umount /a
e2fsck -f /dev/mapper/padded
resize2fs /dev/mapper/padded ${PSIZE}s
dmsetup remove padded
mount /dev/sda1 /a
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't install RAID created with Windows (and raid controller) on laptop running Linux with no hardware controller rollim01 Linux - Hardware 7 01-14-2020 07:47 PM
Hardware raid vs software raid, is hardware raid portable? MikeyCarter Linux - Hardware 2 01-06-2016 03:30 PM
SCSI controller - Add extra controller & add a disc to the extra controller raj100 Linux - Hardware 1 11-01-2015 11:30 AM
Moving from non-raid to Raid with linux Danathar Linux - General 1 11-01-2005 07:02 PM
RAID controller card override onboard RAID controller? Dr. Psy Linux - Enterprise 1 05-30-2005 10:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 07:30 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration