TIP: Click on subject to list as thread! ANSI
echo: rberrypi
to: ROBH
from: CHRIS ELVIDGE
date: 2019-11-09 09:37:00
subject: Re: Enal disk wik with th

On 08/11/2019 20:13, RobH wrote:
> On 07/11/2019 16:36, Chris Elvidge wrote:
>> On 07/11/2019 15:44, RobH wrote:
>>> On 07/11/2019 00:56, Vince Coen wrote:
>>>> Hello Chris!
>>>>
>>>> Thursday November 07 2019 13:10, you wrote to RobH:
>>>>
>>>>   > On 07/11/2019 12:52, RobH wrote:
>>>>   >> I'm having a hard time finding the information I want , so I ask
>>>>   >> here:
>>>>   >>
>>>>   >> Has anyone had success using an external disk with the pi 4, and
>>>>   >> preferably booting from it.
>>>>   >>
>>>>   >> The other option I thought about was to put some other version of
>>>>   >> Linux on it, ubuntu?, but using etcher in linux doesn't do it, as
>>>>   >> it's an iso.
>>>>   >>
>>>>   >> Thanks
>>>>
>>>>   > Not a Pi4 but I have Pi3+s booting from SD card (holding only the
>>>>   > /boot partition) and 128/256Gb SSD (mSATA in mSATA to USB3
>>>> adapter) as
>>>>   > root. Quite easy if you follow the instructions. I never had
>>>> much luck
>>>>   > booting directly from the USB SSD, hence the above arrangement.
>>>>
>>>>   > --
>>>>   > Chris Elvidge, England
>>>>
>>>>
>>>> I use a 3B+ sitting in a x830 box and card with a 1TB dasd  .
>>>> The drive has the Rasbian installed and it powers up, boots to the
>>>> the USB
>>>> drive.
>>>>
>>>> Every thing works - so far but I do not run it daily just as a when
>>>> as I use a
>>>> server system for day to day
>>>> development and other activities such as BBS, FTP, SQL, Apache, IBM
>>>> m/f server
>>>> or services.
>>>> This hold a lot of dasd unit giving over 10+ TB storage all in 16GB
>>>> Ram with a
>>>> modular PSU so it is light on
>>>> power needs but a Pi is a heck of a lot less :)
>>>>
>>>> Did want to get a Pi4 but will not fit into the current X830 case so
>>>> will wait
>>>> until a revised X830 combo
>>>> comes out.
>>>>
>>>>
>>>>
>>>> Vince
>>>>
>>> Thnks, and are there any simple instructions for doing that for a
>>> simple lad like me.
>>
>> Install Raspbian (other OSs are available) onto SD card as usual.
>> Update as necessary.
>> Format external drive. Include a swap partition, root partition plus
>> any extra ones required.
>>
>> Make a note of UUID/PARTUUID of the new root (and swap if used)
>> partition. (see "man blkid"). Mount the new root partition on (say)
>> /mnt and then
>> rsync -avx / /mnt to get the OS onto the usb drive.
>>
>> You now need to change the cmdline.txt file on the SD card boot
>> partition to add to the root= parameter. Make a copy before you edit
>> this file. Should look something like this:
>>
>> dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1
>> root=PARTUUID=5cf6b9c2-9894-cd47-933e-ad3840ae4e5c rootfstype=btrfs
>> elevator=deadline fsck.repair=yes rootwait quiet splash
>> plymouth.ignore-serial-consoles net.ifnames=0 biosdevname=0
>> usbhid.mousepoll=0
>>
>> Note the PARTUUID is the one you remember from your note above. (You
>> can use the UUID instead, though; root=UUID=uuidfromabove).
>> net.ifnames=0 and biosdevname=0 makes the ethernet and wireless ports
>> revert to eth0 and wlan0. usbhid.mousepoll=0 compensates for a USB
>> mouse on my system.
>> Commands in cmdline.txt must be all one line, and only on one line.
>> Remove any blank lines in the file.
>>
>> Now edit /etc/fstab on the NEW root partition (/mnt/).
>> If there is an entry for /dev/mmcblk0p2 on /, change the
>> /dev/mmcblk0p2 to UUID=theuuidfromabove. If not OK, it'll find it from
>> the cmdline.txt file.
>> Put a new entry:
>> /dev/mmcbl0p2 /mnt/oldroot ext4 noauto,defaults 0 0
>> (and remember to make directory /mnt/oldroot AFTER unmounting the new
>> root partition). This will stop your old root being mounted at boot.
>> (You can still mount it with mounr /mnt/oldroot, if necessary.)
>>
>> Add an entry for swap if using a partition.
>>
>> umount /mnt; mkdir /mnt/oldroot
>>
>> Reboot and keep your fingers crossed.
>>
>> I don't think I've left anything out!!
>>
>> If it fails, take out the SD card and revert the cmdline.txt file in
>> another computer. It's on a vfat partition so a Windows PC can read
>> it, too.
>> Put it back and reboot. Check all the above. If it still fails, note
>> the errors and come back.
>>
>> Good luck
>>
>
> I've made a root partition, as  well as a swap partition on a spinning
> 160Gb disk.
>
> This is my present cmdline.txt file before any changes, and it looks a
> bit different than new or changed line. Does it matter.
>
> dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1
> root=PARTUUID=4eae5394-02 rootfstype=ext4 elevator=deadline
> fsck.repair=yes rootwait quiet splash plymouth.ignore-serial-consoles
>

The root=PARTUUID= bit refers to the second partition on your SD card.
Use blkid to find the PARTUUID or UUID of what will become the root
partition on the HDD. Change 4eae5394-02 to whatever you found from the
blkid command. If you have no PARTUUID on the HDD, use the UUID and
change root=PARTUUID= to root=UUID=
net.ifnames=0 and biosdevname=0 are only needed if you want to refer to
your network interfaces as eth0 and wlan0
usbhid.mousepoll=0 compensates for a mouse connected over a wireless USB
connection (dongle). A bluetooth mouse doesn't need it. Wired USB mouse
may or may not. If you get lag, try it.


--

Chris Elvidge, England

--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)

SOURCE: echomail via QWK@docsplace.org

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.