data/app folder showing wrong folder names


Question

After messing around with the xposed framework and installing lots of modules, I got into a bootloop (classic !), but I knew the solution was to add a disabled file in data/app/de.rovb.android.xposed.installer/conf/ to disable xposed and uninstall the faulty modules.



The thing is, most of the time when I access this folder, I don't see the correct folder names, which are supposed to look like this : com.xyz.app.*. Instead, I see com.xyz.app.*-1 folders, containing a lib folder and the app's .apk file. I have to reboot into recovery a dozen times before I can access the actual folders.



I'm running CyanogenMod 12S (5.0.2) on a (rooted) OnePlus One.



I have no idea what's happening, and I couldn't find any info on that. Does anyone know why this is happening?



Thanks in advance !


Answer

Let's clear up some confusion. Things to always remember:




  • /data/app contains the APK of an app.



    (PACKAGE → package name of an app)




    • Android 4.x: if the app is installed using Package installer of Android the file name would be PACKAGE-*.apk where * is often a positive integer.



      /data/app isn't supposed to have any directory inside it.


    • Android 5.x: if the app is installed using the Package installer, a directory would be created for the app with name PACKAGE-* where * is often a positive integer. This directory contains the APK of the app with name base.apk.


  • For both Android 4.x and 5.x, /data/data contains only the data of the apps. All the apps are allotted a directory with name strictly the package name of the app.


  • For both Android 4.x and 5.x, /data/lib contains only the library (optional) of the apps. All the apps are allotted a directory with name PACKAGE-* where * is often a positive integer.




Now let's head towards the real issue.






When dealing with boot issues caused by an Xposed module, do not wander here and there.



Note:




  • Device requires to be booted into a custom recovery, data partition mounted there and setup in PC.

  • PACKAGE → package name of the Xposed module here

  • Unless explicitly mentioned otherwise, the solution would work on Android versions 4.2.1 - 5.1.1.



When you know which module is causing the boot issue



Go to /data/app and remove the APK of the troublesome module. This can be done from GUI on TWRP.



You can use command-line as an alternative



adb shell rm /data/app/PACKAGE*.apk


A less-extreme approach is to disable the Xposed module but not remove it. Head over to data directory of Xposed Installer /data/data/de.robv.android.xposed.installer, go inside conf, and remove the entry for your module from modules.list. It is up to you how you remove the line.




  • You can pull the file into PC, make changes and push it back.

  • I'd go for command-line though



    adb shell sed -i '/.*PACKAGE.*/d' /data/data/de.robv.android.xposed.installer/conf/modules.list


    sed is a stream editor and it is removing any line which contains module's package name from modules.list.




When uncertain about the exact module causing the boot issue




  • Go to to data directory of Xposed Installer /data/data/de.robv.android.xposed.installer, go inside conf, and remove or rename or revoke read permission from modules.list.


  • Alternatively, create a blank file named disabled (not disable) inside conf directory. This would cause Xposed Framework to not activate any module during boot. You can create the file using command-line



    adb shell touch /data/data/de.robv.android.xposed.installer/conf/disabled

  • Another alternative, per the framework's developer rovo89 is




    [It is] possible to disable Xposed by repeatedly pressing one of the hardware buttons during early startup. The phone will vibrate twice when the first key press has been detected. Then you have five seconds to press the same button four more times. Each key press will be confirmed with a short vibration; the final one with a long vibration. It creates /data/data/de.robv.android.xposed.installer/conf/disabled, which prevents most of Xposed's actions (e.g. ... no modules are loaded). There's no 100% guarantee that this will get you out of a bootloop, but in most cases it should.




    (Emphasis mine)




Remove Xposed Framework as a last resort



Android 4.2.x - 4.4.x



Use the file Xposed-Disabler-Recovery.zip located at /sdcard/Android/data/de.robv.android.xposed.installer/files. Flash that file from recovery mode to disable Xposed Framework. It doesn't delete the Installer app.



Download the file from official thread, if you don't have one.



That archive, in essence, changes /system/bin/app_process.orig to /system/bin/app_process. You can make those changes on your own using adb in recovery mode.



Android 5.x



The official thread hosts an uninstaller file. Download the one relevant to your CPU's architecture and flash it from recovery mode.



If you're not using the official Xposed Framework then the uninstaller may not work for you. It may even cause unforeseen issues. Best is to search the web for the uninstaller.


Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes