Difference between revisions of "User:Pnoecker/Undead USB Install"

From Funtoo
Jump to navigation Jump to search
m (adding linux firmware & noto fonts to improve universality)
m
(4 intermediate revisions by the same user not shown)
Line 10: Line 10:
###i## cd /mnt/funtoo
###i## cd /mnt/funtoo
###i## wget https://build.funtoo.org/1.4-release-std/x86-64bit/generic_64/2019-11-26/gnome-stage3-generic_64-1.4-release-std-2019-11-26.tar.xz
###i## wget https://build.funtoo.org/1.4-release-std/x86-64bit/generic_64/2019-11-26/gnome-stage3-generic_64-1.4-release-std-2019-11-26.tar.xz
###i## tar --numeric-owner -xpf *stage3*
###i## tar --numeric-owner -xpf *stage3* && rm -f *stage3*
###i## mount -t proc none proc
###i## mount -t proc none proc
###i## mount --rbind /sys sys
###i## mount --rbind /sys sys
###i## mount --rbind /dev dev}}
###i## mount --rbind /dev dev}}


were using googles name server simply because its universal and anyone can access it anywhere.
were using googles name server simply because its universal, and anyone can access it anywhere.


{{console|body=
{{console|body=
Line 21: Line 21:
###i## env -i HOME=/root TERM=$TERM /bin/chroot . bash -l}}
###i## env -i HOME=/root TERM=$TERM /bin/chroot . bash -l}}


were disabling swap because we didnt partition for it, many new systems and some old systems have enough ram to never need it, and swap frys flash media rapidly so it should be located on rotating disks anyways.
were disabling swap because we didn't partition for it, many new systems, and some old systems have enough ram to never need it, and swap frys flash media rapidly so it should be located on rotating disks anyways.  im compiling on 16gb of ram but 8 should be sufficient, possibly even 4gb or less.


{{console|body=
{{console|body=
Line 28: Line 28:
###i## echo "LABEL=funtoo / jfs noauto,noatime 0 1" >> /etc/fstab
###i## echo "LABEL=funtoo / jfs noauto,noatime 0 1" >> /etc/fstab
###i## ping -c 5 google.com && ego sync
###i## ping -c 5 google.com && ego sync
###i## emerge jfsutils grub linux-firmware media-fonts/noto}}
###i## emerge jfsutils grub haveged linux-firmware media-fonts/noto}}


Name your host name to reflect that this is your undead media.
Name your host name to reflect that this is your undead media.
Line 37: Line 37:
use old school mbr method of installing grub.
use old school mbr method of installing grub.
{{console|body=
{{console|body=
###i## grub-install --target=i386-pc --no-floppy /dev/sda && ego boot update}}
###i## grub-install --target=i386-pc --no-floppy /dev/sda && ego boot update
###i## rc-update add haveged}}


final install size is 10,176 MB purging the stage3 tarball will reduce this 3 gb.
final install size is 10,176 MB


I have a pny nvidia 1050ti 4gb and nouveau doesn't work well so I have to rebuild the kernel and nvidia drivers.
rebuild the kernel video drivers modules.


{{console|body=
{{console|body=
###i##Emerge @module-rebuild}}
###i##Emerge @module-rebuild}}


Past this the USB should work on almost anything with a USB port.
DONE!  there are modularity problems to be ironed out.
 
Past this the USB should work on almost anything x86_64 with a USB port. i have not tested this on intel systems yet.  i have not tested on amd video systems yet.
 
ok uefi isnt booting yet...  intel graphix isnt doin its thing.  lets try
dev-util/intel-graphics-compiler
dev-libs/amdgpu-pro-opencl #difficult fetchrestrictions ill check if its actually necessary to start xdm.
&& maybe fix that uefi mode?  idk how this is going to go down on my non uefi system building this, my amd video device is uefi so that hasnt been tested yet.  building from a non uefi bios will not allow the command, but the uefi bios has a legacy boot mode option.  uefi looks like a disaster, suggesting setting bios to support legacy mode for now.
grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id="Funtoo Linux [GRUB]" --recheck /dev/sda

Revision as of 03:52, December 25, 2019

This is an install strategy to target a USB flash stick as / instead of a traditional hard drive or internal solid state drive. this isn't a live cd, this is a persistent root funtoo install that changes will keep living on.

In this run i will use a 64gb 100 mb/s sandisk, but you can probably get away with even 16gb. get a fast usb3 drive even if you dont have usb3 ports as the flash memory on them is much faster than the flash memory on usb2 keys which will improve usability.

using gparted delete the flash key fat32 partition and create a single jfs / partition labeled as funtoo, and mount it to /mnt/funtoo. were using JFS because we want as much raw speed and power from the install possible.

we want our USB to be targeting generic hardware so we can take our root funtoo EVERYWHERE with us all the time. we use the generic 64 subarch. if a systems 32, you probably dont want to be doing much computing on it anyways, but do as you will. we will be using a gnome stage3 tarball.

root # cd /mnt/funtoo
root # wget https://build.funtoo.org/1.4-release-std/x86-64bit/generic_64/2019-11-26/gnome-stage3-generic_64-1.4-release-std-2019-11-26.tar.xz
root # tar --numeric-owner -xpf *stage3* && rm -f *stage3*
root # mount -t proc none proc
root # mount --rbind /sys sys
root # mount --rbind /dev dev

were using googles name server simply because its universal, and anyone can access it anywhere.

root # echo "nameserver 8.8.8.8" > /mnt/funtoo/etc/resolv.conf
root # env -i HOME=/root TERM=$TERM /bin/chroot . bash -l

were disabling swap because we didn't partition for it, many new systems, and some old systems have enough ram to never need it, and swap frys flash media rapidly so it should be located on rotating disks anyways. im compiling on 16gb of ram but 8 should be sufficient, possibly even 4gb or less.

root # rc-update del swap boot
root # passwd
root # echo "LABEL=funtoo / jfs noauto,noatime 0 1" >> /etc/fstab
root # ping -c 5 google.com && ego sync
root # emerge jfsutils grub haveged linux-firmware media-fonts/noto

Name your host name to reflect that this is your undead media.

root # mv /etc/conf.d/hostname /etc/conf.d/.hostname
root # echo 'hostname="undead"' > /etc/conf.d/hostname

use old school mbr method of installing grub.

root # grub-install --target=i386-pc --no-floppy /dev/sda && ego boot update
root # rc-update add haveged

final install size is 10,176 MB

rebuild the kernel video drivers modules.

root #Emerge @module-rebuild

DONE! there are modularity problems to be ironed out.

Past this the USB should work on almost anything x86_64 with a USB port. i have not tested this on intel systems yet. i have not tested on amd video systems yet.

ok uefi isnt booting yet... intel graphix isnt doin its thing. lets try dev-util/intel-graphics-compiler dev-libs/amdgpu-pro-opencl #difficult fetchrestrictions ill check if its actually necessary to start xdm. && maybe fix that uefi mode? idk how this is going to go down on my non uefi system building this, my amd video device is uefi so that hasnt been tested yet. building from a non uefi bios will not allow the command, but the uefi bios has a legacy boot mode option. uefi looks like a disaster, suggesting setting bios to support legacy mode for now. grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id="Funtoo Linux [GRUB]" --recheck /dev/sda