HASS.IO -> transfer from SD card to SSD or USB

Hassbian is being depreciated, Raspbian is supported by the Raspberry Pi foundation, based on the latest version of Debian - 2 separate things.

You can run a Pi with Raspbian, and install HA in venv, HA with docker, or Hass.io.

1 Like

@kanga_who and @DavidFW1960, my apologies.
I did not read the thread in detail as it was not a path I was invested in.
I ā€œassumedā€ it was Hass on Raspbian.

Iā€™ve just made an ā€œassā€ of myself :rofl: (no change there then)

Are there more people who can conform a working setup:

  • Without reboot failures
  • Without the bootfile on SD card trick
  • Using an SSD (which brand / type did you use?)
  • Using an SSD to USB adapter (which brand / type did you use ?)
  • Using a Raspberry Pi 3b+
  • Running HASSIO?

Thanks!

100% working here. Never had a reboot failure. No SD even in the pi. iitrust USB 3.0 to SATA Adapter and SanDisk SSD Plus 240 gb.

Edit: Answering other questions: Hassio and the 3B+

4 Likes

Use a test RPi3 B+ + SSD Latest version HASS.IO

First time boot need the config file fore Wireless, after that install SSH + WebUI and config Wifi:

nmcli radio
nmcli device wifi rescan
nmcli device wifi
nmcli device wifi connect "YOUR_SSID" password "YOUR_WIFI_PASSWORD"

then I can boot from SSD and connected to Wifi without any problem

Now I bought a RPi4 4GB and go test this one with SSD and see if it will work also
maybe different way of config

1 Like

It is possible to run Hassio on PI4 + SSD (boot via SD until RP4 supports USB boot).

  1. Install latest Hassio on PI4 SD card
  2. Setup SSH on port 22222 as explained on the Debugging Hassio dev doc and login
  3. Attach SSD and create a EXT4 file system on it (OPTIONAL MANUAL RESIZE: e2fsck -f /dev/sda1 resize2fs /dev/sda1)
  4. Copy the /mnt/data on SSD eg. dd if=/dev/mmcblk0p8 of=/dev/sda1 bs=4096 conv=notrunc,noerror,sync
  5. Change the partiotion labels
    lsblk -o name,mountpoint,label,size,uuid
    e2label /dev/mmcblk0p8 hassos-data-old
    e2label /dev/sda1 hassos-data
  6. reboot

Should look like this:

ā€˜# lsblk -o name,mountpoint,label,size,uuidā€™

NAME        MOUNTPOINT   LABEL             SIZE UUID
sda                                      223.6G
`-sda1                   hassos-data     223.6G 695900dd-1281-4ae5-8946-aef7f0d03b36
mmcblk0                                   14.9G
|-mmcblk0p1 /mnt/boot    hassos-boot        32M 81C4-9941
|-mmcblk0p2              hassos-kernel      24M f6986d54-5e8f-446a-8b97-76ac90c0edff
|-mmcblk0p3 /                              256M
|-mmcblk0p4                                 24M
|-mmcblk0p5                                256M
|-mmcblk0p6                                  8M
|-mmcblk0p7 /mnt/overlay hassos-overlay     96M 285be7ef-69c3-4052-9091-8b16d5ee5258
`-mmcblk0p8 /mnt/data    hassos-data-old  14.2G 5bc9d413-95a8-45ef-9367-d52516d63670
zram0       [SWAP]       hassos-zramswap 976.1M ac0dbf8f-1fa9-4ffd-9646-91320fec5b82
zram1       /var         hassos-var         32M 309122ca-46e3-4fea-86d7-f2410574ad43
zram2       /tmp         hassos-tmp         16M f657d309-06b5-4ad8-a81e-0545a752ad7b

some more information here if needed:
https://www.gitmemory.com/issue/home-assistant/hassos/164/506053307

3 Likes

migrated my rby pi3b+ sd card on USB disk first, still waiting for my MSATA to arrive. HASSIO 3.7. Now running for 2 weeks without any reboot or crash. This MSATA is very good, used it for 2 years on my video surveillance config.
US $14.64 45%OFF | KingSpec mSATA SSD Solid State Disk SATA III 64gb

1 Like

Ordered the X825 sata board for the pi4 so will try that out once it comes in. Thanks :slight_smile:

@chris669 how do you connect the kingspec msata to your pi 3b+? The expansionboard X850 OR another one? And do you use a certain type of case? PS: could you let us know if this combination works without a bootfile and reboot failures, once you set everything up?

Thanks for that information @DanM!

Must request a ELI5 here (Explain it like iā€™m 5yr)!
How is the OTP bit set so the Rpi3B+ knows how to boot from usb? Does it get written when you upgrade to 0.100.3?
Is the model of ssd of any importande at all? I guess that the sata-adapter is the one that needs to be compliant with the low-leve driver right?
Obviously i havent got it working with my existing usb-casingsā€¦

The 3B+ doesnā€™t need you to set the OTP. Try imaging a USB stick and see if it will boot from that.

1 Like

Oh, that never occured to me that the 3B+ didnā€™t need that setting. Thanks David. Will try a stick to verify. But it seems to be picky on which usb-adapter to use though.

this works perfect!
US $3.07 22%OFF | 6Gbs Converter Adapter Card Mini USB mSATA SSD to USB 3.0 Super Speed Converter SSD Adapter Card


Btw, you can just try by yourself! If it doesnā€™t work, just reboot from your USB.
Again, no, I do not need any SD card anymore for booting. Running HASSOS 3.7

1 Like

Hi All,

Im a happy owner of a RPi4 4GB. And do some tests to let it work with a SSD. I have follow config working now:

Boot from SDcard, Root from SSD. Installed Hass.io on it.

Flash on SD Card Debain Buster Lite Image (in my case on iMac I goto the boot part after flashing)

sudo touch ssh
sudo nano /boot/wpa_supplicant.conf

ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
country=NL

network={
        ssid="SSID"
        psk="PASSWORD"
}

Reboot RPi4 and ssh to it after its done with first normal boot from SDcard.
Iā€™m formatting the SSD on iMac with a FAT Partition then connect it to RPi

sudo mkfs.ext4 /dev/sda1 -L root
sudo mkdir /media/newdrive
sudo mount /dev/sda1 /media/newdrive
sudo rsync -avx --progress / /media/newdrive
sudo nano /boot/cmdline.txt

root=/dev_/sda1 rootfs_type=ext4 root_wait rootdelay=5

reboot now

After reboot I install follow things

sudo -i
apt-get install software-properties-common -y
apt-get update
apt-get install apparmor-utils apt-transport-https avahi-daemon ca-certificates curl dbus jq socat
curl -fsSL get.docker.com | sh

curl -sL "https://raw.githubusercontent.com/home-assistant/hassio-installer/master/hassio_install.sh" | bash -s -- -m raspberrypi4

What I do now is rsync the root folder to the old root folder on SDcard.
When Hassio crash for some reason I only have to change the codline.txt and but back the original root= and boot.

:smiley:

3 Likes

Hi. Iā€™m trying to migrate my Hassio installation from SD to ssd. I have a raspberry pi 3B+, running Hassio 0.103.5. I restored a backup to a USB key and to a ssd connected by a usb-sata adapter. I downloaded bootcode.bin file and put it on SD card. When I try to boot, it doesnā€™t start. On screen I see ā€œ**No partition table - mmc 0 **ā€. What can I try? Thanks

Edit: Ok, fixed, obviously my fault. I was still on HassOs 2.11, after updating it, USB boot worked. No sd card with bootload.bin file needed.

Just curious is Hass.io getting update include Raspberry 4 ssd boot any time soon? I think i wait that time that feature is included hass.io installer after that buy that cheapest raspberry 4 and attack my old intel 80gb ssd that and finally not need to thing how long memory card last this time :slight_smile:

Imho, of sd card life is a driving concern, pi3 is the way to go for now. As said before, hass pi4 USB boot workarounds are not an appetizing project for devs, and (like pi3 when it first released) pi4 will get proper usb boot firmware soon enough. I feel that Pi4 ha is best left for the devs at this timeā€¦ by that I donā€™t mean everyone go buy a pi4 now and start bugging devs for usb boot, lol!

I boot firs part from SDCard. But rest is on a SSD card (ROOT). Run smooth for me on RPi4!!
I rsync the root (SSD) to not used root (SDcard) when ssd of HA crash for some reason i can change cmdline.txt so it boot from root of SDCard. Rebuild SSD and rsync back the root (SDCard) to root (SSD) and change cmdline.txt back. And we running again from SSD

Hi,

Iā€™m running HASS.IO on tinkerboard with sdcard. Do you think that a ssd and an adapter like the ones you use on RPi3 are good to go for a tinkerboard?