[Galaxy Note 4 General] edp17:
OTA update to 4.4 is ready. (4.4.0.58)

Because 4.3 is a stop release, as the first step, we need to OTA to 4.3, then move over to 4.4.

The problem with wifi (keeps forgetting the password after every boot) remains. There is a workaround below.

Here is the instruction on what to do:

OTA 4.2 to 4.3

!IMPORTANT!

If you are on the kernel with waydroid support (hybris-boot-sfos42-06-waydroid.img), first you must flash the original cm14.1 kernel (hybris-boot-sfos42-01.img) otherwise the OTA update will break the system![/COLOR]

In TWRP, do a full backup of your 4.2 system just in case something goes wrong during the upgrade

Unapply and remove all patches

Uninstall patchmanager

Reboot (this is required after patchmanager is removed, otherwise you will need to restart lots of services)

Boot into sfos, enable developer mode and set a password

Connect the phone to a wifi network (for downloading packages)

From this point, we will work on the PC, leave the phone connected.

Connect the phone to a PC, open a console and on the PC run (enter the password when you are prompted):ssh nemo@192.168.2.15

Switch user to root (enter the password when you are prompted): devel-su

Check repos: ssu lr

Disable all repos, except: apps, hotfixes, jolla: ssu dr <repo_name>

Add/modify adaptation-community-common repo: ssu ar adaptation-community-common https://repo.merproject.org/obs/nemo:/testing:/hw:/common/sailfishos_4.3.0.15/

Add/modify adaptation-community-treltexx repo: ssu ar adaptation-community-treltexx https://repo.merproject.org/obs/nemo:/testing:/hw:/samsung:/treltexx/sailfishos_4.3.0.15/

In case you have the mousetracker repo, disable it as can be added after the update ssu dr mousetracker

if you have waydroid installed and chum repo added, disable the chum repo because its waydroid packages will interfere with the installed ones. (The new waydroid packages will be updated from the chum repo and will break the waydroid installation.)ssu dr chum

make sure that both adaptation-community-common and adaptation-community-treltexx are enabled and you do not have duplications (command 'ssu er <name>' enables the given repo)

the adaptation-community-common should point to https://repo.merproject.org/obs/nemo:/testing:/hw:/common/sailfishos_4.3.0.15/

make sure adaptation-common is there and points to https://releases.jolla.com/releases/4.3.0.15/jolla-hw/adaptation-common/armv7hl/

Put the device in release mode:ssu release 4.3.0.15

Refresh packages: (use zypper now) zypper ref

Upgrade the system: zypper dup --details

IMPORTANT!

: Before the reboot amend these two files:

/usr/lib/systemd/system/dsme.service : set PrivateNetwork=true to PrivateNetwork=false

/usr/lib/systemd/system/systemd-hostnamed.service : remove or comment out PrivateNetwork=true

Then reboot: reboot

Once rebooted you can stay on 4.3 or go to 4.4.

If you decide to upgrade to 4.4 (I recommend that), here is the instruction on what to do. Some steps will be hacky but until I found another solution, this is the way.

OTA 4.3 to 4.4

(You can stay on the kernel that came with 4.3)

In TWRP, do a full backup of your 4.3 system just in case something goes wrong during the upgrade

