[SOLVED] Moving a CentOS 7 HDD from HP DL160 to HP DL360p

General support questions
mathog
Posts: 256
Joined: 2008/07/09 23:52:06

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by mathog » 2021/02/05 23:02:42

VeeDub wrote:
2021/02/05 21:35:45
Trying to move a physical disk from one system to another and then change the boot configuration is risky and has the potential to leave you with a disk that doesn't boot on any system.
Agreed. Always safest to work with a copy.

User avatar
TrevorH
Forum Moderator
Posts: 30314
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by TrevorH » 2021/02/05 23:18:43

The disk was part of a single volume RAID array on a HP Smart Array B110i SATA RAID Controller.
So that's a FakeRAID controller, not a hardware one. The P420i in your new machine is a hardware RAID controller.

Do you still have the old machine and does the old disk still boot if you put it back? If it does then can you check if the hpsa module is part of your initramfs like so: lsinitrd /boot/initramfs-3.10.0-1160-11.1.el7.x86_64.img | grep -i hpsa? Do the same with the initramfs for the rescue kernel (/boot/initramfs-0-rescue*.img) and see if it's present there.

If it is in the rescue initramfs then the driver for that controller is loading and it should be working. Try booting it again and this time, interrupt the boot process at the grub menu when it asks you to select the kernel, scroll down and select the rescue kernel and hit 'e' to edit it and make sure it does not include either 'rhgb' or 'quiet' and remove them if they're there. Now ctrl-x to boot up with the change you just made and take a picture of the screen if it does not boot. If it's not booting the rescue kernel and the initramfs-0-rescue file does have the hpsa module included then perhaps you have to tell the RAID controller to treat that disk as 'JBOD' or 'passthru' or however it styles it. Be aware that that might chage RAID metadata and stop it fro working on the old controller.
CentOS 6 died in November 2020 - migrate to a new version!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

webdbase
Posts: 21
Joined: 2021/01/27 13:00:19

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by webdbase » 2021/02/06 08:29:47

mathog wrote:modprobe hpsa [ hpsa_allow_any=1 ]
I've already tried that, but with no success. I read in a similar forum. There was also an option hpsa.hpsa_simple_mode=1
And each try costs me at least 5 minutes :)
mathog wrote:Looking at your screen shot it says that it is a P420i controller. However, in CentOS 7 "man hpsa" shows supported devices as:
When I initially thought it was a devices driver problem, I checked at HPE's site and it took me here:
https://support.hpe.com/hpesc/public/km ... %20Server]
The page read "This RPM is used to provide binary driver modules that have been pre-built to enable HPE ProLiant Smart Array Px4x and Hx4x series controllers."
There were two RHEL7 rpms - for kernels 3.10.0-1160.el7.x86_64 and 3.10.0-1127.el7.x86_64. So I downloaded both of them and found hpsa.ko in both of them. It's size was one and the same - 185150 bytes. I opened it in Notepad++ and saw that Smart Array P420i was mentioned in it.
A file with that name is to be found in /usr/lib/modules/3.10.0-1127.8.2.el7.x86_64/kernel/drivers/scsi/hpsa.ko.xz. It's unpacked size is 165429 bytes. I opened it in Notepad++ and saw that Smart Array P420i was mentioned in it, too.
I tried to rebuilt the initramfs-3.10.0-1127.8.2.el7.x86_64 with the 165429 bytes one, and I'm sure the driver was in it after that, as I wrote in a previous post. Still nothing.
TrevorH wrote:So that's a FakeRAID controller, not a hardware one
Yes, I know that. I learned it 11 years ago when I was installing Ubuntu on that DL160 server first, and I saw the installer was detecting two disk.
TrevorH wrote:Do you still have the old machine and does the old disk still boot if you put it back?
I still have the old machine and it's running a copy of the original disk. As I mentioned before, I had to replace it because it started to report bad sectors that were not reallocatable. I also have a second copy of the original. Both the original and the second copy are bootable on a standard desktop PC with SATA controller after I have plugged them in DL360p many times. I have not tried on DL160, because I cannot afford such down time, but I'm sure they will.
TrevorH wrote:lsinitrd /boot/initramfs-3.10.0-1160-11.1.el7.x86_64.img | grep -i hpsa? Do the same with the initramfs for the rescue kernel (/boot/initramfs-0-rescue*.img) and see if it's present there.
No, it's not present in any of the initramfs-3.10.0*.img, but it is present in the rescue kernel, which is also not bootable, as I mentioned above?!?
TrevorH wrote:... 'rhgb' or 'quiet' and remove them...
I've tried that too - same thing. The bottom line is "Warning /dev/centos/root does not exist". I'll try it again and post a picture, but it's a long text, will not fit on one screen.

I'm thinking of something else. How come it reads the boot sector, but cannot read /dev/sda1 (/boot) and (/dev/sda2) LVM group. As I wrote in a previous post, if I boot from installation CentOS Minimal CD and choose rescue mod, it fails
Image
But after I press <return> and go to shell, I can manually mount /dev/sda1, where the boot partition is and /dev/sda2 which is the LVM2 part (/home /swap and /root) with exception of /root which complains to be shorter by some number of blocks?
TrevorH wrote:... tell the RAID controller to treat that disk as 'JBOD' or 'passthru' or however it styles it.
I'm not sure there is such an option, but I'll have a look at it.

Everybody, thank you very much for your time!

User avatar
TrevorH
Forum Moderator
Posts: 30314
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by TrevorH » 2021/02/06 12:55:22

You don't need an external copy of the hpsa module. It's already part of the CentOS kernel and the kernel versions you mention are definitely new enough to support the P420. You do not need the HP versions of the thing and installing them will only make things more complex. Avoid.
No, it's not present in any of the initramfs-3.10.0*.img, but it is present in the rescue kernel, which is also not bootable, as I mentioned above?!?
Then you have a different problem. If the rescue kernel doesn't recognise the controller or the drives attached to it then there is something wrong with its setup. The hpsa module is there and will load, if it doesn't find the disk then there is a controller problem.

I'd suggest booting the rescue DVD again and this time, look at the console on ctrl-alt-f3 (4? 5?) for the system logs and then use the root command prompt on ctrl-alt-f2 to modprobe -r hpsa and then modprobe hpsa (i.e unload and reload it) and then check the logs on the original console to see if there are errors.
CentOS 6 died in November 2020 - migrate to a new version!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

webdbase
Posts: 21
Joined: 2021/01/27 13:00:19

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by webdbase » 2021/02/07 17:27:50

I found an image in my phone. I've taken it a week ago. It show the end of the log of the booting process without grub options 'rhgb' and 'quiet' .
Image

webdbase
Posts: 21
Joined: 2021/01/27 13:00:19

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by webdbase » 2021/02/09 12:44:50

TrevorH wrote:
2021/02/06 12:55:22
I'd suggest booting the rescue DVD again and this time, look at the console on ctrl-alt-f3 (4? 5?) for the system logs and then use the root command prompt on ctrl-alt-f2 to modprobe -r hpsa and then modprobe hpsa (i.e unload and reload it) and then check the logs on the original console to see if there are errors.
So here is what I got.

Boot log in install mode
Image

boot log with rescue kernel: modprobe -r hpsa and then modprobe hpsa
Image

The warning about the smaller size of /dev/sda2 bothers me. But it is a warning, not an error?

/dev/mapper folder after modprobe -r hpsa and then modprobe hpsa
Image

User avatar
TrevorH
Forum Moderator
Posts: 30314
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by TrevorH » 2021/02/09 13:30:12

The warning about the smaller size of /dev/sda2 bothers me. But it is a warning, not an error?
Looks like an error to me.
CentOS 6 died in November 2020 - migrate to a new version!
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 is dead, do not use it.
Full time Geek, part time moderator. Use the FAQ Luke

webdbase
Posts: 21
Joined: 2021/01/27 13:00:19

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by webdbase » 2021/02/09 13:45:04

TrevorH wrote:
2021/02/09 13:30:12
The warning about the smaller size of /dev/sda2 bothers me. But it is a warning, not an error?
Looks like an error to me.
But still it boots on a desktop PC with a regular SATA controller.

tunk
Posts: 895
Joined: 2017/02/22 15:08:17

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by tunk » 2021/02/09 20:55:37

... perhaps you have to tell the RAID controller to treat that disk as 'JBOD' or 'passthru' or however it styles it.
Did you try this? (HBA may be another name for 'passthru'.)

webdbase
Posts: 21
Joined: 2021/01/27 13:00:19

Re: Moving a CentOS 7 HDD from HP DL160 to HP DL360p

Post by webdbase » 2021/02/10 10:32:29

tunk wrote:
2021/02/09 20:55:37
... perhaps you have to tell the RAID controller to treat that disk as 'JBOD' or 'passthru' or however it styles it.
Did you try this? (HBA may be another name for 'passthru'.)
This is all I have as RAID configuration
Image
Image
Image
Image

Post Reply

Return to “CentOS 7 - General Support”