Bluebird
Posts: 88
Joined: Fri May 16, 2014 9:28 am

Raspberry Pi 4 on SSD

Sun Feb 23, 2020 2:09 pm

Good day,

I am using Raspberry Pi's for lots of years, since Raspberry pi 1 till the new Raspberry pi 4.

The biggest problem having so far is when the raspberry pi has powerloss there is a big chance it won't boot anymore because of corrupted sd card.

I saw a video online to use the Raspberry Pi 4 with an external SSD drive.
I have bought the same gear as the video but i am having a few problems.

The hardware i am using:
* 8gb kinsgston microSD
* Samsung 860 evo 250GB
* Orico 2.5 inch transparent usb3.0

The tutorial i am using is here: https://www.youtube.com/watch?v=gp6XW-fGVjo

I do the exact same steps till giving the SSD another identification number. It stores the new identification number but after changing the cmdline.txt file the pi won't reboot anymore.


After trying it three times i tried another tutorial, this one: https://www.tomshardware.com/news/boot- ... 39782.html
Right now, the SSD is formatting but it takes a really long time. The tutorial says it can take a few minutes but i am already waiting for 2 hours and it still is shows the message:

"Creating journal (262144 blocks): "

Is this normal or am i having some problem?
I connected the SSD (as suggested) to the USB 3 port but i am reading some bugs in there. Is it normal that the formatting takes this long or should i stop it and try a different usb port?

Or can something else be wrong?

Thanks!

User avatar
Roken
Posts: 370
Joined: Sun Dec 31, 2017 4:35 pm
Location: UK

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 3:13 pm

Why do people seem to have so much trouble with this?

If you have your OS on the root directory of the SSD, cmdline.txt looks like:

Code: Select all

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=REPLACEWITHPARTUUID rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait rootdelay=5 fbcon=map:10 fbcon=font:ProFont6x11 logo.nologo
And if you are booting from a remote drive:

Code: Select all

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/nfs nfsroot=SEEBELOW,udp,vers=3 rw ip=dhcp rootfstype=nfs smsc95xx.turbo_mode=N plymouth.enable=0 ip=FIXEDIPIFREQUIRED
SEEBELOW: this is your IP address and mountpoint of the OS to boot. e.g. "192.168.1.100:/mnt/NFS/pi3"

I should clarify, this assumes that the SSD is formatted with ext4
Headless PI. OMG, someone cut it's head off. Oh, hang on. it didn't have one to start with.

ejolson
Posts: 5400
Joined: Tue Mar 18, 2014 11:47 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 3:21 pm

Bluebird wrote:
Sun Feb 23, 2020 2:09 pm
Good day,

I am using Raspberry Pi's for lots of years, since Raspberry pi 1 till the new Raspberry pi 4.

The biggest problem having so far is when the raspberry pi has powerloss there is a big chance it won't boot anymore because of corrupted sd card.

I saw a video online to use the Raspberry Pi 4 with an external SSD drive.
I have bought the same gear as the video but i am having a few problems.

The hardware i am using:
* 8gb kinsgston microSD
* Samsung 860 evo 250GB
* Orico 2.5 inch transparent usb3.0

The tutorial i am using is here: https://www.youtube.com/watch?v=gp6XW-fGVjo

I do the exact same steps till giving the SSD another identification number. It stores the new identification number but after changing the cmdline.txt file the pi won't reboot anymore.


After trying it three times i tried another tutorial, this one: https://www.tomshardware.com/news/boot- ... 39782.html
Right now, the SSD is formatting but it takes a really long time. The tutorial says it can take a few minutes but i am already waiting for 2 hours and it still is shows the message:

"Creating journal (262144 blocks): "

Is this normal or am i having some problem?
I connected the SSD (as suggested) to the USB 3 port but i am reading some bugs in there. Is it normal that the formatting takes this long or should i stop it and try a different usb port?

Or can something else be wrong?

Thanks!
It looks like you have hardware which doesn't properly implement the UAS protocol. That can lead to really slow reads and writes. Information about how to disable UAS mode is at

viewtopic.php?f=28&t=245931

As a temporary measure ou could also try plugging your drive into one of the USB2 ports. If neither of these things solve your problems, I'd check I was using a good power supply and consider running the SSD from an independent power adapter, for example, a powered USB3 hub placed between the Pi and your Samsung SSD.

Bluebird
Posts: 88
Joined: Fri May 16, 2014 9:28 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 3:42 pm

Roken wrote:
Sun Feb 23, 2020 3:13 pm
Why do people seem to have so much trouble with this?

If you have your OS on the root directory of the SSD, cmdline.txt looks like:

Code: Select all

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=REPLACEWITHPARTUUID rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait rootdelay=5 fbcon=map:10 fbcon=font:ProFont6x11 logo.nologo
And if you are booting from a remote drive:

Code: Select all

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/nfs nfsroot=SEEBELOW,udp,vers=3 rw ip=dhcp rootfstype=nfs smsc95xx.turbo_mode=N plymouth.enable=0 ip=FIXEDIPIFREQUIRED
SEEBELOW: this is your IP address and mountpoint of the OS to boot. e.g. "192.168.1.100:/mnt/NFS/pi3"

I should clarify, this assumes that the SSD is formatted with ext4
I followed the tutorial exact, but my cmdline.txt looks like this:

Code: Select all

console=serial0,115200 console=tty1 root=PARTUUID=d34db33f-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh
It was the original content of the cmdline.txt with the partuuid changed.

ejolson wrote:
Sun Feb 23, 2020 3:21 pm
Bluebird wrote:
Sun Feb 23, 2020 2:09 pm
Good day,

I am using Raspberry Pi's for lots of years, since Raspberry pi 1 till the new Raspberry pi 4.

The biggest problem having so far is when the raspberry pi has powerloss there is a big chance it won't boot anymore because of corrupted sd card.

I saw a video online to use the Raspberry Pi 4 with an external SSD drive.
I have bought the same gear as the video but i am having a few problems.

The hardware i am using:
* 8gb kinsgston microSD
* Samsung 860 evo 250GB
* Orico 2.5 inch transparent usb3.0

The tutorial i am using is here: https://www.youtube.com/watch?v=gp6XW-fGVjo

I do the exact same steps till giving the SSD another identification number. It stores the new identification number but after changing the cmdline.txt file the pi won't reboot anymore.


After trying it three times i tried another tutorial, this one: https://www.tomshardware.com/news/boot- ... 39782.html
Right now, the SSD is formatting but it takes a really long time. The tutorial says it can take a few minutes but i am already waiting for 2 hours and it still is shows the message:

"Creating journal (262144 blocks): "

Is this normal or am i having some problem?
I connected the SSD (as suggested) to the USB 3 port but i am reading some bugs in there. Is it normal that the formatting takes this long or should i stop it and try a different usb port?

Or can something else be wrong?

Thanks!
It looks like you have hardware which doesn't properly implement the UAS protocol. That can lead to really slow reads and writes. Information about how to disable UAS mode is at

viewtopic.php?f=28&t=245931

As a temporary measure ou could also try plugging your drive into one of the USB2 ports. If neither of these things solve your problems, I'd check I was using a good power supply and consider running the SSD from an independent power adapter, for example, a powered USB3 hub placed between the Pi and your Samsung SSD.
Oef, i have bought this hardware a few days ago because it is listed as good working device here: https://jamesachambers.com/raspberry-pi ... sh-drives/


I have used the USB 2 port to test it and i see it in the DHCP list with an ip address so i think it boots up, but logging in via ssh gave me the message: "connection refused". I have no idea if i was too quick and maybe it wasn't ready, i unplugged it and now it won't boot, but i think it was my fault.

Would a powered usb hub help or is the adapter not correct? I can return this one and buy another one but i don't know which one to buy because i thought this one would work as well

ejolson
Posts: 5400
Joined: Tue Mar 18, 2014 11:47 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 4:12 pm

Bluebird wrote:
Sun Feb 23, 2020 3:42 pm
Roken wrote:
Sun Feb 23, 2020 3:13 pm
Why do people seem to have so much trouble with this?

If you have your OS on the root directory of the SSD, cmdline.txt looks like:

Code: Select all

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=REPLACEWITHPARTUUID rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait rootdelay=5 fbcon=map:10 fbcon=font:ProFont6x11 logo.nologo
And if you are booting from a remote drive:

Code: Select all

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/nfs nfsroot=SEEBELOW,udp,vers=3 rw ip=dhcp rootfstype=nfs smsc95xx.turbo_mode=N plymouth.enable=0 ip=FIXEDIPIFREQUIRED
SEEBELOW: this is your IP address and mountpoint of the OS to boot. e.g. "192.168.1.100:/mnt/NFS/pi3"

I should clarify, this assumes that the SSD is formatted with ext4
I followed the tutorial exact, but my cmdline.txt looks like this:

Code: Select all

console=serial0,115200 console=tty1 root=PARTUUID=d34db33f-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh
It was the original content of the cmdline.txt with the partuuid changed.

ejolson wrote:
Sun Feb 23, 2020 3:21 pm
Bluebird wrote:
Sun Feb 23, 2020 2:09 pm
Good day,

I am using Raspberry Pi's for lots of years, since Raspberry pi 1 till the new Raspberry pi 4.

The biggest problem having so far is when the raspberry pi has powerloss there is a big chance it won't boot anymore because of corrupted sd card.

I saw a video online to use the Raspberry Pi 4 with an external SSD drive.
I have bought the same gear as the video but i am having a few problems.

The hardware i am using:
* 8gb kinsgston microSD
* Samsung 860 evo 250GB
* Orico 2.5 inch transparent usb3.0

The tutorial i am using is here: https://www.youtube.com/watch?v=gp6XW-fGVjo

I do the exact same steps till giving the SSD another identification number. It stores the new identification number but after changing the cmdline.txt file the pi won't reboot anymore.


After trying it three times i tried another tutorial, this one: https://www.tomshardware.com/news/boot- ... 39782.html
Right now, the SSD is formatting but it takes a really long time. The tutorial says it can take a few minutes but i am already waiting for 2 hours and it still is shows the message:

"Creating journal (262144 blocks): "

Is this normal or am i having some problem?
I connected the SSD (as suggested) to the USB 3 port but i am reading some bugs in there. Is it normal that the formatting takes this long or should i stop it and try a different usb port?

Or can something else be wrong?

Thanks!
It looks like you have hardware which doesn't properly implement the UAS protocol. That can lead to really slow reads and writes. Information about how to disable UAS mode is at

viewtopic.php?f=28&t=245931

As a temporary measure ou could also try plugging your drive into one of the USB2 ports. If neither of these things solve your problems, I'd check I was using a good power supply and consider running the SSD from an independent power adapter, for example, a powered USB3 hub placed between the Pi and your Samsung SSD.
Oef, i have bought this hardware a few days ago because it is listed as good working device here: https://jamesachambers.com/raspberry-pi ... sh-drives/


I have used the USB 2 port to test it and i see it in the DHCP list with an ip address so i think it boots up, but logging in via ssh gave me the message: "connection refused". I have no idea if i was too quick and maybe it wasn't ready, i unplugged it and now it won't boot, but i think it was my fault.

Would a powered usb hub help or is the adapter not correct? I can return this one and buy another one but i don't know which one to buy because i thought this one would work as well
It takes some time at first boot to resize partitions and regenerate the public key encryption. Subsequent boots will be much faster.

I would start the tutorial over and not be so hasty to pull the plug.

As for a UAS capable SATA adapter, try disabling UAS mode first. The speed can be very good without it. Many hardware devices listed as compatible don't even try to support that mode.

Bluebird
Posts: 88
Joined: Fri May 16, 2014 9:28 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 4:15 pm

I am doing that now, the only part i don't quite understand is that i need to put:

Code: Select all

usb-storage.quirks=xxxx:xxxx:u
infront of the /boot/cmdline.txt, but i need to do that on the sd card or on the ssd?

I am not sure but i believe the ssd /boot/cmdline.txt is never used?


I have inserted this and now after rebooting the raspberry pi is visible again in the DHCP table (which wasn't there on my previous tries).
When i want to connect i get the message: "Network error: Connection refused".

Maybe it is because of the resizing of the partitions and regenerate the public key encryption?
I should just wait? At the moment i don't have a Micro HDMI cable so i can't connect a display to it, i am doing everything over ssh (by the way, the adapter normally flashes blue / purple when doing something, now it is solid blue)

ejolson
Posts: 5400
Joined: Tue Mar 18, 2014 11:47 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 4:23 pm

Bluebird wrote:
Sun Feb 23, 2020 4:15 pm
I am doing that now, the only part i don't quite understand is that i need to put:

Code: Select all

usb-storage.quirks=xxxx:xxxx:u
infront of the /boot/cmdline.txt, but i need to do that on the sd card or on the ssd?

I am not sure but i believe the ssd /boot/cmdline.txt is never used?


I have inserted this and now after rebooting the raspberry pi is visible again in the DHCP table (which wasn't there on my previous tries).
When i want to connect i get the message: "Network error: Connection refused".

Maybe it is because of the resizing of the partitions and regenerate the public key encryption?
I should just wait? At the moment i don't have a Micro HDMI cable so i can't connect a display to it, i am doing everything over ssh (by the way, the adapter normally flashes blue / purple when doing something, now it is solid blue)
Put it on the SD Card. Also, have you set up ssh and networking properly?

It would be useful to have a monitor and keyboard attached while debugging this.

Bluebird
Posts: 88
Joined: Fri May 16, 2014 9:28 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 4:58 pm

SSH was working because the first steps where done via ssh.
The strange thing is that after reboot the pi shows up with an ip address, but i can't connect because the "connection refused" error.

I plugged the ssd in my pc again and there was no SSH file anymore (i put it in there for sure).
I put it in there again and rebooted but still the same error.

If i plug the ssd into my pc again, the file is gone again.

I think i am going to buy a cable to debug with a display, this is too difficult without seeing what it does

User avatar
B.Goode
Posts: 10356
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 5:07 pm

Bluebird wrote:
Sun Feb 23, 2020 4:58 pm
SSH was working because the first steps where done via ssh.
The strange thing is that after reboot the pi shows up with an ip address, but i can't connect because the "connection refused" error.

I plugged the ssd in my pc again and there was no SSH file anymore (i put it in there for sure).
I put it in there again and rebooted but still the same error.

If i plug the ssd into my pc again, the file is gone again.

I think i am going to buy a cable to debug with a display, this is too difficult without seeing what it does


From the Raspberry Pi documentation:
For headless setup, SSH can be enabled by placing a file named ssh, without any extension, onto the boot partition of the SD card from another computer. When the Pi boots, it looks for the ssh file. If it is found, SSH is enabled and the file is deleted.
Ref: https://www.raspberrypi.org/documentati ... /README.md

Bluebird
Posts: 88
Joined: Fri May 16, 2014 9:28 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 5:11 pm

Okay, but that means the raspberry pi boots from the ssd (which is great), but i still can't access the pi via ssh

User avatar
B.Goode
Posts: 10356
Joined: Mon Sep 01, 2014 4:03 pm
Location: UK

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 5:18 pm

Bluebird wrote:
Sun Feb 23, 2020 5:11 pm
Okay, but that means the raspberry pi boots from the ssd (which is great), but i still can't access the pi via ssh

From recollection, when I experimented with booting an RPi3b+ from a usb-connected ssd I set up networking while it was still booting from microSD and then migrated that installation to the SSD. And it carried on working.

I can't comment on your situation from actual experience.

Bluebird
Posts: 88
Joined: Fri May 16, 2014 9:28 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 6:09 pm

Hmmz, i have waited a long time but nothing happened anymore. The pi wasn't accessible via SSH. I reconnected the SSH to the USB 2 port and i can connect to the Raspberry Pi straightaway.

With this command:
findmnt -n -o SOURCE /

I get this result:
/dev/sda2

So that means it runs on the SSD now right?
Is my Raspberry Pi faulty?

Bluebird
Posts: 88
Joined: Fri May 16, 2014 9:28 am

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 6:42 pm

Now i am getting crazy, i finished setup with the usb 2 port and it worked well, the benchmark result using sudo curl https://raw.githubusercontent.com/TheRe ... Storage.sh | sudo bash

Score 2874

Because i am using the Samsung 850 evo i expected more but because of the usb 2 port it is that low.

I then tried once again to use the usb 3 port and it booted up... i could login and did the same test again, i am now getting this:

Score 6421


I am not sure if using a powered usb hub would increase this but i think for me this is more than enough.
Thanks for all the help. i think it works great now

renice123
Posts: 198
Joined: Tue Oct 15, 2019 3:56 pm

Re: Raspberry Pi 4 on SSD

Sun Feb 23, 2020 9:17 pm

There are basically two companies that produce relatively inexpensive controllers that are used in devices for connecting SSD via USB 3
ASMedia controllers generally perform better than competitor controllers. Of course, there are also many subtypes of controllers, so you have to watch datasheets before buying.
https://www.asmedia.com.tw/eng/e_show_p ... 2&item=156
That is, you should find a device with a well-functioning controller. Most likely you should just buy a controller from ASMedia on the ASM1351 chip
 (pay attention to the letters after 351 - you need full support for usb 3)
Since I heard about the problem with hubs, controllers, I immediately bought
https://www.startech.com/HDD/Enclosures ... SMS1BMU313
In general, the advice is very simple - first of all, look at the controllers and unfortunately, it is usually the expensive controllers that provide you with speed support.
 

sora03
Posts: 265
Joined: Mon Dec 29, 2014 4:11 pm
Location: Philippines
Contact: Website YouTube

Re: Raspberry Pi 4 on SSD

Tue Feb 25, 2020 2:30 pm

Did you succeed in running raspbian in SSD?

try to execute the following in the pi:

- $ sudo blkid
- sudo cat /boot/cmdline.txt
- $ sudo cat /etc/fstab

paste them here.


In the video Andreas just cloned the pi from the microSD install, but then in the microSD you need to change the partuuid to point to your SSD.
You also need to change fstab PARTUUID to match your SSD's UUID using blkid.
Mastodon: https://mastodon.social/@ssora

Return to “Troubleshooting”