Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remote scrcpy #5915

Open
arsenars555 opened this issue Mar 10, 2025 · 6 comments
Open

remote scrcpy #5915

arsenars555 opened this issue Mar 10, 2025 · 6 comments

Comments

@arsenars555
Copy link

Hi. I have smartphone1 wich has ssh remote(outside my local network in other town) access to my server(server on other smartphone2 connected by wifi to my router ). Can I use ssh tunel to connect from server side smartphoe2 to smartphone1 by scrcpy ?

@rom1v
Copy link
Collaborator

rom1v commented Mar 10, 2025

@arsenars555
Copy link
Author

I've already tried.

On smartphone1 :

adb start-server
ssh -CN -L5038:localhost:5037 -R27183:localhost:27183 "phonename"@"my_router_real_IP" -p"port"

on router port forwarded for shh - and work from phone1 to phone2.

On smartphone2 :

export ADB_SERVER_SOCKET=tcp:localhost:5038
scrcpy

But it doesn't work. Maybe there are some nuances?
I have Android 7 on both phones.

@rom1v
Copy link
Collaborator

rom1v commented Mar 11, 2025

Does it work with local port forwarding (section To avoid enabling remote port forwarding… in the documentation)?

@arsenars555
Copy link
Author

arsenars555 commented Mar 12, 2025

with local port forwarding on smartphone2 I have this:

~ $ export ADB_SERVER_SOCKET=tcp:localhost:5038
~ $ scrcpy --force-adb-forward
scrcpy 3.1 https://github.com/Genymobile/scrcpy
ERROR: Could not initialize SDL audio: Could not setup connection to PulseAudio

@rom1v
Copy link
Collaborator

rom1v commented Mar 12, 2025

Add --no-audio just to test.

@arsenars555
Copy link
Author

~ $ export ADB_SERVER_SOCKET=tcp:localhost:5038
~ $ scrcpy --force-adb-forward --no-audio
scrcpy 3.1 https://github.com/Genymobile/scrcpy

and nothing hapened - no error, no answer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants