• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!

[OFFICIAL] LineageOS 18.1 for the Samsung Galaxy S4 (All QCOM Variants)

Search This thread

kel_niun

New member
Jan 18, 2014
4
0
Official procedure includes formatting data partition for removing device encryption
Thank You very much! That did solve my problem. I flashed the current lineageOS recovery with heimdall and used that to "factory reset" and install the LineageOS zip. I thought that wiping partitions with TWRP would do the same but the LOS recovery seems to do some extra things.
 

kurtn

Senior Member
Jan 28, 2017
4,238
1,839
Small town in Bavaria
Thank You very much! That did solve my problem. I flashed the current lineageOS recovery with heimdall and used that to "factory reset" and install the LineageOS zip. I thought that wiping partitions with TWRP would do the same but the LOS recovery seems to do some extra things.
Haha! No. LineageOS recovery just has just the absolute minimum of features. Looks like that made it easier for you to find.
Twrp also has that factory reset somewhere in advanced menu.
 

Edhuin

Member
Jan 24, 2015
14
0
Just picked up this phone for 30 bucks for my brother. Flashed twrp using odin and your lineageOS rom with opengapps pico. Runs well just the battery drains kinda fast even with wlan disabled. Wondering if it's caused by the rom or if the battery needs to be replaced. (gt-i9505)
 
Last edited:

kurtn

Senior Member
Jan 28, 2017
4,238
1,839
Small town in Bavaria
Just picked up this phone for 30 bucks for my brother. Flashed twrp using odin and your lineageOS rom with opengapps pico. Runs well just the battery drains kinda fast even with wlan disabled. Wondering if it's caused by the rom or if the battery needs to be replaced. (gt-i9505)
GApps is a heavy pieceof software. Leit it settle a few days. Wlan enabled.
 
  • Like
Reactions: pocketrule

rw_on_xda

Senior Member
Jun 24, 2013
335
178
Berlin
Just picked up this phone for 30 bucks for my brother. Flashed twrp using odin and your lineageOS rom with opengapps pico. Runs well just the battery drains kinda fast even with wlan disabled. Wondering if it's caused by the rom or if the battery needs to be replaced. (gt-i9505)
idle drain is here ~10 % /day (without GApps installed, Wifi, BT, NFC, Mobile Data: OFF, mobile: 2G)
 
  • Like
Reactions: pocketrule

Xharos

Senior Member
Dec 27, 2010
252
32
Canary Islands
I'm having a problem with this ROM. I was on LineageOS 17.1 previously and I followed the instructions to install 18.1 "from scratch", from the installation instructions page in the lineageOS wiki. I installed LineageOS and the MindTheGapps package, and the ROM boots but it always gets stuck in this part of the initial setup process:

9r81PnX.png


Any ideas? I left it overnight just in case it was just taking VERY long but nah, it always gets 100% stuck.
 
  • Like
Reactions: pocketrule

rw_on_xda

Senior Member
Jun 24, 2013
335
178
Berlin
no expert here, but:

1. I would leave MindTheGapps off in the first step
2. I would exchange LOS-Recovery with TWRP Recovery (currently don't know if LOS-Recovery is able format partitions !)
3. when TWRP is on the phone: format (not wipe) caches, DATA, system
4. install the rom
5. reboot
6. install MindTheGapps
 
  • Like
Reactions: pocketrule

Retrial

Recognized Contributor
Jun 10, 2015
1,375
2,300
Athens
Samsung Galaxy S4
Xiaomi Poco F1
I'm having a problem with this ROM. I was on LineageOS 17.1 previously and I followed the instructions to install 18.1 "from scratch", from the installation instructions page in the lineageOS wiki. I installed LineageOS and the MindTheGapps package, and the ROM boots but it always gets stuck in this part of the initial setup process:

9r81PnX.png


Any ideas? I left it overnight just in case it was just taking VERY long but nah, it always gets 100% stuck.
You can check my guides in S4 Unified Collection & Guides.
 
  • Like
Reactions: pocketrule

js-xda

Senior Member
Aug 20, 2018
219
101
I am still having troubles with reboots on a S4 (see quote of an earlier post below - the change of mobile network from 4G to 2G did not resolve in the end). I can narrow it by now down to receiving a WhatsApp message without GAPPS/Magisk/MicroG being installed (I9505, plain LOS 18.1 various recent builds, no Magisk, no MicroG, no GAPPS, WhatsApp and a 2-3 other apps). But it is by far not for every message! Nevertheless, I have also another S4 in use (same details as above) with Signal and WhatsApp without GAPPS/Magisk/MicroG where this issue does not occur. Also not on two S4s with GAPPS running no WhatsApp but some other messager (WeChat).

Is anyone experiencing issues with WhatsApp causing reboots in same or similar setting?

In the end, the issue can be top-line due to:
  • bug in a specific app
  • bug in the ROM
  • faulty hardware (e. g. overheating)
As I don't see it in a similar setting, I am wondering that the phone might be faulty but can't notice any excessive heating or so. Any other suggestion?

I am experiencing with one I9505 (plain LOS 18.1 various recent builds, no Magisk, no GAPPS, WhatsApp and a 2-3 other apps) quite frequent reboots (sometimes multiple times per day) which I notice as I need to enter the SIM PIN. This seems not to be the case for another I9505 (same LOS 18.1 builds, also no Magisk, no GAPPS, no WhatsApp here but 2-3 other apps) which I am running without SIM - so, not 100 % sure. I wiped the first one lately (data & system), flashed LOS 18.1 and installed everything from scratch but it still occurs. Anyone else observing similar behavior or an idea what could be the cause?

Edit: Just noticed that it is not a "full" reboot: The run time counter (second last entry in "About phone") shows 22 h runtime (matching a reboot last night while I had to enter SIM PIN twice today).

Edit 2: Appears that changing network from 4G to 2G (SIM is only for WhatsApp in there, all data via WiFi) helps. No SIM-PIN required since two days.
 

rw_on_xda

Senior Member
Jun 24, 2013
335
178
Berlin
@js-xda
maybe
- app CPU-Z for heating issues
- app syslog for getting log's

thoughts:
- try to install the Rom from the scratch
- maybe with stock as a intermediate step
- format partitions under TWRP
- try the last bootloader/Modem [1]
in short:
get the phone in a clean state
see @Retrail's Guides from comment #308

- try to exchange the battery of both phones to check if it's the not battery
- check sdcard's if you're running one
- usually they get slow over time => try to format under windows (NOT quick format !)


in the prev. LOS there had been crashes/reboots for some users and according to @arco68 they might be in this ROM too...
no one know exactly what it is/was !

I have had one during the first ~5 relases of 18.1

[1]
i've been running the last modem (HQK1) on an I9505
since LOS 18.1 I'm back on stock (HPK2, what is stock [germany, DBT])
 
Last edited:

npjohnson

Recognized Developer

x2k13

Senior Member

Jixyuuru

New member
Feb 2, 2019
3
1
Android 11? If GT-i9515 is your device, look here:

If you're looking for the last vendor update/firmware then check here:
yeah, I mean the requirement or best samsung firmware to run lineageos 18.1, do i need like android 4.4.2, 5.0.1 or 5.0.2? Sorry if type that wrong.
 

rw_on_xda

Senior Member
Jun 24, 2013
335
178
Berlin
yeah, I mean the requirement or best samsung firmware to run lineageos 18.1, do i need like android 4.4.2, 5.0.1 or 5.0.2? Sorry if type that wrong.
the requirement are here:

in general you don't need to care what's currently on the phone. It's overwritten when you flash LOS.
But I would flash the lastest stock to get the lastest stock modem and bootloader.
AFAIK, both don't get overwritten when flashing LOS (but I'm unsure here, esp. regarding bootloader).
but you're able to exchange both after flashing LOS too
- if modem/bootloader packages are available: see @Retrail's Guides from comment #308 -
 

Jixyuuru

New member
Feb 2, 2019
3
1
whatever the newest is for your variant.
I see, thank you sir.
the requirement are here:

in general you don't need to care what's currently on the phone. It's overwritten when you flash LOS.
But I would flash the lastest stock to get the lastest stock modem and bootloader.
AFAIK, both don't get overwritten when flashing LOS (but I'm unsure here, esp. regarding bootloader).
but you're able to exchange both after flashing LOS too
- if modem/bootloader packages are available: see @Retrail's Guides from comment #308 -
Ok, I keep that in mind, thanks.
 
  • Like
Reactions: npjohnson

Top Liked Posts

  • 1
    I reinstalled Lineage 18.1. after the installation I have the button Update Lineage recovery automatically.

    And see the internal memory is back.
    Ps. Although I activated this button, I still get into TWRP state Lineage recovery.

    Thank you for your tip, it helped
    Yeah you need to use Lineage Recovery for initial install for that toggle to work. TWRP overrides it.
    I have small bug in OTA update.
    After OTA update in recovery the phone reboots to ROM, shows "System update" then reboots again.
    But this is not real phone reboot but UI reboot only (no PIN request).
    Then the phone shows "System update" again endlessly.
    I need press power button and select reboot to ROM.
    OTA setting: update recovery, delete ROM after update.
    What other mods do you have? Xposed or magisk?
    1
    No. Only Official LineageOS 18.1 (Recovery & ROM), MindTheGapps, unrooted.
    I'd format and try again, something went wrong.
    1
    I'd format and try again, something went wrong.
    OK. I have the plans for this (clean install) in NY holiday :)
  • 3
    @npjohnson
    Today I installed the latest update lineage-18.1-20211104-nightly-jfltexx-signed.zip via the updater and found that the "Terminal" app is no longer available and can no longer be activated in the developer options. What could be the reason?
    We removed it, it wasn't very useful, as SELinux blocked most of it's functionality behind neverallows.
    3
    yeah, I mean the requirement or best samsung firmware to run lineageos 18.1, do i need like android 4.4.2, 5.0.1 or 5.0.2? Sorry if type that wrong.
    whatever the newest is for your variant.
    3
    yeah, I mean the requirement or best samsung firmware to run lineageos 18.1, do i need like android 4.4.2, 5.0.1 or 5.0.2? Sorry if type that wrong.
    the requirement are here:

    in general you don't need to care what's currently on the phone. It's overwritten when you flash LOS.
    But I would flash the lastest stock to get the lastest stock modem and bootloader.
    AFAIK, both don't get overwritten when flashing LOS (but I'm unsure here, esp. regarding bootloader).
    but you're able to exchange both after flashing LOS too
    - if modem/bootloader packages are available: see @Retrail's Guides from comment #308 -
    2
    So I'm having a weird issue on my SCH-R970 S4. I installed the lineageos recovery and rom easily. Everything worked fine for about an hour, then the phone powers off by itself and boots into recovery telling me that lineageos is corrupt.

    The weird thing is that it takes around an hour for it to happen. It's not the battery, it shows
    "Powering off" and the battery still shows it's charge when it happens.

    I had a Android 8 rom running on my S4 before this that worked fine, so I'm very confused as to why it's doing this.
    Let's hope inernal storage chip isn't dying. Try installing lineageOS again.
    2
    GT-i9515 here, what's the best firmware for this rom, should i go for lolipop or kitkat?
    Android 11? If GT-i9515 is your device, look here:

    If you're looking for the last vendor update/firmware then check here:
  • 23
    lineage-os-logo.png

    Samsung Galaxy S4

    Code:
    - Your warranty is now void.
    - You have been warned.
    - Use at your own risk.

    Introduction:
    This is the Official Lineage OS 18.1 thread for all Galaxy S4 variants.

    Downloads:
    Please follow the install instructions in your device's Wiki page linked below exactly, and make sure your device's firmware matches the required firmware listed.
    • jactivelte (GT-I9295)
    • jflteatt (SGH-I337) - Please note you will need to be on bootloader I337UCUAMDB or I337UCUAMDL
    • jfltespr (SCH-R970/C/X, SPH-L720)
    • jfltevzw (SCH-I545) - Please note you need to be on bootloader I545VRUSMDK
    • jfltexx (GT-I9505, SGH-I337M, SGH-M919) - NOTE: GT-I9505G is supported in this build, but due to system size space limitations it will not fit any form of GApps package.
    • jfvelte (GT-I9515/L)

    If you don't follow these instructions, or use 3rd party add-ons (like Magisk) please don't expect support here.

    Known Bugs:
    • MHL doesn't work after LineageOS 14.1, and likely never will again, as Google dropped support for it platform-wide in AOSP.
    • Find any? Report them according to this guide.
    Notes:
    • The only supported GApps package at the moment is MindTheGapps, linked on our Wiki page about gapps.
    Kernel Source: https://github.com/LineageOS/android_kernel_samsung_jf
    6
    thanks for response and support
    This issue is now fixed. You will need to sideload the upcoming build by hand to get back on track though.

    Sorry for the inconveniences.
    5
    Good news, my GT-I9505 is updating automatically at this moment ("Update recovery" option disabled).
    Next step, activate the option to update the recovery and see if this works well.
    Thanks @npjohnson for your incredible work
    the recovery image updates the second you check the box.

    after you update OS, it updates the recovery on the next boot during boot animation.

    Have fun! Good to hear.
    5
    USB otg is unfortunately broken at the moment. But you can get access to your external storage by installing MiXplorer (which I recommend in any case) and "enable otg" in settings -> more settings
    Should be fixed in next build.
    5
    many thanks all developers - great work.

    i had dirty flashed from official 17.1 with 65 installed apps yesterday
    (SAMSUNG_I9505)

    rebooted to TWRP (twrp-3.5.1_9-0-jflte)
    0. wiped only system/dalvic/cache:
    1. flashed LOS (lineage-18.1-20210401-nightly-jfltexx-signed.zip)
    2. MindTheGapps-11.0.0-arm-20210328_143701
    3. magisk 22.0

    everything works well.


    but there was to much google-apps.

    i had unzipped MindTheGapps-11.0.0-arm-20210328_143701
    and reduced apps like "open_gapps-arm-pico"

    deleted:
    system/product/app/GoogleTTS
    system/product/app/talkback
    system/product/priv-app/AndroidAutoStubPrebuilt
    system/product/priv-app/Velvet

    and zipped again "MindTheGapps-11.0.0-arm-20210328_reduced"

    also once again

    0. wiped only system/dalvic/cache - rebooted to TWRP:
    1. flashed LOS 18.1
    2. MindTheGapps-11.0.0-arm-20210328_reduced
    3. magisk

    everything works well for now.