1

I wrote the Raspbian Stretch image with Desktop to my USB HDD using Win32 Disk Imager. I resized partition 2 using sudo fdisk /dev/sda (my usb drive) by deleting the partition and recreating it with the same start and a new end (the default one of fdisk) on my Pi 3 that has Jessie installed.

After rebooting I expanded the filesystem of partition 2 by executing sudo resize2fs /dev/sda2. df -h showed that everything went right. I deleted all partitions on a 4GB SD card, created a new "W95 FAT32 (LBA)" partition (both steps using fdisk), created a new vfat filesystem (sudo mkfs.vfat -F 32 /dev/sda1, my HDD wasn't attached) and copied the files from the HDD's boot partition to my SD card.

I changed the cmdline.txt's root option on my SD card to root=/dev/sda2. So my cmdline.txt now looks like that:

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/sda2 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh splash plymouth.ignore-serial-consoles

After trying to boot from the SD card with the HDD attached the Raspberry Pi logos at the top of the screen appear and after about 14 seconds when the HDD is ready those messages are printed:

[     xxx.xxx] sd 1:0:0:0: [sda] No Caching mode page found
[     xxx.xxx] sd 1:0:0:0: [sda] Assuming drive cache: write through

They are also printed when executing dmesg on Jessie.
After these messages the Pi reboots, again showing the rainbow screen, and everything starts again.

I don't want to boot from USB by setting an OTP-bit because I still want to be able to boot from SD card.

Is it possible that my HDD spins up to slow (14 seconds are quite a bit)?

0

If you don't set the bit in OTP you can't boot from an external drive. The Raspberry is simply hardwired to search for the boot partition on the SD card. You can move the root partition to the external drive as you've already found out. I believe the reboot loop is a different problem. Did you connect the external drive directly to the Raspberry? If yes then you need to connect it through a powered USB hub. The external drive probably draws too much power during powering up thereby depriving the Raspberry itself of power causing it to reboot.

  • Yes, I connected my drive directly which always works well when I use my Pi with Raspbian Jessie only on an SD card. It didn't work with my Pi 2 but since the Pi 3 everything is alright. – user78403 Jan 9 '18 at 10:00
  • The Pi 3 has a better powersupply than the Pi 2 that's why it works with the Pi 3. – wie5Ooma Jan 9 '18 at 16:29
  • Do you know what else could cause the reboot? – user78403 Jan 9 '18 at 16:46
  • Power problems are the main cause of reboots. Since it works with the new Pi you can rule out any other cause. – wie5Ooma Jan 9 '18 at 16:53
  • 1
    OTP switching will still prioritise SD over USB, if an SD is present. It doesn't only bit from USB after the switch. – Andy Anderson May 9 '18 at 16:45
0

Can your raspberry Pi support the Hard drive (powering it)? Try booting the Pi without changing any partitions after burning the raspbian image to the HDD.

BTW the OTP bit does not mean you can't boot from an SD card again.

Anyways why do you need the 4 GB SD card? Why not boot everything from the HDD? Make sure you have an adequate power supply and cables, thin cables might create problems.

  • Whoops... Did not see that this post was this old. Sorry if i bumped it! – The Royal Noob Aug 17 '18 at 20:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.