1

Using adb, I uninstalled some system apps on my device. Sadly, I uninstalled something important, and now the device is in a bootloop.

During boot there is a window of time which I'm able to login with adb. But when I try to reinstall the system apps:

adb shell cmd package install-existing --user 0 com.xyzname

I get this error:

Can't find service: package

I used to be able to run install/uninstall commands in this bootup window, but now the service 'package' isn't being started.

I tried looking up how to run services with adb, and I found some commands using am, but nothing pertaining to specifically running 'package'.

I need to get service 'package' to run. Begging for help here.

2
  • See if you can run this command: adb shell pm install-existing --user 0 com.xyzname. If that doesn't work either, you have to do a factory reset because I am assuming you don't have a custom recovery (which at least offers a way out in this case).
    – Firelord
    Aug 8, 2021 at 20:42
  • 1
    Thanks for the suggestion. Sadly it doesn't work, I don't have custom recovery. The service package needs to be running ☹️
    – Rucent88
    Aug 9, 2021 at 2:32

1 Answer 1

1

I had the same error and finally got it to work by adding su -c.

For your case, it should be:

adb shell su -c cmd package install-existing --user 0 com.xyzname

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .