6

I need to install an APK on a phone with no built in file browser, and no connection (wifi/mobile). The LG Optimus M has no built in file browser... Not sure why, but it is making things very difficult. I was thinking if I could put an app in a special place on an SD card, or auto-run an APK install.

ADB is also not an option due to usb driver issues. I know this is pretty limited...

EDIT: I got down voted because you didn't read? There is no wifi/mobile connection available. Downloading a file manager etc. from market not an option.

6
  • Why can't you use ADB? ADB doesn't require any special drivers for your phone, you simply put the device in development mode and it should work.
    – slayton
    Sep 15, 2011 at 1:16
  • The windows drivers are preventing us in this specific case with the current requirements
    – jhnclvr
    Sep 15, 2011 at 1:22
  • If you don't have a market connection and you can't get ADB working then you are stuck. It would be a HUGE security issue if your phone started installing random APKs without user input.
    – slayton
    Sep 19, 2011 at 15:21
  • It is possible we are stuck. We are working with broken phones as part of the requirements, and so the requirements are a bit restrictive indeed. I was hoping there was a key folder or something where you could put an APK that would somehow show up as an option to install. Or there would be a folder that would show up on the desktop etc. Thanks for your help.
    – jhnclvr
    Sep 20, 2011 at 13:36
  • Can better you describe what happens when you plug in the phone in Debug mode
    – slayton
    Sep 20, 2011 at 13:49

4 Answers 4

5
  1. Enable usb debugging

  2. Install the drivers and android sdk

  3. Connect the phone through usb to your computer

  4. Call the following program from the command prompt: adb install application.apk

  5. Adb will now install your application

According to the about of just running adb, you can use the following command line arguments:

adb install [-l] [-r] [-s] [--algo <algorithm name> --key <hex-encoded key> --iv <hex-encoded iv>] <file>
    - push this package file to the device and install it
                ('-l' means forward-lock the app)
                ('-r' means reinstall the app, keeping its data)
                ('-s' means install on SD card instead of internal storage)
                ('--algo', '--key', and '--iv' mean the file is encrypted already)
1
  • I always get this error: Error: failed to write; ES (No such file or directory) for any APK file
    – vsync
    May 22, 2017 at 7:27
0

Why not download one of the MANY file browsers in the market? May I suggest my favorite which is Astro File Manager

0
0

If you have a terminal emulator app on the device, you can put MyApp.apk on the SD card and run this, which should open the package installer:

am start -a "android.intent.action.VIEW" -d "file:///mnt/sdcard/external_sd/MyApp.apk" -t "application/vnd.android.package-archive"

You might need to change that path depending on your device — see How can I determine storage directory from ADB?

You will also need to enable the Unknown Sources option in the device settings.

-2

Why not download astro file manager? it works great. Other than that I would host the apk on a server and download it from the phone.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.