Unapply and remove all patches and uninstall patchmanager (these shouldn't be there if you go to 4.4 without using 4.3)

mask lipstick (this disables the GUI for the upgrade): devel-su systemctl-user mask lipstick

reboot (from this point, this will be a bit tricky as there is no GUI and no wifi available) important to leave the cable in before booting, otherwise, there won't be ssh

As there is no internet and wifi cannot be started, you need to use your host linux's internet, do the following:

on host linux:

run these two commands as root:

iptables -t nat -A POSTROUTING -o wlpxxxx -j MASQUERADE
echo 1 > /proc/sys/net/ipv4/ip_forward

where wlpxxxx is the host wlan name

on the device:

run these as root:

route add default gw 192.168.2.x
echo 'nameserver 208.67.222.222' > /etc/resolv.conf

where 192.168.2.x is the ip address of the device on host

now you should have an internet connection on the device, so we can do the actual upgrade

Switch user to root (enter the password when you are prompted): devel-su

Check repos: ssu lr

Disable all repos, except: apps, hotfixes, jolla: ssu dr <repo_name>

Add/modify adaptation-community-common repo: ssu ar adaptation-community-common https://repo.merproject.org/obs/nemo:/testing:/hw:/common/sailfishos_4.4.0.58/

Add/modify adaptation-community-treltexx repo: ssu ar adaptation-community-treltexx https://repo.merproject.org/obs/nemo:/testing:/hw:/samsung:/treltexx/sailfishos_4.4.0.58/

In case you have the mousetracker repo, disable it as can be added after the update ssu dr mousetracker

if you have waydroid installed and chum repo added, disable the chum repo because its waydroid packages will interfere with the installed ones. (The new waydroid packages will be updated from the chum repo and will break the waydroid installation.) ssu dr chum

make sure that both adaptation-community-common and adaptation-community-treltexx are enabled and you do not have duplications (command 'ssu er <name>' enables the given repo)

the adaptation-community-common should point to https://repo.merproject.org/obs/nemo:/testing:/hw:/common/sailfishos_4.3.0.15/

make sure adaptation-common is there and points to https://releases.jolla.com/releases/4.4.0.58/jolla-hw/adaptation-common/armv7hl/

Put the device in release mode: ssu release 4.4.0.58

Refresh packages: (use zypper now) zypper ref

Upgrade the system: zypper dup --details

IMPORTANT!

: Before the reboot amend these two files (they were overwritten by the upgrade):

/usr/lib/systemd/system/dsme.service : set PrivateNetwork=true to PrivateNetwork=false

/usr/lib/systemd/system/systemd-hostnamed.service : remove or comment out PrivateNetwork=true

don't forget to unmask lipstick: devel-su systemctl-user unmask lipstick

Then reboot:reboot

Once the device is booted into the new system try all functions and reboot at least once to try if it still starts the system correctly. If everything is okay, you can add back the chum and mousetracker repos:

ssu ar chum https://repo.sailfishos.org/obs/sailfishos:/chum/4.4.0.58_armv7hl/

ssu er chum

ssu ar mousetracker https://repo.merproject.org/obs/home:/elros34:/sailfishapps/sailfishos_4.4.0.58/

ssu er mousetracker

GPS and Bluetooth (and waydroid if installed) should work out of the box. Plus you don't need to flash the kernel either.

Workaround for the wifi issue:

This is a bit hacky but you need to do the hacky bit only once.

There is a script provided to turn wifi manually on/off from a command line or Shellex. The script is located in /usr/bin/droid/wifi-on.sh It has one parameter on or off (e.g.: wifi-on.sh on)

To make it work you need to enter your home network name, password and last IP address into the /usr/bin/droid/wifi-conf file.

In addition (and this is the hacky part) you need to do the following (only once):

turn wifi on and connect to the home network

turn wifi off

as root, go into ~/.local/share/system/privileged/connman

if you have multiple wifi_*_*_managed_psk folders in the, keep only one and delete the rest

rename the kept wifi_*_*_managed_psk folder to tmp_wifi

go into the tmp_wifi folder and edit the settings file

Its first line will be the same as the original file name was like [wifi_*_*_managed_psk]

rename the text in [] to match with the new name, so needs to be [tmp_wifi] (in the file you'll see the network name, password and last IP address that you need to add into the wifi.conf file)

Done. :D From now if you call the `wifi-on.sh on` script as root, it will connect to the network defined in wifi.conf (you don't need to toggle the wifi button from the menu)

Waydroid potential problem

After the upgrade I got this error reported into in waydroid log : "dnsmasq: failed to create listening socket for 192.168.250.1: Address already in use"

The solution was: to check and kill the running dnsmasq, then restart waydroid-container. Then you can start the session and UI as normal.

Spen problem

The other thing I spotted was a typo in the /usr/bin/droid/sailfishpen-daemon.sh. Because of that, the device doesn't detect when the Spen is pulled out/put back.

Solution: In /usr/bin/droid/sailfishpen-daemon.sh, change the evtest path to /usr/bin/evtest. (The wrong is /usr/bin/droid/evtest)

If you have any issues, give me a shout. :)

Good luck!