Difference between revisions of "PinePhone Installation Instructions"
Jump to navigation
Jump to search
(→Installation to the eMMC: Why was that deleted? It's a valid installation method.) |
(various style fixes) |
||
Line 24: | Line 24: | ||
Make sure to select the correct device using <code>lsblk</code>. Then run <code>dd</code> with the correct device: | Make sure to select the correct device using <code>lsblk</code>. Then run <code>dd</code> with the correct device: | ||
sudo dd if='''IMAGE.img''' of=/dev/'''[DEVICE]''' bs=1M status=progress conv=fsync | |||
sudo dd if= | |||
==== Using bmaptool ==== | ==== Using bmaptool ==== | ||
Make sure to select the correct device using <code>lsblk</code>. Then run bmaptool with the correct device: | Make sure to select the correct device using <code>lsblk</code>. Then run bmaptool with the correct device: | ||
Download the | Download the ''IMAGE.xz'' and the ''IMAGE.bmap'' files, then run <code>bmaptool copy --bmap ''IMAGE.bmap'' ''IMAGE.xz'' /dev/'''[DEVICE]'''</code>. This takes around 2.5 minutes to flash a 4 Gb file. | ||
==== Using graphical tools ==== | ==== Using graphical tools ==== | ||
GUI applications such as Etcher and GNOME Disks can be used to flash the | GUI applications such as Etcher and GNOME Disks can be used to flash the microSD too. | ||
== Installation to the eMMC == | == Installation to the eMMC == | ||
Line 56: | Line 54: | ||
# Boot the PinePhone from the Jumpdrive microSD card | # Boot the PinePhone from the Jumpdrive microSD card | ||
# Connect the PinePhone to your computer using USB-A -> USB-C cable | # Connect the PinePhone to your computer using USB-A -> USB-C cable | ||
# Flash the exposed PinePhone drive (e.g. /dev/mm..., check for the right device in dmesg, GNOME disks, or similar, and make sure it's unmounted) with your chosen OS image | # Flash the exposed PinePhone drive (e.g. ''/dev/mm...'', check for the right device in <code>dmesg</code>, GNOME disks, or similar, and make sure it's unmounted) with your chosen OS image | ||
# Once the flashing process is complete, disconnect the PinePhone from your PC, power it down and remove the Jumpdrive microSD card | # Once the flashing process is complete, disconnect the PinePhone from your PC, power it down and remove the Jumpdrive microSD card | ||
# The process is now finished, and you can boot from eMMC | # The process is now finished, and you can boot from eMMC | ||
Line 67: | Line 65: | ||
# Download the desired OS' image on the booted OS or transfer it to the microSD card | # Download the desired OS' image on the booted OS or transfer it to the microSD card | ||
# Extract the image file if it is archived | # Extract the image file if it is archived | ||
# Flash the image file to eMMC using <code>dd if= | # Flash the image file to eMMC using <code>dd if='''IMAGE.img''' of=/dev/'''mmcblkX''' bs=1M status=progress conv=fsync</code> where X is the number label of the eMMC (of the disk, not the partition!). Use the command <code>lsblk</code> to check your devices: typically with the current kernel the microSD card is ''/dev/mmcblk0'' and the eMMC is ''/dev/mmcblk2'' but as always with ''dd'' be extremely cautious to get the devices correct. | ||
# Turn off phone, remove microSD card and then turn on the phone. | # Turn off phone, remove microSD card and then turn on the phone. | ||
=== SD to eMMC via installer === | === SD to eMMC via installer === | ||
postmarketOS and Mobian installer images booted from microSD card will simply ask the user, if they want to install to eMMC. The feature lives in the | postmarketOS and Mobian installer images booted from microSD card will simply ask the user, if they want to install to eMMC. The feature lives in the distribution-agnostic calamares-extensions repository (see [https://github.com/calamares/calamares-extensions/pull/7 calamares-extensions#7]), so other distributions might adopt this in the future. | ||
== Resize partition to fit disk space == | == Resize partition to fit disk space == | ||
Line 111: | Line 109: | ||
Once you have installed your release of choice to eMMC, you may wish to use an microSD card for data storage. If you choose to re-use a card you have previously used to boot from, you will find your phone will not boot if you just reformat the card and insert it. This is because the Allwinner firmware in the PinePhone uses some (normally) unused space at the front of the microSD card to store boot software, which you need to clear. | Once you have installed your release of choice to eMMC, you may wish to use an microSD card for data storage. If you choose to re-use a card you have previously used to boot from, you will find your phone will not boot if you just reformat the card and insert it. This is because the Allwinner firmware in the PinePhone uses some (normally) unused space at the front of the microSD card to store boot software, which you need to clear. | ||
This can be done as follows on any | This can be done as follows on any Linux system: | ||
lsblk | lsblk | ||
to check the device of your microSD card – as an example lets assume it is /dev/mmcblk0 | to check the device of your microSD card – as an example lets assume it is /dev/mmcblk0 | ||
then | then | ||
sudo dd if=/dev/zero of=/dev/ | sudo dd if=/dev/zero of=/dev/'''[DEVICE]''' bs=8k seek=1 count=4 | ||
will clear the relevant sectors of your card. | will clear the relevant sectors of your card. | ||