Installing debian on pinebook pro (deb installer/emmc)
#11
No dice I'm afraid! I did try modifying /etc/default/u-boot replacing the line in it with U_BOOT_ROOT="root=LABEL_ROOT_DEBIAN" . I've attached a picture of this btw.

I also checked with fdisk and found the emmc (while on its usb adapter) dosen't start at 32768 but 251904 so guessing that won't work. 

I'll try again with just the one partiton starting at 32768.

Update: I tried again with one partiton starting at 32768 and this time it looks like things worked ok :-) . Will post back here later to show what I did (pretty much just fdisk'd on another computer starting at 32768, installed via the debian installer, chroot, ran u-boot-update /dev/sda and then tried booting off the emmc). 

ljones


Attached Files Thumbnail(s)
   
  Reply
#12
Ok, here's what seemed to work for me! I am still trying this out btw on the rockpro64 btw I am hoping it can be adapted for the pinebook pro.

First of all, you need the following:

* An already existing debian install on microsd for the rockpro64 - needed because the debian installer itself can't actually mount ext4 partitions manually.

* A blank microsd (to write the debian installer onto)

* An emmc chip(!) . I'm using a 16GB emmc as that was all that was left the larger sizes have all sold out.

* An emmc to USB adapter

The first thing to do is to use another linux pc to fdisk the emmc. Put the emmc chip onto its usb adapter and do the following:

Code:
$ su -
$ dmesg (find out what the emmc on usb adapter is called, let's say for example /dev/sdg)
$ fdisk /dev/sdX (e.g. /dev/sdg)

Then create a new partition with the first sector of the partition starting at 32768 (important!). The last sector can be anything for example up to the end of the emmc. Write this and then exit fdisk.

Remove the emmc to usb from the PC and then grab your blank microsd card. Insert it into the pc (a usb to sd/microsd card adapter should work fine).

Next write the debian installer from here choosing the files firmware.rockpro64-rk3399.img.gz and partition.img.gz; then (remaining as root);

Code:
$ dmesg ( find out what the microsd card is called, let's say /dev/sdg)
$ zcat firmware.rockpro64-rk3399.img.gz partition.img.gz > out.img
$ dd < out.img > /dev/sdX (e.g. /dev/sdg)
$ sync

Put the jumper onto the rockpro64 and insert the microsd card with the debian installer on it into the rockpro64. Plug the emmc to usb into the rockpro64.

When in the installer when you get to partition disks, choose "manual" then look for the emmc device; in my case it turned out to be "SCSI1 (sda) 15.8 GB Generic storage device".

Then choose #1 primary then "Use as:do not use" change to ext4. Change mount point none to "/"; then turn the bootable flag on. Write this by choosing "done setting up the partition". Finish writing the changes ("finish partitioning"). If it says you haven't selected any swap space choose no - don't go back to partitioning menu. Then say yes to write changes. Then carry on with normal install.

Unfortunatly at this point (and so I found out) the debian installer although it can seemingly write to ext4 partitions it dosen't seem to have any way to manually mount ext4 (I did try this and it did not work). Instead (and this is where the other micro sd card is needed) boot up an already existing debian install off microsd for the rockpro64; with the emmc to usb still connected do:

Code:
$ mkdir /tmp/0
$ mount /dev/sda1 /tmp/0
$ mount -o bind /dev /tmp/0/dev
$ chroot /tmp/0

And then when you're in the chroot;

Code:
$ apt update
$ apt install u-boot-menu u-boot-rockchip
$ cd /usr/lib/u-boot/rockpro64-rk3399
$ cp * / (ugly but it works)
$ u-boot-update
$ u-boot-install-rockchip /dev/sda
$ sync

(It appears my earlier idea of thinking that I needed to set something like a partition name isn't needed after all).

Next exit the root, shut down the rockpro64 and power off. Disconnect power then transfer the emmc onto the rockpro64 itself. Make sure the jumper isn't on and the microsd socket is empty; power on and (hopefully) it'll boot debian off the emmc.

It'll need a different firmware file for sure but hopefully this will work for the pinebook pro.

Hope I haven't forgotten anything!





Update:
I now also have this working on the pinebook pro! Here are some rough notes:

**WARNING** Not guaranteed to work! There's the possibility I've forgotten a step here btw, not sure!

- You need the files firmware.pinebook-pro-rk3399.img.gz and partition.img.gz - zcat them together as above then dd.

- You'll need 2 micro sd cards - one for an actual debian install and one for the installer.

- a USB to ethernet adapter (makes things easier).

First use the microsd card that you used dd on. Install debian onto that same microsd card (the one with the installer on). It does actually work -- in the installer choose manual partitioning and choose "MMC/SD card"; mine showed up as "MMC/SD card #2 (mmcblk1) 8GB SD". Don't use the 62.5 GB MMC/SD card (that is the internal emmc!).

Make the partition on the microsd card itself (leave the partition that is already on it alone) there should be some space. Create the new partition, set the mount point to /, format type ext4 and bootable to on. Write that and install as normal to the microsd.

Once the install is complete boot off the microsd card. Then install u-boot-menu and u-boot-rockchip.

Then
Code:
$ cd /usr/lib/u-boot/pinebook-pro-rk3399
$ cp * /
$ u-boot-update
$ u-boot-install-rockchip /dev/mmcblk2

Then use fdisk and delete (on /dev/mmcblk2) any partitions on the internal emmc. Create an ext4 partition but start it at 32768 as above.

Now use the other microsd card and install the debian installer again (on another linux pc). But this time install to the partition you made on the emmc. Make it bootable and ext4 but do not change it in any other way. Install as normal.

Once complete, remove the microsd then power cycle the pinebook pro. Hopefully it should start up and boot ok. If it won't boot off the emmc, try booting off the first micro sd card again the one with debian installed (with debian installed now onto the internal emmc, mmcblk2) and try installing u-boot again (above). I forget if I had to do this a second time!

Unknown: Unless it is just my pinebook pro sometimes I found when booting I got lots of grey or white vertical lines and no text. This seems to require powering down, waiting for a few seconds and then powering back on again to fix.

ljones


Attached Files Thumbnail(s)
           
  Reply
#13
If I understand you correctly you are trying to boot of a eMMC thats is attached to a USB to eMMC "converter".

Are you sure your u-boot can boot of USB? To my understanding this is a special treat that is not always/ever supported.
  Reply
#14
(02-04-2022, 09:14 AM)Humid Stylus Wrote: If I understand you correctly you are trying to boot of a eMMC thats is attached to a USB to eMMC "converter".

Are you sure your u-boot can boot of USB? To my understanding this is a special treat that is not always/ever supported.

Just really trying to copy onto the emmc by using a emmc to usb adapter not really booting off it. On the rockpro64 I removed the emmc once I was finished from the usb to emmc adapter and installed the emmc directly onto the rockpro itself.

ljones
  Reply
#15
Your error seems like the one I had before I left enough space for u-boot, that is before your partitions start.

See https://forum.pine64.org/showthread.php?...0#pid99470 for more info.
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Upgrading Armbian from v24.2.1 gnome, breaks pinebook pro Sb2024 0 198 11-10-2024, 02:50 PM
Last Post: Sb2024
  Pinebook pro won't boot after bootloader installation jwensouls 4 1,171 08-21-2024, 04:17 AM
Last Post: KC9UDX
  Official Debian support moonwalkers 64 66,470 07-08-2024, 01:40 PM
Last Post: Humid Stylus
  [Pinebook Pro/Mobian/XFCE4] can fix touch or screen in greeter not both SynthGal 0 464 05-31-2024, 09:42 AM
Last Post: SynthGal
  Debian on Pinebook Pro u974615 7 3,151 03-31-2024, 10:11 AM
Last Post: u974615
  Pinebook Pro upgrading from the factory image yamsoup 12 4,650 02-22-2024, 04:02 PM
Last Post: tllim
  Help installing Manjaro on eMMC of Pinebook Pro pine4546464 4 3,416 12-13-2023, 07:22 PM
Last Post: trillobite
  Need Help Recovering Manjaro /boot Contents on Pinebook Pro calinb 6 3,712 12-11-2023, 03:47 AM
Last Post: calinb
  Gentoo on Pinebook Pro RELEASE jannik2099 54 106,327 12-08-2023, 11:25 PM
Last Post: tllim
  Manjaro 20.04 not loading from SD (with Manjaro on eMMC) zaius 1 947 12-07-2023, 03:11 PM
Last Post: wdt

Forum Jump:


Users browsing this thread: 1 Guest(s)