NEWS
RasPi4B bootet von USB-Stick aber nicht von SSD
-
Nachdem ich den USB-Stick mittels rpi-clone auf eine Kexin Model:X1pro 500GB SSD gebracht habe bootete der RasPi damit nicht mehr. Das Clonen mittels Balena, Aomai oder Easeus wurde wegen wegen unterschiedlicher Sektorlänge verweigert. Mittels Clonezilla neuerlich geclont das gleiche Ergebnis; kein booten. Nach dem Einschalten kurzes Flacken der grünen LED dann Dauerlicht. Eine Neuinstallation mittels Pi-Imager direkt auf die SSD läuft problemlos durch, aber trotzdem danach kein Booten. Weder mit Bookworm noch Bullseye 32bit. Bootloader ist auf Stand und bootorder ist eingestellt.
Auf dem Stick sind iobroker mit Redis, InfluxDB und Grafana sowie pi-hole und pivpn installiert und laufen ohne Probleme.Mit USB-Stick und SSD angesteckt sieht fdisk -l so aus:
pi@pivpn:~ $ sudo fdisk -l Disk /dev/ram0: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram1: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram2: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram3: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram4: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram5: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram6: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram7: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram8: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram9: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram10: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram11: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram12: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram13: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram14: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/ram15: 4 MiB, 4194304 bytes, 8192 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 Disk /dev/sda: 476.71 GiB, 511864471552 bytes, 124966912 sectors Disk model: Tech Units: sectors of 1 * 4096 = 4096 bytes Sector size (logical/physical): 4096 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 268431360 bytes Disklabel type: dos Disk identifier: 0xc5bc36ce Device Boot Start End Sectors Size Id Type /dev/sda1 8192 532479 524288 2G c W95 FAT32 (LBA) /dev/sda2 532480 3850239 3317760 12.7G 83 Linux Disk /dev/sdb: 57.28 GiB, 61505273856 bytes, 120127488 sectors Disk model: SanDisk 3.2Gen1 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: 0xbd727156 Device Boot Start End Sectors Size Id Type /dev/sdb1 8192 532479 524288 256M c W95 FAT32 (LBA) /dev/sdb2 532480 62333951 61801472 29.5G 83 Linux pi@pivpn:~ $
Ich habe alle Foren abgesucht aber keinen passenden Hinweis gefunden wie das zu lösen wäre. Warum bootet er nicht einmal nach einer Neusinstallation? Kann die Sektorlänge damit etwas zu tun haben? Auf meinem Heimsystem läuft eine 120GB SSD ohne Probleme. Die hat aber wie ich eben nachgesehen habe 512 byte Sektoren
-
@maximinus sagte in RasPi4B bootet von USB-Stick aber nicht von SSD:
mittels rpi-clone
incl. der ID des Sticks?
Clonen ist nie eine gute Idee!
-
@maximinus said in RasPi4B bootet von USB-Stick aber nicht von SSD:
https://forums.raspberrypi.com/viewtopic.php?t=334314
mit hdparm könnte man ggfs auch die logische Sektorgröße auf 512 bekommen ...
hdparm --set-sector-size 512 --please-destroy-my-drive /dev/sdX
https://unix.stackexchange.com/questions/606072/change-logical-sector-size-to-4k
Nachtrag - das finde ich merkwürdig:
Disk model: Tech
-
Bin mir nicht sicher was das bedeutet:
pi@pivpn:~ $ sudo hdparm -I /dev/sda /dev/sda: ATA device, with non-removable media Standards: Likely used: 1 Configuration: Logical max current cylinders 0 0 heads 0 0 sectors/track 0 0 -- Logical/Physical Sector size: 512 bytes device size with M = 1024*1024: 0 MBytes device size with M = 1000*1000: 0 MBytes cache/buffer size = unknown Capabilities: IORDY not likely Cannot perform double-word IO R/W multiple sector transfer: not supported DMA: not supported PIO: pio0 pi@pivpn:~ $
das sieht nach 512 bytes aus. Kann man hdparm auf SSDs anwenden?
-
Hab mir nichts dabei gedacht weil das mit der 120GB SSD so problemlos funktioniert hat.
Ich weiß nicht ob das geht und wie kompliziert das sein mag. Könnte man weiterhin mit dem USB Stick nur booten und alles andere auf die SSD so wie sie ist verlagern? Wenn ja, wie?
LG Gerhard
-
@maximinus Sieht irgendwie nicht nach einer normalen SSD aus - oder die USB zu M.2 Bridge ist nicht das Gelbe vom Ei ...
Ich hab ne SATA-SSD in meinem Mini-PC, direkt am SATA Port ...
Sehr geschwätzig ... und da passt auch alles zusammen ..
root@pve:~# hdparm -I /dev/sda /dev/sda: ATA device, with non-removable media Model Number: CT480BX500SSD1 Serial Number: 2248E68B04B2 Firmware Revision: M6CR056 Media Serial Num: Media Manufacturer: Transport: Serial, ATA8-AST, SATA 1.0a, SATA II Extensions, SATA Rev 2.5, SATA Rev 2.6, SATA Rev 3.0 Standards: Used: unknown (minor revision code 0x011b) Supported: 10 9 8 7 6 5 Likely used: 10 Configuration: Logical max current cylinders 16383 16383 heads 16 16 sectors/track 63 63 -- CHS current addressable sectors: 16514064 LBA user addressable sectors: 268435455 LBA48 user addressable sectors: 937703088 Logical Sector size: 512 bytes Physical Sector size: 512 bytes Logical Sector-0 offset: 0 bytes device size with M = 1024*1024: 457862 MBytes device size with M = 1000*1000: 480103 MBytes (480 GB) cache/buffer size = unknown Form Factor: 2.5 inch Nominal Media Rotation Rate: Solid State Device Capabilities: LBA, IORDY(can be disabled) Queue depth: 32 Standby timer values: spec'd by Standard, no device specific minimum R/W multiple sector transfer: Max = 1 Current = 1 DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6 Cycle time: min=120ns recommended=120ns PIO: pio0 pio1 pio2 pio3 pio4 Cycle time: no flow control=120ns IORDY flow control=120ns Commands/features: Enabled Supported: * SMART feature set Security Mode feature set * Power Management feature set * Write cache * Look-ahead * WRITE_BUFFER command * READ_BUFFER command * NOP cmd * DOWNLOAD_MICROCODE * 48-bit Address feature set * Mandatory FLUSH_CACHE * FLUSH_CACHE_EXT * SMART self-test * General Purpose Logging feature set * WRITE_{DMA|MULTIPLE}_FUA_EXT * 64-bit World wide name * {READ,WRITE}_DMA_EXT_GPL commands * Segmented DOWNLOAD_MICROCODE * Gen1 signaling speed (1.5Gb/s) * Gen2 signaling speed (3.0Gb/s) * Gen3 signaling speed (6.0Gb/s) * Native Command Queueing (NCQ) * Phy event counters * READ_LOG_DMA_EXT equivalent to READ_LOG_EXT * DMA Setup Auto-Activate optimization * Device-initiated interface power management * Software settings preservation Device Sleep (DEVSLP) * SANITIZE feature set * BLOCK_ERASE_EXT command * DOWNLOAD MICROCODE DMA command * WRITE BUFFER DMA command * READ BUFFER DMA command * Data Set Management TRIM supported (limit 8 blocks) Security: Master password revision code = 65534 supported not enabled not locked frozen not expired: security count supported: enhanced erase 6min for SECURITY ERASE UNIT. 6min for ENHANCED SECURITY ERASE UNIT. Logical Unit WWN Device Identifier: 500a0751e68b04b2 NAA : 5 IEEE OUI : 00a075 Unique ID : 1e68b04b2 Device Sleep: DEVSLP Exit Timeout (DETO): 90 ms (drive) Minimum DEVSLP Assertion Time (MDAT): 26 ms (drive) Checksum: correct root@pve:~#
-
Das is so eine kompakte kleine schwarze die man nicht zerstörungsfrei zerlegen kann. habe nachdem das mit der Sektorgrösse erkannt war da gefunden:
Conclusion: if you want to boot Pi 4 from a SATA SSD, get an adapter with the ASM1153 chip, not the JMS567 chip.pi@pivpn:~ $ sudo lsusb Bus 002 Device 002: ID 0781:5591 SanDisk Corp. Ultra Flair Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub Bus 001 Device 003: ID 152d:0562 JMicron Technology Corp. / JMicron USA Technology Corp. JMS567 SATA 6Gb/s bridge Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub pi@pivpn:~ $
Jetzt bin ich mir nicht sicher ob ich das mit hdparm überhaupt versuchen soll. Vielleicht ist sie dann ja ganz unbrauchbar.
Danke jedenfalls für den Hinweis