Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Copy a ATA (IDE) disk to a SATA using DD ?
View unanswered posts
View posts from last 24 hours

Goto page Previous  1, 2  
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54322
Location: 56N 3W

PostPosted: Sat Oct 29, 2022 1:27 pm    Post subject: Reply with quote

destroyedlolo,

Code:
device 8:4
That's /dev/sda4 is that correct?
The kernel will expect to find /sbin/init there. Is it?

Lets assume for testing that the boot proceeds normally but you just can't see it.
If that correct, can you ssh into the system and look around?
The dmesg will be useful if you can get it.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
destroyedlolo
l33t
l33t


Joined: 17 Jun 2011
Posts: 846
Location: Close to Annecy (France)

PostPosted: Sat Oct 29, 2022 1:51 pm    Post subject: Reply with quote

Yes it is.
The partitionning as shown above is :
  • sda1 : Bios boot
  • sda2 : /boot
  • sda3 : swap
  • sda4 : /


Quote:
The kernel will expect to find /sbin/init there. Is it?

Yes, without it, I got : "no init found" (or something like that).

Quote:
Lets assume for testing that the boot proceeds normally but you just can't see it.
If that correct, can you ssh into the system and look around?

Unfortunately it didn't : the network is not initialized and can't see it on my network.

I edited the previous messages with test I did :
Quote:
with "noapic" or clocksource=hpet, it hangs at "random: nonblocking pool ...

The same kernel is working on the original machine : the only difference is the hard disk :evil:
End especially the "new" system doesn't have IDE disk attached. on the IDE bus, only the DVDROM is here ...


It's an IBM ThinkCenter with was always problematic : on the one that is working, I uevent takes age to proceed.
I can provide the dmesg of the orginale machine if it can be helpful.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54322
Location: 56N 3W

PostPosted: Sat Oct 29, 2022 2:21 pm    Post subject: Reply with quote

destroyedlolo,

Lets start at the beginning and do some analysis.

Rule 1 - assume nothing. That's hard.

Post the output of
Code:
lspci -nnk

Tell us how your old and new HDD are connected. To what sort of electrical interface?
It sounds like you have both PATA and SATA available.

Put your current (non booting) kernel .config file onto a pastebin.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
destroyedlolo
l33t
l33t


Joined: 17 Jun 2011
Posts: 846
Location: Close to Annecy (France)

PostPosted: Sun Oct 30, 2022 8:08 pm    Post subject: Reply with quote

NeddySeagoon wrote:

Post the output of
Code:
lspci -nnk


Code:
00:00.0 Host bridge [0600]: Intel Corporation 82865G/PE/P DRAM Controller/Host-Hub Interface [8086:2570] (rev 02)
   Subsystem: Intel Corporation 82865G/PE/P DRAM Controller/Host-Hub Interface [8086:2570]
   Kernel driver in use: agpgart-intel
00:02.0 VGA compatible controller [0300]: Intel Corporation 82865G Integrated Graphics Controller [8086:2572] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: i915
00:06.0 System peripheral [0880]: Intel Corporation 82865G/PE/P Processor to I/O Memory Interface [8086:2576] (rev 02)
00:1d.0 USB controller [0c03]: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #1 [8086:24d2] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: uhci_hcd
00:1d.1 USB controller [0c03]: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #2 [8086:24d4] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: uhci_hcd
00:1d.2 USB controller [0c03]: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #3 [8086:24d7] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: uhci_hcd
00:1d.3 USB controller [0c03]: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB UHCI Controller #4 [8086:24de] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: uhci_hcd
00:1d.7 USB controller [0c03]: Intel Corporation 82801EB/ER (ICH5/ICH5R) USB2 EHCI Controller [8086:24dd] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: ehci-pci
00:1e.0 PCI bridge [0604]: Intel Corporation 82801 PCI Bridge [8086:244e] (rev c2)
00:1f.0 ISA bridge [0601]: Intel Corporation 82801EB/ER (ICH5/ICH5R) LPC Interface Bridge [8086:24d0] (rev 02)
   Kernel modules: intel_rng
00:1f.1 IDE interface [0101]: Intel Corporation 82801EB/ER (ICH5/ICH5R) IDE Controller [8086:24db] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: ata_piix
00:1f.3 SMBus [0c05]: Intel Corporation 82801EB/ER (ICH5/ICH5R) SMBus Controller [8086:24d3] (rev 02)
   Subsystem: IBM Device [1014:0287]
00:1f.5 Multimedia audio controller [0401]: Intel Corporation 82801EB/ER (ICH5/ICH5R) AC'97 Audio Controller [8086:24d5] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: snd_intel8x0
03:08.0 Ethernet controller [0200]: Intel Corporation 82562EZ 10/100 Ethernet Controller [8086:1050] (rev 02)
   Subsystem: IBM Device [1014:0287]
   Kernel driver in use: e100


NeddySeagoon wrote:

Tell us how your old and new HDD are connected. To what sort of electrical interface?
It sounds like you have both PATA and SATA available.

Yes, they got PATA and SATA interface.
On the original system, system 'old' disk is the primary on the PATA, secondary is a DVD-ROM.
Then, the 'new' disk is put on the SATA controler, working w/o trouble (didn't test to boot).

On the "new" system :
The "new" disk is put on the SATA controler and is the only SATA device.
I tested with and without the PATA DVD-ROM which is alone on the PATA.


NeddySeagoon wrote:
Put your current (non booting) kernel .config file onto a pastebin.


https://pastebin.com/Fdx2T8F4

Notez-bien : this kernel is perfectly working on the old system (it's the one is booting now).

Thanks
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54322
Location: 56N 3W

PostPosted: Mon Oct 31, 2022 7:34 pm    Post subject: Reply with quote

destroyedlolo,

Check the BIOS settinigs of both systems in the area of the HDD controller options.

Try booting the new drive in the old system.

What size does the BIOS (in both systems) report the new HDD as?
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
destroyedlolo
l33t
l33t


Joined: 17 Jun 2011
Posts: 846
Location: Close to Annecy (France)

PostPosted: Tue Nov 01, 2022 4:01 pm    Post subject: Reply with quote

Hello,

NeddySeagoon wrote:

Check the BIOS settinigs of both systems in the area of the HDD controller options.

Done, they are the sames.

NeddySeagoon wrote:
Try booting the new drive in the old system.

Hanging at the same step :evil:
So, with the same kernel, it wants to boot from IDE but hangs when booting from SATA.

NeddySeagoon wrote:
What size does the BIOS (in both systems) report the new HDD as?

The disk is identified as 1802Go -Sata2- (but I think it is too old for a 4TB disk) and its model is correctly displayed.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54322
Location: 56N 3W

PostPosted: Tue Nov 01, 2022 7:19 pm    Post subject: Reply with quote

destroyedlolo,

The laptop BIOS is not LBA48 aware. That's not a surprise.
That only means the /boot and all the files needed to boot need to be at the start of the drive so the BIOS can read them.

The kernel, once its loaded, can see the entire HDD.
Some BIOSes refuse to boot with a drive that is too big. To beat that, some HDD had a jumper to make them lie about their real size.
The kernel still saw the real size so everyone was happy.

What is the full model number of your SATA drive?
Code:
smartctl
will tell. Then we can get the data sheet on the drive.

There is another thing.
Share the output of
Code:
fdisk -l -t dos /dev/<old_hdd>
and
Code:
fdisk -l -t dos /dev/<new_hdd>
and
Code:
fdisk -l -t gpt /dev/<new_hdd>

_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
destroyedlolo
l33t
l33t


Joined: 17 Jun 2011
Posts: 846
Location: Close to Annecy (France)

PostPosted: Wed Nov 02, 2022 10:55 am    Post subject: Reply with quote

Hi,

NeddySeagoon wrote:

The kernel, once its loaded, can see the entire HDD.
Some BIOSes refuse to boot with a drive that is too big. To beat that, some HDD had a jumper to make them lie about their real size.
The kernel still saw the real size so everyone was happy.


But we are after this step as the kernel started to boo, right ?


What is the full model number of your SATA drive?
Code:
smartctl
will tell. Then we can get the data sheet on the drive.
Code:
=== START OF INFORMATION SECTION ===
Device Model:     ST4000NE001-2MA101
Serial Number:    WJG03CZP
LU WWN Device Id: 5 000c50 0cc049a16
Firmware Version: EN01
User Capacity:    4,000,787,030,016 bytes [4.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Rotation Rate:    7200 rpm
Form Factor:      3.5 inches
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   Unknown(0x0fe0) (minor revision not indicated)
SATA Version is:  SATA >3.1, 6.0 Gb/s (current: 1.5 Gb/s)
Local Time is:    Wed Nov  2 11:50:50 2022 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled


and for fdisk :
Code:
# fdisk -l -t dos /dev/sda

Disk /dev/sda: 37.3 GiB, 40016019456 bytes, 78156288 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x000c9a57

Device     Boot   Start      End  Sectors   Size Id Type
/dev/sda1  *         63   144584   144522  70.6M 83 Linux
/dev/sda2        144585  1140614   996030 486.4M 82 Linux swap / Solaris
/dev/sda3       1140615 78156224 77015610  36.7G 83 Linux

# fdisk -l -t dos /dev/sdb

Disk /dev/sdb: 3.7 TiB, 4000787030016 bytes, 7814037168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: dos
Disk identifier: 0x00000000

Device     Boot Start        End    Sectors Size Id Type
/dev/sdb1           1 4294967295 4294967295   2T ee GPT

Partition 2 does not start on physical sector boundary.

# fdisk -l -t gpt /dev/sdb

Disk /dev/sdb: 3.7 TiB, 4000787030016 bytes, 7814037168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 22D32028-989D-4A50-B1DD-82C25B000622

Device          Start        End    Sectors  Size Type
/dev/sdb1        2048       4095       2048    1M BIOS boot
/dev/sdb2        4096     147455     143360   70M Linux filesystem
/dev/sdb3      147456    1196031    1048576  512M Linux swap
/dev/sdb4     1196032   43139071   41943040   20G Linux root (x86)
/dev/sdb5    43139072 4338106367 4294967296    2T Linux filesystem
/dev/sdb6  4338106368 7814037134 3475930767  1.6T Linux filesystem
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54322
Location: 56N 3W

PostPosted: Wed Nov 02, 2022 5:10 pm    Post subject: Reply with quote

destroyedlolo,

The data sheet for your drive is huru That's a PDF.
It says noting about any jumpers that i can see.

You old HDD has the bootable flag set.
Code:
Device     Boot   Start      End  Sectors   Size Id Type
/dev/sda1  *         63   144584   144522  70.6M 83 Linux


Run
Code:
fdisk -t dos /dev<nem_drive>
and st the bootable flag there.
I'm sure fdisk will shout at you about you are about to do a very bad thing because GPT is in use.
That's mostly right too.
It this case, as long as you only flip the bootable flag, its safe. This is where your BIOS will look for it at boot time.
It may not care about the bootable flag but we need to try.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
destroyedlolo
l33t
l33t


Joined: 17 Jun 2011
Posts: 846
Location: Close to Annecy (France)

PostPosted: Thu Nov 03, 2022 6:16 pm    Post subject: Reply with quote

It doesn't change anything, but why are U thinking it's bios related ?
I can boot from sda or sdb without trouble using the bios menu and, in both cases, the kernel is loaded : if it was bios issue, it can't load the kernel isn't it ?
Back to top
View user's profile Send private message
destroyedlolo
l33t
l33t


Joined: 17 Jun 2011
Posts: 846
Location: Close to Annecy (France)

PostPosted: Sat Nov 05, 2022 4:08 pm    Post subject: Reply with quote

Hi,

I did another test by building last kernel : 5.15.75-gentoo.

  • is it booting on the old disk (and it's faster as uevent doesn't take age to complete :)
  • but same result with the new disk : hangs at switching TSC :?


I'll do another try using another Linux, TCL.

And if it's not working as well, I have zillion of small IDE disk : I'll use one as system disk. but it's gonna be messy as the enclosure is not built to host 2 disks.
Back to top
View user's profile Send private message
destroyedlolo
l33t
l33t


Joined: 17 Jun 2011
Posts: 846
Location: Close to Annecy (France)

PostPosted: Thu Nov 10, 2022 8:30 pm    Post subject: Reply with quote

Some update.
So I'm able to boot from the 4To disk on this machine from TCL.
So I guess something is wrong with what I've put in the kernel.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Goto page Previous  1, 2
Page 2 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum