Rescue Your Mobian post Update Aug22 faster fix to working guide
#1
This guide is broken up into main recovery steps, and two separate guides for fixing your partition size and setting up GPS(not even needed in bookworm) referred to as steps in the main install guide, I am live editing it for a bit to add links and clean it up.  Most of this is copy/paste fixes over ssh and file transfers over USB, pretty easy way to get a better than fresh system in under an hour.

This is a kludgy guide I made after needing to wipe and restart at an auspicious time right before the serious system breaking Mobian Bookworm issues of August 2022.

*******!!!Use towboot to mount your / over your USB cable to rescue your /home we will use it later!!!**********

Get tow-boot and set it up on a SD card if you haven't already, we need it for install and salvaging your old /home and it's recovery, you can easily install it on a broken system

https://wiki.mobian-project.org/doku.php?id=tow-boot

this should be an easy copypasta fixit toolbox to get a working everyday driver pinephone in under an hour, jsut hold on updates until Mobian is fixed soon.
this works for me, edit what you want for install packages, I am sure the mobian issues could be hand fixed but this is the fast fix I have right now.
This fix works for me in a repeatable way, let me know ways to improve it!
_____________________________________________________________
Use towboot mount(boot with volume up button pressed you get a blue LED) to easily copy /home or at least copy a backup of phone contacts from ~/.local/share/evolution/addressbook/system/contacts.db to your computer

******remove your SD card or at least unsocket it!!!******  (if you forget to remove SD how-to de-booting the SD card at end of main guide)

reinstall Mobian over towboot/USB an image I used https://images.mobian-project.org/pineph...814.img.gz

Code:
sudo apt install ssh

ssh in through cable or wifi

do partition fix below(be sure to pick the correct partition mine is for emmc)!!!!!! 

***FIX PARTITION SIZES FIRST OR YOU WILL NOT BE ABLE TO INSTALL ANY SOFTWARE(unless the partition size in your image is already fixed in the future)***
------------------------------
ROOT PARTITION FIX (NOT OPTIONAL UNTIL MOBIAN FIXES ISSUE)

Emmc/SD card not being expanded on the Pinephone
On specific Pinephone installer images the storage medium Mobian is installed to does not get expanded to the full disk size. This can cause storage issues but can be fixed on the Pinephone in the terminal.
Assuming a ext4 setup.

First install parted by running
Code:
sudo apt install parted

Next, use parted on the correct drive put mmcblk2 if its on a emmc. mmcblk0 for sd card
Code:
sudo parted /dev/mmcblk2
****OR***
Code:
sudo parted /dev/mmcblk2

verify the correct partition with
Code:
lsblk

To further verify run
Code:
print

Resize the second partition
Code:
resizepart 2 100%

Verify it has changed with
Code:
print
ctrl-C out of parted to finish

If you have FDE(Full Disk Encryption) setup run this to resize the encrypted device. If not using disk encryption skip this command.
Code:
sudo cryptsetup resize calamares_crypt

Next, resize the ext4 filesystem.
Code:
sudo resize2fs /dev/mapper/calamares_crypt

check the result with
Code:
df -h


This should fix the issue with file expansion on a fresh install.
____________________________________________________________________________
start installing additional software.  if you like to be speedy fix GPS while flatpak installs your app list but check occasionally as some installs will ask options and flatpak requires y/n for all installs before it runs

do this first so you can have a second window open and setup navigation while apt and flatpak are running, check back on the installation though as sometimes there is dialog needing answers
Code:
sudo apt install gpsd gpsd-clients

now you can do navigation fixes in one window while you run the installs below
Code:
sudo apt install flatpak kodi tor screen links traceroute

***I recommend going into the software update app NOW and turning OFF automatic updates, at least as long as the current update is considered a problem.

(You HAVE to add flathub or you can't search software)

Code:
flatpak remote-add flathub https://flathub.org/repo/flathub.flatpakrepo
Install stuff edit as you like

Code:
sudo flatpak install authenticator clapper cozy enroute foliate fragments komikku puremaps shortwave teleport amberol osmscoutserver

do the bonus GPS fix below if you like, check for needing disc expansion below

Remember the backup copy we made of of /home? After setup is complete shutdown and use tow-boot(hold the volume up key and boot up) and transfer over USB now to replace with old /home if reloading (my restore overwrite took 15min for my 4gb) (edit)in hindsight I did only .kodi .local/share/evolution/ and .mozilla on my second try as something in home messed up the settings app and it couldn't open afterward

Insert you SD card if you haven't yet
If you accidently installed onto your SD card it will triy to block boot, easy to fix just run this on the SD from your computer or on the PP

Code:
sudo dd if=/dev/zero of=/dev/mmcblk0(or whatever device it is) bs=512 seek=16 count=1

Autoscale ALL apps

Code:
gsettings set sm.puri.phoc scale-to-fit true
 ---(or run it again as false if this gets annoying)  ***for auto scaling***
-------------------------------------------------------------------
GPS SETUP

Code:
sudo mmcli -m any --location-enable-gps-nmea --location-enable-gps-raw

(do the apt installs only if you didn't in the main guide)
Code:
sudo apt install gpsd gpsd-clients

scale the gui
Code:
scale-to-fit xgps on
scale-to-fit xgpsspeed on

Edit gpsd for the pinephone's modem/GPS connection in DEVICES="your modem"
Code:
sudo vi /etc/default/gpsd
  ------- add /dev/ttyUSB1 to devices--- 
Code:
DEVICES="/dev/ttyUSB1"
restart and daemons
Code:
sudo systemctl start gpsd.service
sudo systemctl status gpsd.service

Setup geoclue
Code:
sudo vi /usr/lib/systemd/system/geoclue.service
  ---- add in the “[Service]” section---
Code:
Environment="G_MESSAGES_DEBUG=Geoclue"

restart daemons
Code:
sudo systemctl daemon-reload
sudo systemctl restart geoclue.service

***Remember to turn ON navigation in the Settings app, under Privacy > Location Services***
Turning on Location services will get a mobile telephone network assist for AGPS as long as you have Internet too, if you are a privacy person you do not need to enable the Mozilla location service for AGPS to work as I show above.

I have found that puremaps seems to work best at triggering the GPS to take a fix and paired with OSM scout server so I can have my maps ready and offline, be sure to setup your maps before you travel
__________________________________________________________________
**as always use your mobian wiki and PLEASE contribute verified fixes to the wiki, we notn need to reinvent the wheel as individuals!!!***

https://wiki.mobian-project.org/doku.php?id=location
https://wiki.mobian.org/doku.php?id=trou...-pinephone
https://wiki.mobian-project.org/doku.php?id=tweaks
  Reply
#2
It is worth noting that something in the post update .conf files in /home/mobian is crashing the settings app.
before I transferred my backup of /home/mobian on to of the install it worked and I was able to setup my mobile data, after I am back to the settings app crash issue.
I might leave it until a Mobian fix or if I need settings to fix data I might go back and only save the dirs I feel like transferring like .kodi .local/share/evolution/ .mozilla maybe my mapping apps too.
For sure I will do this if the Mobian updates over the next few days are not fixed and I have to wipe anyways.


Perhaps I will take personal .img of a loaded, personalized, configured, and fully working pinephone so I don't have to do all of this work again but rather USB it over with tow-boot and reboot into personalized for me ready-to-use if I ever need it again.

There was a lightweight alt-boot bootloader app for the Maemo5 Linux Nokia N900 called Backup Manager which was a highly functional toolkit of useful actions like taking a backup image of the system to the SD or EMMC, restoring it, fdisk'ing the partitions, mounting them over USB, busybox, etc the only thing missing was mounting USB drives as this was a later hack. It was similar to the functionality of TWRP recovery tools on Android devices. I hope that tow-boot or a derivative will add these useful features with compatibility for most pinephone OSs.
  Reply
#3
I tested it and it worked exactly as I planned, wiped and reloaded from the guide, setup wifi and my mobile data APN, then I used filezilla to move .kodi(I used my desktop debian .kodi directory for this) and .local/share/evolution for my contacts from my /home backup.  Nothing else seems worth sending over as this /home backup was from a reinstall less than a week old.  Maybe
Code:
sudo apt remove totem
that app is nearly useless vs
Code:
sudo apt install clapper
which has hardware acceleration for smooth playback and has most normal media codecs I am not sure I have ever gotten any media on a SD card to play on totem, it has been pretty useless since the 2000s for me on all systems.

We need an easy to use mobian setup and tweaks for pinephone (gps and partitions) and backup script or app to do all of the above for a new install guide as well as backup important stuff from /home and backup apt and flatpak.  Maybe ~/.purple for SMS and IMs and ~/.var/app/com.github.geigi.cozy/data/cozy especially if you have several audiobooks running and want to keep your bookmarks.
Pikabackup only backs up a file and I see no easy path to a usable restore on the pinephone so it is a distraction at best from taking a real usable backup.
  Reply
#4
Exclamation 
(08-22-2022, 11:58 AM)biketool Wrote: It is worth noting that something in the post update .conf files in /home/mobian is crashing the settings app.

I tried to reinstall gnome-control-center, it seems to have a problem of dependency version right now. I hope that it will be fixed soon because I need it to work around several bugs (the alarm not working in power saving mode, receiving MMS not working with multiple APNs, etc).
  Reply
#5
Flashing tow-boot and the mobian distro you linked didn't work for me, and so I reverted to megi's multi distro, which 1) worked once already, 2) gives me Jumpdrive so I can write a script to extract my photos and sound recordings from the phone. In that distro, however, the resizing methods you mention don't work, there's always something missing - so once I finally remembered how I did it the first time (see here), the rest just worked. Well, mostly - there seems to be, probably, a clash between some setting in my backed-up /home (restored the address book and syncthing settings just fine), so the caller exits after its splash screen, and megapixels sometimes exits after trying to take a shot once, but when relaunched works again, or takes a few shots and then exits on next shot. SMS works but takes and makes no calls...

I remember I had such problems with the 2022-08-22 update, and that the next update fixed most of them, so... still waiting for the upgrade to finish.

Other than that, followed your instructions and, well, thanks man.
  Reply
#6
(08-28-2022, 12:41 PM)Eugo Wrote: Flashing tow-boot and the mobian distro you linked didn't work for me, and so I reverted to megi's multi distro, which 1) worked once already, 2) gives me Jumpdrive so I can write a script to extract my photos and sound recordings from the phone. In that distro, however, the resizing methods you mention don't work, there's always something missing - so once I finally remembered how I did it the first time (see here), the rest just worked. Well, mostly - there seems to be, probably, a clash between some setting in my backed-up /home (restored the address book and syncthing settings just fine), so the caller exits after its splash screen, and megapixels sometimes exits after trying to take a shot once, but when relaunched works again, or takes a few shots and then exits on next shot. SMS works but takes and makes no calls...

I remember I had such problems with the 2022-08-22 update, and that the next update fixed most of them, so... still waiting for the upgrade to finish.

Other than that, followed your instructions and, well, thanks man.

I am not sure why the resize didn't work for you; even jumpdrive vs towboot should work just fine, we are just mounting /home to get the few conf files we need.
I will say that I think I had trouble transferring all of /home so when I re-wiped I chose a few folders which were important to me.
I read your other post though and my cut/paste solution is for EMMC internal installs, you need to choose your SD card "put mmcblk2 if its on a emmc. mmcblk0 for sd card" you can verify with "print". 
Good to see it is working now though.
  Reply
#7
Aaaaaarghh! The upgrade stalled at 92%, on repeat it worked within a minute, but then the calls still didn't work (SMS did!), and camera was still erratic.

So I did an apt dist-upgrade, which killed the SMS too and a few other things as well. On next reboot the Mobian was stuck on console login without keyboard, aka the silent death.

Luckily, I went through Jumpdrive and backed up my contacts and keyboards (there's still nothing else important there)... switched to Fedora for a while, same interface and far fewer stuff installed (doesn't even have apt or apt-get or software manager...). But calling and SMS work, and I was able to finish entering my contacts. Now backup that and worry later - I need the phone to make a call tonight (namely, call a cab after a party Smile).

p.s. It almost worked - dialed all fine, but there was no sound in either direction, so a friend called a cab for us. Tested today again, same - no sound. I sort of remember there were some distros with this problem, and that fixing it was a long process.
  Reply
#8
(08-29-2022, 04:15 AM)Eugo Wrote: p.s. It almost worked - dialed all fine, but there was no sound in either direction, so a friend called a cab for us. Tested today again, same - no sound. I sort of remember there were some distros with this problem, and that fixing it was a long process.

I am having the same issue after I reinstalled and backed up a similar way. There is a way to manually get the sound to work in a phone call. The trick is to go to Sound under the Settings app and set it to the phone profile. This can be done before a call or during a call and then sound will work. You have to change back manually again afterwards.
  Reply
#9
(09-02-2022, 01:47 PM)vortex Wrote:
(08-29-2022, 04:15 AM)Eugo Wrote: p.s. It almost worked - dialed all fine, but there was no sound in either direction, so a friend called a cab for us. Tested today again, same - no sound. I sort of remember there were some distros with this problem, and that fixing it was a long process.

I am having the same issue after I reinstalled and backed up a similar way. There is a way to manually get the sound to work in a phone call. The trick is to go to Sound under the Settings app and set it to the phone profile. This can be done before a call or during a call and then sound will work. You have to change back manually again afterwards.

Yes, I have to do this all of the time, I guess I am used to it.  I wonder why it doesn't toggle, this is also a big problem I have with using the PP with Bluetooth in rental cars.
  Reply
#10
I will mark this as closed now as sudo apt upgrade(not dist-upgrade) gets me past but doesn't apply the held-back gnome updates to phosh.
I am sure there will be plenty of users who still need a quick reinstall guide for whatever reason so I hope this helps them and replying should ping my notifications.
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  atinout binaries for mobian/debian? NeutralGrey 4 1,312 10-31-2024, 04:16 AM
Last Post: astylethargic
  bookworm vs trixie discussion for mobian in pinephone regular. zetabeta 39 8,087 10-15-2024, 01:12 PM
Last Post: anonymous
  Calls 4G not working oliwierzgorniak 2 2,094 08-06-2024, 02:20 PM
Last Post: baptx
  Mobian-Kicksecure? 3460p 0 804 05-26-2024, 02:09 PM
Last Post: 3460p
  Mobian repository status henrythemouse 16 11,964 04-10-2024, 10:02 AM
Last Post: diederik
  cant verify mobian image at website gnugpg penguins_rule 0 867 03-18-2024, 08:54 PM
Last Post: penguins_rule
  Mobile internet via cellular network mostly not working Anna 18 13,573 01-19-2024, 02:59 AM
Last Post: anonymous
Exclamation The internal speaker stops working anonymous 6 2,586 01-17-2024, 05:53 PM
Last Post: anonymous
  mobian installed to eMMC - how to install tow-boot grump_fiddle_reinstall 6 3,876 11-22-2023, 11:46 AM
Last Post: aLoop100o
  What actions needed to keep on mobian testing user641 3 2,562 09-05-2023, 06:44 AM
Last Post: Zebulon Walton

Forum Jump:


Users browsing this thread: 1 Guest(s)