Gentoo Archives: gentoo-user

From: Mark Knecht <markknecht@×××××.com>
To: Gentoo User <gentoo-user@l.g.o>
Subject: Re: [gentoo-user] Weird harddisk problem: AHCI disks sometimes not found
Date: Thu, 11 Mar 2021 19:50:01
Message-Id: CAK2H+eeQtfg4tY3BQtn3V62aagJ9qdF25mqnH-WyHK1LrDDo+Q@mail.gmail.com
In Reply to: [gentoo-user] Weird harddisk problem: AHCI disks sometimes not found by Alexander Puchmayr
1 On Thu, Mar 11, 2021 at 12:39 PM Alexander Puchmayr <
2 alexander.puchmayr@×××××××.at> wrote:
3 >
4 > Hi there,
5 >
6 > I have a weird harddisk detection problem which rises the questio: what
7 does
8 > the gentoo-kernel make differently than the ubuntu kernel?
9 >
10 > The system in question has 2 identical SSDs (Kingston SV300S3 60GB) and
11 two
12 > identical HDDs (older Maxtor7V300F0 300GB) , all connected to SATA/AHCI
13 ports;
14 > the HDDs are combined to a LVM-raid1 volume. SATA controller is a onboard
15 SB7x
16 > on an Asus M3A78 mainboard in AHCI mode.
17 >
18 > Only one of the two SSDs is attached at the same time to the system, the
19 other
20 > one is disconnected. One contains a gentoo installation (just updated
21 > yesterday), the other one an Ubuntu LTS 20.04. This allows dual-.boot by
22 > switching connection cables.
23 >
24 > When I connect the gentoo-SSD and boot it, BIOS finds all HDDs and the
25 SSD, and
26 > starts booting; but gentoo does not recognize at least one of the HDDs
27 (/dev/
28 > sdc missing, dmesg shows link down on Sata-Interface
29 > . Going back to the bios shows that even BIOS does not recognize the disk
30 > anymore. A full powercycle (pressing reset button is not sufficent) to
31 make BIOS
32 > to recognize the disks again.
33 >
34 > Doing the same with the Ubuntu-Disk works absolutely fine, all HDDs are
35 > recognized and the raid is working fine, not a single time that one of the
36 > disks was not recognized.
37 >
38 > Without the Ubuntu observation I'd say its a hardware problem and the old
39 HDDs
40 > are simply beyond their age, but why are they working in ubuntu and not in
41 > gentoo? And what is it doing with BIOS/Harddisk that even Bios does not
42 find it
43 > anymore? I need a full powercycle to make bios find it again. This
44 indicates a
45 > gentoo kernel problem, and I have no idea where to start looking, and
46 AFAIK
47 > there's nothing much to configure a SATA/AHCI drive.
48 >
49 > Any ideas?
50 >
51 > Thanks
52 > Alex
53 >
54 > PS:
55 > Sys-kernel/gentoo-kernel-5.4.97, default configuration
56 > Hardware:
57 > 00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] RS780 Host Bridge
58 > 00:01.0 PCI bridge: Advanced Micro Devices, Inc. [AMD] RS780/RS880 PCI to
59 PCI
60 > bridge (int gfx)
61 > 00:06.0 PCI bridge: Advanced Micro Devices, Inc. [AMD] RS780 PCI to PCI
62 bridge
63 > (PCIE port 2)
64 > 00:11.0 SATA controller: Advanced Micro Devices, Inc. [AMD/ATI]
65 SB7x0/SB8x0/
66 > SB9x0 SATA Controller [AHCI mode]
67 > 00:12.0 USB controller: Advanced Micro Devices, Inc. [AMD/ATI]
68 SB7x0/SB8x0/
69 > SB9x0 USB OHCI0 Controller
70 > 00:12.1 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0 USB
71 OHCI1
72 > Controller
73 > 00:12.2 USB controller: Advanced Micro Devices, Inc. [AMD/ATI]
74 SB7x0/SB8x0/
75 > SB9x0 USB EHCI Controller
76 > 00:13.0 USB controller: Advanced Micro Devices, Inc. [AMD/ATI]
77 SB7x0/SB8x0/
78 > SB9x0 USB OHCI0 Controller
79 > 00:13.1 USB controller: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0 USB
80 OHCI1
81 > Controller
82 > 00:13.2 USB controller: Advanced Micro Devices, Inc. [AMD/ATI]
83 SB7x0/SB8x0/
84 > SB9x0 USB EHCI Controller
85 > 00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD/ATI] SBx00 SMBus
86 Controller
87 > (rev 3a)
88 > 00:14.1 IDE interface: Advanced Micro Devices, Inc. [AMD/ATI] SB7x0/SB8x0/
89 > SB9x0 IDE Controller
90 > 00:14.2 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] SBx00 Azalia
91 > (Intel HDA)
92 > 00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD/ATI]
93 SB7x0/SB8x0/SB9x0
94 > LPC host controller
95 > 00:14.4 PCI bridge: Advanced Micro Devices, Inc. [AMD/ATI] SBx00 PCI to
96 PCI
97 > Bridge
98 > 00:14.5 USB controller: Advanced Micro Devices, Inc. [AMD/ATI]
99 SB7x0/SB8x0/
100 > SB9x0 USB OHCI2 Controller
101 > 00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] K8
102 [Athlon64/Opteron]
103 > HyperTransport Technology Configuration
104 > 00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] K8
105 [Athlon64/Opteron]
106 > Address Map
107 > 00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] K8
108 [Athlon64/Opteron]
109 > DRAM Controller
110 > 00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] K8
111 [Athlon64/Opteron]
112 > Miscellaneous Control
113 > 01:05.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI]
114 > RS780 [Radeon HD 3200]
115 > 01:05.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] RS780 HDMI
116 Audio
117 > [Radeon 3000/3100 / HD 3200/3300]
118 > 02:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd.
119 RTL8111/8168/8411
120 > PCI Express Gigabit Ethernet Controller (rev 02)
121 >
122 >
123 >
124
125 I'm going to assume that you built your Gentoo kernel and have the config
126 file.
127
128 Ubuntu ships the config file along with whatever kernel you are running
129 which you can obtain with
130
131 less /boot/config-$(uname -r)
132
133 Ubuntu 'tends' to ship everything as a module and ships nearly every
134 module vs your Gentoo kernel where you may be building things into
135 the kernel. You should be able to do a diff on the two config files as
136 a starting point assuming you are using the same kernel version.
137
138 lsmod should give you an idea what modules are loaded for each kernel.
139
140 HTH,
141 Mark