Showing posts with label USB-Mode. Show all posts
Showing posts with label USB-Mode. Show all posts

Friday, February 7, 2025

Pinephone Pro (with Tow-Boot) - Installing a new OS on the eMMC

In my previous Pinephone Pro, I was describing how I was coming up to speed on the different storage mechanisms on the Pinephone Pro: SPI vs eMMC vs microSD.  

Contextually, we are talking about block storage, and there is a well known command that one can run to see block storage on a Linux device: lsblk.  Running this command on your Pinephone Pro - in a Terminal - can help you understand "what is what and where". And it's important to understand this.

One concern I had, was installing a new OS to the eMMC, and blowing away the boot process. I had installed Tow-Boot on the phone, but had to make sure it was in its own spot (it was, SPI) - away from where a new OS was going to go - especially if you plan to clean or format the eMMC before installing a new OS. So my previous post discusses how I had to figure all of this out, and learned that Tow-Boot was installed on the SPI - making it safe to install a new OS.

Here was my process for installing this new OS, with comments:

  1. Download the image
    • Figure out what display manager you want. 
      • Phosh? Plasma? Gnome? Xfce? There is not shortage of choices.
      • I went with Plasma - because it worked well when I ran the OS on the microSD
    •  I went with 20250206
      • Check the md5 hash - which is always wise to verify the integrity of the image.
      • Unpack/Uncompress the "xz" file.
        • NOTE: In Mac Pro, xz did not work, and neither did tar xvfz. Using the GUI and clicking the file in File Manager invoked the Archive Utility to unpack the file. But in Linux, xz or tar should work fine.
  2. Make sure your Pinephone Pro is sufficiently charged. 
    • At least 50%, preferably 75%, and optimally fully charged at 90% or greater. 
    • I should note that with Manjaro, the power charge percentage was not always accurate.
  3. Power off your Pinephone Pro.
  4. Connect the Pinephone Pro using USB-C connector, into a USB-C connector of your laptop.
  5. Power the phone up, and after first vibration, hit the Volume-Up button
    • You are looking for a blue light on your Pinephone Pro, signifying that you are in USB Mode.
  6. Make sure the laptop/computer sees the Pinephone Pro as a device.
    • In my case, on a Mac Pro, I used File Manager.
    • Examine the /dev devices and this is IMPORTANT! Because if you install your OS onto your laptop partition, you have a big big problem.
      • I quickly noticed that /dev/disk4 had the BOOT_MJRO volume name on it, ensuring that disk4 was the disk I wanted to install the new OS to.
  7. Unmount the disk
    • because you cannot format or do an image copy on a disk that's already mounted. 
    • on a Mac Pro, diskutil was used for this: sudo diskutil unmountDisk /dev/disk4 
  8. Clean the partition
    • sudo dd if=/dev/zero of=/dev/disk4 bs=1M count=100
  9. Copy the image to the eMMC 
    • Tools like Balena Etcher can be used for this.
    • The "dd" tool is a Linux tried-true way to do this and this is what I chose:
      • sudo dd if=20250206-0046-postmarketOS-v24.12-plasma-mobile-5-pine64-pinephonepro.img of=/dev/dis
        k4 bs=1M status=progress
  10. Watch the progress, and once finished, eject the phone
    • sudo diskutil eject /dev/disk4
  11. Power the Pinephone Pro down
  12. Unplug the USB-C connector that is connected between Pinephone Pro and the laptop/computer.
  13. Power the Pinephone Pro back up.
    • You will see a terminal show up on the screen - don't mess with it - just wait.
    • Eventually the Plasma Display Manager will (or should) light up.
    • The OS will take some minutes to initialize, and to be responsive to user input.
  14. Log into the phone

SLAs using Zabbix in a VMware Environment

 Zabbix 7 introduced some better support for SLAs. It also had better support for VMware. VMware, of course now owned by BroadSoft, has prio...