Genymobile / gnirehtet

Gnirehtet provides reverse tethering for Android
Apache License 2.0
6.3k stars 579 forks source link

Cannot start client #255

Open JU5T1C3 opened 4 years ago

JU5T1C3 commented 4 years ago

Hi, I'm using the Rust version for macOS64 in Version 2.2.1 on my Mojave MacBook Pro, old Samsung phone with Android 5.0.1 is connected via cable and adapter. I'm following your guidelines for the simple run by calling ./gnirehtet run, this is the output:

2019-12-23 17:22:42.984 INFO Main: Starting relay server... 2019-12-23 17:22:42.983 INFO Main: Checking gnirehtet client... 2019-12-23 17:22:42.985 INFO Relay: Relay server started 2019-12-23 17:22:42.987 ERROR Main: Cannot start client: Command adb ["shell", "dumpsys", "package", "com.genymobile.gnirehtet"] failed: No such file or directory (os error 2)

Any ideas on that?

rom1v commented 4 years ago

You need adb in your PATH. You should be able to execute for example adb devices.

JU5T1C3 commented 4 years ago

You're right, i fixed that in the meantime, it's now working better; but the connection interrupts after a few seconds:

thread 'main' panicked at 'calledResult::unwrap()on anErrvalue: Error { repr: Os { code: 2, message: "No such file or directory" } }', src/libcore/result.rs:916:5 note: Run withRUST_BACKTRACE=1for a backtrace.

So i had a stable connection for a few seconds and did some page calls in the browser, but for doing some recovery stuff on that old phone it's too unstable..

lajtmaN commented 7 months ago

I had some issues getting adb to work correctly, so at some point I added an alias for adb which pointed to the install directory - and then I forgot everything about it.

But I was getting the same errors as this thread. I fixed the "adb command not found" issue (by brew install android-platform-tools) and then gnirehtet started working as well.