Android Enthusiasts
Q&A for enthusiasts and power users of the Android operating system
Latest Questions
1
votes
3
answers
2629
views
How to use terminal on Android to ssh access my server?
Can I ssh into a Linux Server from my Android device?
Can I ssh into a Linux Server from my Android device?
NINJA
(29 rep)
Jun 9, 2015, 03:13 PM
• Last activity: Jun 26, 2025, 07:38 AM
1
votes
1
answers
146
views
Use SSH tunnel along with a proxy
I have installed "Termux" app on my Android device. I can this use this command on Termux app to create a Socks 5 tunnel to my remote VPS on port `1080`: ``` ssh -D 1080 user@22.15x.20y.150 ``` Then I use "Exclave" app to proxy my Android device through that port. But as soon as I activate the conne...
I have installed "Termux" app on my Android device. I can this use this command on Termux app to create a Socks 5 tunnel to my remote VPS on port
1080
:
ssh -D 1080 user@22.15x.20y.150
Then I use "Exclave" app to proxy my Android device through that port.
But as soon as I activate the connection on Exclave app, the ssh
connection on Termux app is terminated. Consequently the Exclave app cannot connect the Android device through the ssh
tunnel to the Internet.
I'm not sure, but it looks like a cycle problem or loop problem to me.
So far, I couldn't find a way to modify Exclave app to exclude the ssh
Socks 5 connection from the proxy.
What are the solutions to this problem?
I'm open to any solution that might possibly solve my original problem. Thanks.
Megidd
(242 rep)
May 18, 2025, 07:01 AM
• Last activity: May 18, 2025, 07:26 AM
1
votes
0
answers
171
views
How to start a ftp/ssh server on android though adb without root
Is it possible to start a ftp server or SSHD (SSH server) on android though ADB without root, then I can use WinSCP to access files on android from PC? Currently I use some apps on android as a FTP server, but this needs operations on the phone, I wish to find a way only by PC CLI method (then for m...
Is it possible to start a ftp server or SSHD (SSH server) on android though ADB without root, then I can use WinSCP to access files on android from PC?
Currently I use some apps on android as a FTP server, but this needs operations on the phone, I wish to find a way only by PC CLI method (then for my scripts).
furynerd
(11 rep)
Nov 19, 2024, 03:43 AM
• Last activity: Nov 19, 2024, 06:09 AM
2
votes
2
answers
2188
views
Free (libre) SSHD for Android?
How can I install a **sshd** server (with **scp** support) on Android **without relying on Google Play Store** for my safety? Rooting the device or compiling the application is not a problem, but so far I'm unable to find proper instructions. I don't need a GUI either, some kind of on/off switch wou...
How can I install a **sshd** server (with **scp** support) on Android **without relying on Google Play Store** for my safety?
Rooting the device or compiling the application is not a problem, but so far I'm unable to find proper instructions. I don't need a GUI either, some kind of on/off switch would be nice tho, but that's not required.
JKAbrams
(123 rep)
Jan 21, 2014, 09:03 AM
• Last activity: Sep 27, 2024, 11:22 AM
2
votes
0
answers
191
views
Is there is a way to exempt apps (e.g. termux) from Doze in Android 14?
Since Android 14, I'm no longer able to log into my phone remotely via a reverse tunnel to a server with a static IP. It appears that Doze is the underlying issue; it stops termux, which stops the sshd child process, so the tunnel goes away, and it doesn't come back, despite my having scheduled (in...
Since Android 14, I'm no longer able to log into my phone remotely via a reverse tunnel to a server with a static IP. It appears that Doze is the underlying issue; it stops termux, which stops the sshd child process, so the tunnel goes away, and it doesn't come back, despite my having scheduled (in termux-land) a check-and-restore process every few minutes. It does not help to turn off battery optimizations or to enable wake-lock.
Is there is a way to exempt termux (for example) from Doze in Android 14 without rooting the phone?
Steve Newcomb
(131 rep)
Apr 26, 2024, 02:34 PM
• Last activity: Jun 28, 2024, 05:13 PM
3
votes
1
answers
155
views
How can I enable swipe typing and autocorrect in Juice SSH?
The Juice SSH app disables swipe typing and autocorrect on the keyboard by default. How can I switch these features back on? The Juice SSH FAQ says to swipe right on the keyboard[1]: > In normal JuiceSSH operation autocomplete, autocorrect and swipe typing are disabled. If you want to ente...
The Juice SSH app disables swipe typing and autocorrect on the keyboard by default. How can I switch these features back on?
The Juice SSH FAQ says to swipe right on the keyboard[1] :
> In normal JuiceSSH operation autocomplete, autocorrect and swipe typing are disabled. If you want to enter text with these features enabled, you can do so by swiping right on our popup keyboard. When done, just swipe it back to switch back into command input mode.
Elsewhere, they say to swipe left[2] :
> Because it interferes with typing in commands. But swipe left on the popup keyboard it will go into autocomplete/autocorrect mode.
However, neither swiping right nor left does anything with the keyboard, neither within Juice SSH nor within any other app.
Alexander Klauer
(211 rep)
Apr 20, 2024, 07:27 PM
• Last activity: Apr 20, 2024, 08:11 PM
0
votes
1
answers
1110
views
SSH to localhost on android
I am trying to get ssh working on my android phone. I am currently able to ssh out, from my phone to another device. But I am struggling to be able to ssh in. To test things, I am just working on my the phone and trying to establish an ssh connection with localhost. Working in termux, I ran the comm...
I am trying to get ssh working on my android phone. I am currently able to ssh out, from my phone to another device. But I am struggling to be able to ssh in. To test things, I am just working on my the phone and trying to establish an ssh connection with localhost.
Working in termux, I ran the command
ssh localhost -p 8022
Then I am given the prompt
u0_a316@localhost's password:
I'm struggling a bit to understand this. I know that u0_a316 should be a user on my phone, but I don't quite know how users on the android oprating system work. I tried entering the lock screen password I have for myself, as well as no password. But neither of these work. Could someone help explain whats going on here, or point me to some (hopefully not too dense) documentation on this?
*this question is cross posted from stackoverflow, following a recommendation in the comments*
IsAdisplayName
(103 rep)
Sep 2, 2023, 09:22 PM
• Last activity: Feb 6, 2024, 07:48 PM
6
votes
1
answers
6307
views
Run Android application from remote computer
I need to run my Android application from a remote computer (in the same network) via SSH (not using ADB). How do I do that?
I need to run my Android application from a remote computer (in the same network) via SSH (not using ADB). How do I do that?
MByD
(186 rep)
Mar 19, 2011, 12:31 PM
• Last activity: Nov 9, 2023, 03:21 PM
6
votes
1
answers
22197
views
SSH client for Android with scp and sftp features
I have tried SSHjuice and Termius and neither of these have the scp features ( I couldn't find it in the free/trial version ). So can anybody tell me is there any SSH client (free version) for Android that have scp (secure copy ) or sftp features. I couldn't find it in Google. thanks .
I have tried SSHjuice and Termius and neither of these have the scp features ( I couldn't find it in the free/trial version ).
So can anybody tell me is there any SSH client (free version) for Android that have scp (secure copy ) or sftp features.
I couldn't find it in Google. thanks .
Just Khaithang
(211 rep)
Mar 28, 2019, 11:12 AM
• Last activity: Nov 4, 2023, 04:11 AM
2
votes
2
answers
3625
views
Access sensors and camera of Android device from shell
I have logged in to my Android phone through SSH [installed SSH client in Android and through Putty from Windows]. Now I can access all the directories like `root`, `dev`, `etc`, of the phone. Can someone tell me what's the native method to access the devices and sensors of the phone? I mean, how ca...
I have logged in to my Android phone through SSH [installed SSH client in Android and through Putty from Windows]. Now I can access all the directories like
root
, dev
, etc
, of the phone.
Can someone tell me what's the native method to access the devices and sensors of the phone? I mean, how can I control say, the camera, just from this Linux shell terminal of the phone?
user2875341
(21 rep)
Oct 13, 2013, 07:57 AM
• Last activity: Sep 21, 2023, 08:06 AM
2
votes
1
answers
4177
views
Connect ADB through SSH
**How can I connect ADB on remote server through SSH to a local, non-rooted Android devices without installing anything on the middleman with root?** This is what I want to achieve: ``` ┌─────────┐ SSH through internet │ Physical│ USB cable ┌────────┐ (outside LAN) ┌────────┐ │ Android ├───────────►...
**How can I connect ADB on remote server through SSH to a local, non-rooted Android devices without installing anything on the middleman with root?**
This is what I want to achieve:
┌─────────┐ SSH through internet
│ Physical│ USB cable ┌────────┐ (outside LAN) ┌────────┐
│ Android ├───────────►│ Laptop ├──────────────►│ Cloud │
│ device │ └────────┘ │ server |
└─────────┘ └────────┘
192.168.0.5 192.168.0.7 (internal IP address)
204.12.46.76 108.63.15.64 (public IP address)
The one in the middle _must not_ install any software with root/sudo
. The laptop and server are both running Ubuntu 22.04.
From Android device to laptop, I can use the physical USB cable. From laptop to cloud server, I can use local SSH port forwarding (ADB uses port 5037). However, I do not know how to go from "physical USB cable" to "port 5037".
I include the relevant (fake) internal and external IP addresses for demonstration only.
ecokjeonb
(71 rep)
Sep 18, 2023, 04:43 AM
• Last activity: Sep 18, 2023, 05:07 PM
11
votes
2
answers
16863
views
How to get battery status in terminal?
I have a phone with dropbear installed. I usually access my phone over WiFi & run commands in putty. I want to get battery status & percentage in terminal. Is there any command or program to obtain battery info ?
I have a phone with dropbear installed. I usually access my phone over WiFi & run commands in putty.
I want to get battery status & percentage in terminal. Is there any command or program to obtain battery info ?
jonny789
(385 rep)
Nov 5, 2015, 08:18 AM
• Last activity: Aug 14, 2023, 08:56 PM
10
votes
3
answers
9196
views
Android keyboard and remapping the CTRL key
I have an Samsung Galaxy 10.1 running Android version 4.1.2. I am using ssh to remotely connect to my main machine which runs Ubuntu 12.04 LTS. Once I am connected I do all my work in emacs 24.3. I also have a bluetooth keyboard. My question is about remapping the Caps Lock key to function as the Ct...
I have an Samsung Galaxy 10.1 running Android version 4.1.2. I am using ssh to remotely connect to my main machine which runs Ubuntu 12.04 LTS. Once I am connected I do all my work in emacs 24.3. I also have a bluetooth keyboard.
My question is about remapping the Caps Lock key to function as the Ctrl key. I do this with my main machine by changing a setting in the terminal options. I checked the options in juiceSSH and there appears to be no equivalent. Perhaps there is a general way to do this with Android or the Bluetooth Keyboard.
How can I remap the Caps Lock character to function as the Ctrl character?
If you need more information let me know.
CodeKingPlusPlus
(193 rep)
Aug 27, 2013, 02:27 AM
• Last activity: Jun 18, 2023, 11:38 AM
0
votes
1
answers
409
views
Trying to set up SSH with shared key, but the server is not recognizing the device's key
I'm running an Amazon Fire HD 7 first gen, with CyanogenMod 11 on it. Here are my system settings since they're required on Reddit: [![][1l]][1] I'm trying to set up SSH with a shared key on CyanogenMod. Normally, it's very easy to connect to my server, but I'm having difficulty setting this up. I d...
I'm running an Amazon Fire HD 7 first gen, with CyanogenMod 11 on it. Here are my system settings since they're required on Reddit:
I'm trying to set up SSH with a shared key on CyanogenMod. Normally, it's very easy to connect to my server, but I'm having difficulty setting this up.
I did
ssh-keygen -t rsa -b 4096
on my Kindle as root, because the user didn't have access to the folders (why is this, by the way? Why can't the user even see the data folder?). I put the key in the default folder with the default file name, which was

/data/.ssh/id_rsa
. Then I copied id_rsa.pub
over to the authorized_keys
file on my server, where all the other keys that work are. I restarted the SSH server, but it keeps telling me the public key failed. I ran SSh with the -vv
option, and it tells me the same thing, that the keys are not matching with the error message Permission denied (publickey)
.
What do I need to do to get the server to recognize the key?
jfa
(131 rep)
Nov 14, 2014, 07:02 PM
• Last activity: Apr 27, 2023, 09:57 AM
1
votes
2
answers
654
views
Unable to use SSH server over VPN on Android 11
I had an old mobile phone with Android 8.x Oreo. In it, I was using "[SSH/SFTP Server - Terminal][1]" app to access my files on the phone through "[WinSCP][2]" in "Windows 10". I used to do that while a VPN connection with "[UFO VPN][3]" Android app is active on the mobile phone. Now, I bought a new...
I had an old mobile phone with Android 8.x Oreo. In it, I was using "SSH/SFTP Server - Terminal " app to access my files on the phone through "WinSCP " in "Windows 10". I used to do that while a VPN connection with "UFO VPN " Android app is active on the mobile phone.
Now, I bought a new mobile phone with Android 11, when I tried to do all the things above, WinSCP refused the connection over the VPN and I can only access the files without the VPN.
I tried to solve the problem by using different SFTP server apps and VPN apps with no success.
Any help will be appreciated, with a notice that I don't want to use a normal connection on my phone.
Jameel Kalwan
Aug 23, 2021, 05:41 AM
• Last activity: Feb 18, 2023, 01:56 PM
3
votes
0
answers
1506
views
Stream video on VLC Player Android over SFTP with SSH key authorization
I would like to connect via SFTP with public/private key encryption with VLC on Android (both on my Chromecast TV and Android phone). I have installed Termux, configured my keys, and can access the SSH server via Termux. How would I supply my ssh keys to VLC?
I would like to connect via SFTP with public/private key encryption with VLC on Android (both on my Chromecast TV and Android phone).
I have installed Termux, configured my keys, and can access the SSH server via Termux. How would I supply my ssh keys to VLC?
David Alsh
Feb 12, 2023, 09:29 AM
• Last activity: Feb 12, 2023, 10:24 AM
2
votes
1
answers
1210
views
JuiceSSH on Android not accepting IPv6 address
Using a current version of [JuiceSSH][1] on Android, I'm trying to set up a New Connection to my system at fe80::f9cd::4687::90cd::5da2. I've confirmed that I can ssh to that address from a Windows machine. But when I try to save the connection in JuiceSSH it tells me "Invalid Address". (I tried sin...
Using a current version of JuiceSSH on Android, I'm trying to set up a New Connection to my system at fe80::f9cd::4687::90cd::5da2. I've confirmed that I can ssh to that address from a Windows machine. But when I try to save the connection in JuiceSSH it tells me "Invalid Address". (I tried single colons too, no improvement. I haven't tried _no_ colons yet.)
In case it matters, I'm using an Identity which has the same Private Key that I used from Windows, pasted into JuiceSSH as multiple lines between
-----BEGIN OPENSSH PRIVATE KEY-----
and -----END OPENSSH PRIVATE KEY-----
lines, which seemed to be what JuiceSSH wanted to see (?). It's an ed25519 key, which JuiceSSH claims it supports; I'm not sure whether that's supposed to be indicated explicitly somewhere. But I wouldn't expect wrong key to cause an "Invalid Address" message.
I presume I'm missing something obvious. Any ideas on what would be welcome.
(BTW, I'm perfectly willing to try other Android SSH clients, but Juice seemed to be the most commonly recommended.)
keshlam
(121 rep)
Jun 29, 2022, 09:52 PM
• Last activity: Jan 4, 2023, 05:35 PM
3
votes
0
answers
304
views
How find large files with QDirStat on Android 11 with root?
I want to list all files in my phones `/data` volume using [QDirStat][1], or something simular. On my phone, I've used [DiskUsage][2] ([`com.google.android.diskusage`][3]) before, but I find the visualization lacking. I want to apply the steps described in this guide with my phone as the remote serv...
I want to list all files in my phones
/data
volume using QDirStat , or something simular.
On my phone, I've used DiskUsage (com.google.android.diskusage
) before, but I find the visualization lacking.
I want to apply the steps described in this guide with my phone as the remote server:
### Technical details
- OnePlus phone running Android 11
- Root via Magisk
- SSH server with key-files
- GNU/Linux desktop PC
- Working SFTP mount of my phones /
(FS root) on my PC
### Goals
- Create a reading on-device using the QDirStat server script
- Run the script (folder & file indexer) on-device
- Don't index from the PC via an SFTP mount
- The script is headless: it does not contain a GUI
- Index every file & folder in /data
(as root)
- Import the index-dump into QDirStat on my PC
- Analyze the index on PC
- Manually delete some files using Nautilus' SFTP
### Questions
- The script seems to require Perl
- How can Perl be installed on Android?
- If it's installed in Termux, can it index everything?
- What would be the (most-)proper way of doing this be?
- Can I run QDirStat on an ARM arch?
- Will cross-compilation be required?
- Will cross-compiling the Qt framework be required?
- How do I provide the required libs for QDirStat?
---
Thanks for reading 🤗
Tanja
(31 rep)
Nov 19, 2022, 04:14 PM
• Last activity: Nov 19, 2022, 08:54 PM
7
votes
1
answers
5648
views
How to run SSH/SFTP server for multiple user logins with password authentication on Android?
I want to run an SSH server on my Android phone so that my clients (varying between 10 to 20) can easily and securely share data with me when I'm on the go, without using any third-party hosting services like email, file sharing, etc. Every user should have their own directory (enforced using SFTP's...
I want to run an SSH server on my Android phone so that my clients (varying between 10 to 20) can easily and securely share data with me when I'm on the go, without using any third-party hosting services like email, file sharing, etc. Every user should have their own directory (enforced using SFTP's chroot) and he/she should be able to log in using his/her own password (not the key file) I provide them, optionally sharing credentials with other users if one needs to.
I didn't find any such flexible solution, especially FOSS. So I built
sshd
program from openssh source code , using gcc-linux-aarch64
cross compiler on Ubuntu. However, when I execute it on my phone, it throws an error:
~# sshd -d
Privilege Separation user sshd does not exist
How can I add sshd
and other users on Android? My phone is rooted.
**PS:** I'm jotting down an answer to my own question of what limitations I faced and how I have been achieving this for the past few years. Any other method - particularly a non-root solution through GUI for ease of a common user - would be appreciated.
Irfan Latif
(21832 rep)
Apr 4, 2019, 12:56 PM
• Last activity: Sep 1, 2022, 08:15 AM
2
votes
1
answers
1750
views
How to connect two phones via SSH with a central SSH server?
I have two phones `A` and `B` which use Mobile Data. I would like to connect from phone `A` to phone `B`, the latter has an SSH server running on port `8022`. The central SSH server is running on AWS and has an Elastic IP. Phone `A` can connect to AWS Server directly at port `22`, so can phone `B`....
I have two phones
A
and B
which use Mobile Data. I would like to connect from phone A
to phone B
, the latter has an SSH server running on port 8022
. The central SSH server is running on AWS and has an Elastic IP.
Phone A
can connect to AWS Server directly at port 22
, so can phone B
.
AWS Server configuration:
GatewayPorts yes
TCP forward yes
Password Authentication Yes
Further, I have forwarded port 9099
on the AWS SSH server to local port 8022
on phone B
:
~$ ssh -NR 9099:localhost:8022 user@Remoteip
By running netstat -tpln
on the AWS SSH server, I can see that 9099
is in listening mode.
But when I ssh from phone A
into the AWS server at port 9099
, it says timed out.
Ehtizad Zashkiyor
(83 rep)
Jul 16, 2019, 12:27 PM
• Last activity: Sep 1, 2022, 08:11 AM
Showing page 1 of 20 total questions