Template:Copying Alpine to Flash: Difference between revisions

From Alpine Linux
(Warning about device name)
m (Remove redirect. (target is also RfD))
 
(26 intermediate revisions by 10 users not shown)
Line 1: Line 1:
== Copy Alpine to a {{{1|Flash Medium}}} ==
{{Delete|This redirect is to an include that is obsolete and is completely unused on the wiki}}
 
# Insert the removable {{{1|flash medium (CF or USB stick)}}} into the computer.
# Determine the name your computer uses for your {{{1|flash medium}}}. The following step is one way to do this.
#* After inserting the {{{1|flash medium}}}, run the command:
#* {{Cmd|dmesg}}
#* At the end of this command you should see the name of your {{{1|flash medium}}}, likely starting with "sd". (For example: "sda").
#* The remainder of this document will assume that your {{{1|flash medium}}} is called /dev/sda
 
{{Warning|Be very careful about this. You do not want to mistakenly wipe your hard drive if it's on /dev/sda}}
 
=== Format {{{1|Flash Medium}}} ===
{{Cmd|fdisk /dev/sda}}
* '''p''' Print list of partitions
* '''d''' Delete all partitions (this may take a few steps)
* '''n''' Create a new partition
* '''p''' A primary partition
* '''1''' Partition number 1
** Use defaults for first and last cylinder (just press [Enter] twice).
* '''t''' Change partition type
* '''c''' Type: Win95 FAT32 (LBA)
* '''a''' Make the partition bootable (set boot flag)
* '''1''' Partition number 1
* '''w''' Write your changes to the device
 
=== Install Syslinux ===
# Install syslinux and dosfstools. If you have booted from an Alpine CD-ROM, use these commands:
#* {{Cmd|apk add syslinux dosfstools}}
#* {{Cmd|{{{|dd if=/usr/share/syslinux/mbr.bin of=/dev/sda}}}}}
# Format the {{{1|flash medium}}} with a VFAT filesystem:
#* {{Cmd|mkdosfs -F32 /dev/sda1}}
#* {{Cmd|syslinux /dev/sda1}}
#* {{Cmd|mkdir -p /media/sda1}}
#* {{Cmd|mount -t vfat /dev/sda1 /media/sda1}}
# Mount the Alpine Linux CD-ROM, and copy the files to the {{{1|flash medium}}}
#* {{Cmd|mount /media/cdrom}}
#* {{Cmd|cd /media/cdrom}}
#* {{Cmd|cp -a .alpine-release * /media/sda1/ }}
 
=== Set up a Serial Console (Optional) ===
 
You can now edit syslinux.cfg to add a serial console to the {{{1|flash medium}}}.
 
# Open /media/sda1/syslinux.cfg for editing.
#* {{Cmd|vi /media/sda1/syslinux.cfg}}
# Add the line `serial 0 9600` to the top of the file
# Add the text ` console=tty1,38400 console=ttyS0,9600` to the end of the "append" line.
 
The result should look like this:
serial 0 9600
timeout 20
prompt 1
default grsec
label grsec
kernel /boot/grsec
append initrd=/boot/grsec.gz alpine_dev=usbdisk:vfat modules=loop,cramfs,sd-mod,usb-storage console=tty1,38400 console=ttyS0,9600

Latest revision as of 06:15, 14 August 2023

This material is proposed for deletion ...

This redirect is to an include that is obsolete and is completely unused on the wiki (Discuss)
Make sure no other pages link here and check the page's history before deleting.