Are adb commands possible on SFOS?

Hey there,

I want to execute adb commands to enable special permissions for an android app.
Is there a way to execute adb command on SFOS?

Thanks!
Best Regards
Philipp

You can use lxc-attach to get a console in the container.

1 Like

devel-su lxc-attach -n aliendalvik /system/bin/sh

It’s not really ‘adb’, but it is a root shell, so you can do certain things that you could do with adb, like ‘pm grant …permission’, etc. It’s like ‘adb shell’

I find it useful for navigation bar mod apps and logcat reader apps…

5 Likes

There is an actual adb that’s made for android, and I’ve briefly yested usimg it, but it’s not starting. I have a feeling that it couldn’t work on Android on SF, probably because of read-only nature of fs…


But anyway, this would not be useful to use on the device you have it installed on. It would be to use your device as if it was a computer, to do adb on another device. If you have an Android device with root access, you can easily uae it to operate adb and fastboot on your SF device. That’s how I do all of my flashing, erc…

why adb then, ssh it

I’m familiar with adb from years of Android. Not so familiar with ssh…

question for you - I have tried to access SF recovery via telnet from android terminal and telnet apps, but always get ‘network unreachable’ or something like that. I can boot the phone into Jolla recovery no problem, but can’t seem to access the recovery when booted. Could ssh do that, or is there something else I’m missing to get through on telnet?

for telnet you should install rndis driver for new device appearing after you insert usb cable to your pc, and setup network connection. Described here: https://jolla.zendesk.com/hc/en-us/articles/360002996893

1 Like

well, then there is a new stuff you can learn.

1 Like

riright, but I’m using an Android phone as a computer

no matter. install termux and feel yourself like a god

1 Like

Ok. So I made an assumption that driver wouldn’t install on Android like it would on computer … I’ll try it.

ohh, just realized you’re trying to connect to sfos recovery from an android device!

yes - that’s my issue. I’ve done it with pc many times, and telnet from Android is no problem, but I haven’t figured out how to get it to see that device…

We have been flashing sfos from sfos quite some time ago so yes

Thank you for your replies!

I need to execute the following adb commands but with the approaches stated here this should not be possible:

Can somebody help?

answer to your question is on first comment

use terminal in Sailfish to get androud shell, as posted above, and then enter the commands in android shell, (but without the ‘adb -d shell’ part).

1 Like

Thanks! I think that worked.
The only thing is that the app “Clipto” seems not to work. When I copy somehting in another android app Clipto should automaticly create a note with the clipboard content. But nothing happens at the moment.

clipto working fine here…



Make sure to go into settings and enable clipboard ‘rune’…