Hello,
I am primarily a windows user but have tinkered with various Linux distros over the years. Really enjoying running the latest Opensuse 42.1 with the kde desktop.
My wife wants me to root her Moto G 1st edition, which I did a few years ago on Windows 7.
Curious to know how Opensuse and ADB/Fastboot play when it comes to rooting, flashing factory images etc?
With windows 7 I found it pretty straight forward, however I seem to remember it was a bit of a nightmare on Ubuntu getting the distro to find the phone (my HTC) and I gave up. Tried the 51 android rules and all that, but still no luck.
To get to the point, anyone have Opensuse playing nicely with their Moto G' and could post some instructions so I can get back to rooting?
Thanks,
Simply install Android Tools.
In openSUSE: http://software.opensuse.org/package/android-tools
In Ubunutu: sudo apt-get install android-tools-adb android-tools-fastboot
Tip: 'sudo' may be required to run fastboot / adb - i.e, sudo fastboot devices
Does it still need 51 android rules creating for the device? I had an awful time with permissions and trying to find the phone on Mint (Ubuntu based) last time I tried this.
Many thanks for your reply.
maritimesbob said:
Does it still need 51 android rules creating for the device? I had an awful time with permissions and trying to find the phone on Mint (Ubuntu based) last time I tried this.
Click to expand...
Click to collapse
No configuration or setup is required.
Related
For whatever reason, my GT 7+ is showing: ????????? offline/device when I run adb devices. I've tried running adb kill/start as root, still nothing. I've cycled "USB debugging". I'm running ubuntu 10.10. Every thing but adb is working but adb
Any insight or help would be helpful.
udev.
See: http://wiki.cyanogenmod.com/wiki/Udev
Answered
Here's the rule I put up in /etc/udev/rules/98-android.rules:
Code:
SUBSYSTEM=="usb", SYSFS{idVendor}=="04e8", MODE="0666" #all samsung devices
Then restart udev and then restart adb and it's up!
This method is hard to remember. You can also start adb as root with:
adb start-server
and it should work that way, at least until adb is closed. You do not have to do all the adb commands as root, only the start.
Jason_25 said:
This method is hard to remember. You can also start adb as root with:
adb start-server
and it should work that way, at least until adb is closed. You do not have to do all the adb commands as root, only the start.
Click to expand...
Click to collapse
Why do you need to remember it? Create a udev rule once and you never have to deal with it again.
Running things as root should be avoided if possible.
I have found that there may be an issue with ubuntu 10.10 and this tablet. For me, it seems that the MTP crud is interfering with adb. If I freeze the MTP application on the tablet, I have no problem.
...and now it gets even stranger: If I boot ubuntu 10.10 in a virtual machine (vmware 8.x), its fine even with mtp enabled.
I haven't had any issue at all with my gentoo boot. (However, I've been trying to do the android development with ubuntu as it appears to be directly supported by google.)
(This really isn't an issue for me, as I actually prefer to keep MTP disabled so I don't get popups.)
Entropy512 said:
Why do you need to remember it? Create a udev rule once and you never have to deal with it again.
Running things as root should be avoided if possible.
Click to expand...
Click to collapse
Because I work on computers other than my own?
Because I have more than one computer?
Because I sometime reinstall the OS?
Because I don't have magical fail-proof hardware?
Because udev gets messed up and apt-get replaces the rules file?
This method is simpler for new users. The adb tools are straight from google so can be trusted and the udev approach just adds a lot of complexity.
edit:
garyd9 said:
I have found that there may be an issue with ubuntu 10.10 and this tablet. For me, it seems that the MTP crud is interfering with adb. If I freeze the MTP application on the tablet, I have no problem.
Click to expand...
Click to collapse
I do not seem to have any problem using 64-bit debian, which you probably know Ubuntu is based on. I have even built the AOSP with it without much trouble. Though, deploying it to a device is a different matter for me.
Well i wanted to develop some Roms from scratch! so i decided to get hold of VirtualBox abd Ubuntu!
I downloaded virtualBox 4.2.6 and Went to their site downloaded
Ubuntu 10.4 VDI
After Starting the VDI i am getting stuck at this window.
Cant run it..Help me guys?
-Rik[Rittik]
What do You mean by "stuck"? It seems that You downloaded server version of Ubuntu 12.04.2 which doesn't have any GUI installed by default (I assume that this is the problem).
Just like ximian said. Server version does not come with GUI.
You can still install it with command: sudo apt-get install ubuntu-desktop
Or download desktop version.
O thanks a lot
-Rik[Rittik]
Hello,
I just got a new U11, hoping to use it to test/debug my Android apps. But I cannot get it connect to ADB reliably. I have tried everything I could, including
enabling developer options + USB debugging
adb kill-server, adb start-server and adb devices
revoking USB debugging authorizations
authorizing & remembering my PC
I've tried countless combinations of the above, but adb keeps showing unauthorized or offline. Very very occasionally adb shows "connected", but Android Studio freezes when I run my app. When I unplug, Android Studio immediately unfreezes. But again, when I plug my phone it becomes unauthorized/offline.
My other Android phone works without any issues. Is it a bug with the stock firmware?
The phone is running stock European firmware, with everything stock (including locked bootloader).
Could anyone please test/confirm this on their Linux laptop/desktop? Any fixes? Thanks a lot!
Strangely, it works on Windows. Maybe Ubuntu kernel update yesterday broke adb :crying:
I get my phone tomorrow and will update adb and try to connect. Have you tried starting the adb server as root?
sudo adb start-server
Sent from my XT1575 using Tapatalk
drzoo2 said:
I get my phone tomorrow and will update adb and try to connect. Have you tried starting the adb server as root?
sudo adb start-server
Click to expand...
Click to collapse
Yes, I did all adb commands after $ sudo -s
As it works without any problems on Windows, perhaps I should ask on a Linux forum?
For now I would use Windows until I found a solution
spolarbear said:
Yes, I did all adb commands after $ sudo -s
As it works without any problems on Windows, perhaps I should ask on a Linux forum?
For now I would use Windows until I found a solution
Click to expand...
Click to collapse
I have the same problem.
I have Debian in my computer (MSI GS40 6QE) and in my girlfriend's computer (Asus UX32V) . Same update state in both of them.
I'm unable to use adb or fastboot in my computer but it works correctly in my girlfriend's computer.
microcris said:
I have the same problem.
I have Debian in my computer (MSI GS40 6QE) and in my girlfriend's computer (Asus UX32V) . Same update state in both of them.
I'm unable to use adb or fastboot in my computer but it works correctly in my girlfriend's computer.
Click to expand...
Click to collapse
Haha, at least the issue is not unique to my phone (and laptop) :laugh:
I suspect Android SDK is most well tested on Windows, at least everything is already set up for you. But Linux allows you to run most dev tools in your HOME folder, so they don't mess things up.
Hopefully someone comes up with a fix.
My Xiaomi running LineageOS (basically AOSP) doesn't have any issue. Perhaps HTC Sense heavily modified some USB options?
spolarbear said:
Haha, at least the issue is not unique to my phone (and laptop) :laugh:
I suspect Android SDK is most well tested on Windows, at least everything is already set up for you. But Linux allows you to run most dev tools in your HOME folder, so they don't mess things up.
Hopefully someone comes up with a fix.
Click to expand...
Click to collapse
I have no problem with my M8 and my computer.
Android "is" Linux. By that, at least, tools like adb and fastboot must be very well tested under Linux :angel:.
Try to open you computer file browser and to browse or copy some files from/to your computer/phone. I'm unable to do that also.
I tried to root my phone in the same day I received it and I was getting really worried because I was unable to use fastboot (I by that I was thinking that my device was defective), even the simple "fastboot getvar all". Then I remembered to switch to another computer and voilà, everything was working perfectly.
Maybe HTC has something broken in the USB3.0 stack.
File transfer and fastboot don't work on my Ubuntu either.
spolarbear said:
File transfer and fastboot don't work on my Ubuntu either.
Click to expand...
Click to collapse
I don't know if it related with kernel (in computer side). I already tried version 4.9, 4.10 and 4.11 (the one I'm running right now).
microcris said:
I don't know if it related with kernel (in computer side). I already tried version 4.9, 4.10 and 4.11 (the one I'm running right now).
Click to expand...
Click to collapse
I tried 4.10 and 4.4, neither worked
I have same problem with Windows 10 64Bit.
All working fine here.
Sounds like udev. Have you followed the setting up usb access part of
https://source.android.com/source/initializing?
I have solved my problem. I have install Windows 10 new and now all working.
Flinny said:
All working fine here.
Sounds like udev. Have you followed the setting up usb access part of
https://source.android.com/source/initializing?
Click to expand...
Click to collapse
What Linux distro/version are you running? I've been trying to get this working with Arch and it's driving me nuts!
I run various flavours of Debian and Ubuntu across my machines and have ADB working on them all..
Flinny said:
All working fine here.
Sounds like udev. Have you followed the setting up usb access part of
https://source.android.com/source/initializing?
Click to expand...
Click to collapse
Flinny said:
I run various flavours of Debian and Ubuntu across my machines and have ADB working on them all..
Click to expand...
Click to collapse
Got it working by downloading adb straight from Google instead of using the Arch package.
Personally, after Windows 8, followed by Windows 10, I started to seriously look into Linux (which is free) as my primary desktop. Today LibreOffice (which is free) has more features than Microsoft Office and can open, edit, and save all of Microsoft Office's documents. Thanks to Steam's new deployment, I can even now run my Windows-only games on Linux too. The one thing I found very hard to swallow was trying to get my Andriod device (which is technically Unix too) to actually connect to my computer and I imagine that is because the documentation (even via a Google search) to using ADB or Fast Boot with Linux seems to be hidden among pages upon pages of Windows users.
For simple ease of reference as I couldn't even find this here on XDA, allow me to correct the matter.
Type out (or copy and paste) the following commands to install ADB and Fastboot.
Code:
sudo apt-get install adb
sudo apt-get install fastboot
Now you have both adb and fastboot installed. Next, you'll need to enable adb.
Code:
sudo adb
Now boot your phone to your bootloader screen (you get there by pressing both your power and lower volume keys at the same time). Once there load TWRP with the following command.
Code:
sudo fastboot boot '/your_path_here/twrp-3.2.3-0-payton.img'
Your path will be wherever you happen to have downloaded your copy of TWRP. From there I was able to successfully mount my device within TWRP and upload my ROM zip file as needed.
You will upload files to your phone using the "ADB PUSH" command to your /sdcard/ directory (as admin in windows or root in Linux). For example:
Code:
adb push lineage-16.0-20180921-UNOFFICIAL-payton.zip /sdcard/
I hope this was helpful.
Note: Because you're doing this in Linux, the files you upload to your phone may not have the correct permission settings (chmod settings) after they are uploaded. This is very unlikely, but still technically possible.
Thankfully, the folks at TWRP have thought of this and in the 'Advanced' menu, you will find a file manager. From there select the file of your choice and click the chmod button that reads "chmod 0777". Don't forget to mount the DATA partition (before using the file manager) else you may not see the file you are looking for.
or just download the package from here
https://developer.android.com/studio/releases/platform-tools
unzip and have fun
munchy_cool said:
or just download the package from here
https://developer.android.com/studio/releases/platform-tools
unzip and have fun
Click to expand...
Click to collapse
This is helpful, but most newbies to Linux wouldn't even know how to execute those base files. lol But Windows users coming to Linux do know how to run command prompts (good old Microsoft kept the command prompt around long enough that folks moving to Linux just associate the terminal in the same light). Which is why I thought to have them install a preconfigured program would be easier.
But thanks for the source. It is still useful.
MotoX4 said:
This is helpful, but most newbies to Linux wouldn't even know how to execute those base files. lol But Windows users coming to Linux do know how to run command prompts (good old Microsoft kept the command prompt around long enough that folks moving to Linux just associate the terminal in the same light). Which is why I thought to have them install a preconfigured program would be easier.
But thanks for the source. It is still useful.
Click to expand...
Click to collapse
lol..i thought the first thing a Linux newbie would learn is command prompt.
you need to read about terminal before you decide using a Linux box.
munchy_cool said:
lol.. I thought the first thing a Linux newbie would learn is the command prompt.
you need to read about terminal before you decide using a Linux box.
Click to expand...
Click to collapse
:laugh: I agree. But there are a lot of folks who feel intimidated whenever learning something new. If I had started this thread with a full introduction to manually configuring and executing everything, most folks would have easily been discouraged. Especially the younger or older generations who fall somewhere between the line of "I don't got time for that" or "why so difficult". lol :laugh: Inoculating folks into using Linux I feel works best. Keep it simple and suggest that there are more in-depth ways of doing things to peak curiosity. -- Which is why I'm glad you pointed that out and why I'm loving writing this reply at the moment. :angel:
The unlock tool by fernando does not seem to work anymore . I don't own a windows machine, is there anyway to unlock X3 bootloader using linux? Thanks!
elementtest8 said:
The unlock tool by fernando does not seem to work anymore . I don't own a windows machine, is there anyway to unlock X3 bootloader using linux? Thanks!
Click to expand...
Click to collapse
X3 ? Wrong forum.
You can try some Windows bootable flash drive.
pl1992aw said:
X3 ? Wrong forum.
You can try some Windows bootable flash drive. I have the right forum I believe.
Click to expand...
Click to collapse
I'd like to know how how to unlock my Xiaomi Poco X3 Pro using a linux OS. I have tried virtualbox, ventoy ( to make a windows bootable), and Francesco Tescari's unlock tool. All three methods have failed for me and I don't have access to a windows computer. Have been trying to solve this problem for multiple weeks now.
bit of an update with the struggle. I have set up a fairly functional windows VM using this guide:
How to set up a KVM / QEMU Windows 10 VM
Over the weekend, I wiped Windows on my Zephyrus G14 and installed Pop!_OS on it. I’ve been trying to get a Windows 10 Virtual Machine as I need it for school. It’s also great to have a setup like…
raphtlw.medium.com
and have gotten the xioami unlock tool working within the virtual machine.
However, the USB is not recognized so it wont connect to my phone to unlock it.
Trying to look into permissions maybe? They recommended using gksu to open virt-manager but that is now deprecated... Hard problem... Feel so much closer using QEMU virtual machine, but still won't recognize my poco x3 pro
elementtest8 said:
Trying to look into permissions maybe? They recommended using gksu to open virt-manager but that is now deprecated... Hard problem... Feel so much closer using QEMU virtual machine, but still won't recognize my poco x3 pro
Click to expand...
Click to collapse
Make a bootable Windows from a flash drive.
Boot Windows without using virtual machine.
Example :
How to Run Windows From a USB Drive
Loading and running Windows 10 or Windows 11 from a USB drive is a handy option when you're using a computer saddled with an older operating system.
www.pcmag.com
just make a bootable windows from flashdrive using rufus
Thanks for the post guys. Unfortunately I couldn't get the thumb drives to work
I have solved the issue and I am posting the solution I found just in case anyone else happens to stumble on this post: fyi, I had a POCO x3 Pro and this worked in March 2022
sudo apt install git openjdk-11-jre openjdk-11-jdk gradle` - I am not sure all of this is required
mkdir xiaomi_unlock && cd xiaomi_unlock (make a directory before copying all the files over in step 3 to make it more organized
git clone https://github.com/francescotescari/XiaoMiToolV2.git && cd XiaoMiToolV2 && git checkout linux`
cd XiaoMiToolV2`
./gradlew build && ./gradlew run`
The xiaomi program should run. When prompted, I chose "Global" region and logged in
(possible step) had an error with my java version not syncing I had to set the home variable
I had to enter this command to make it work
export JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64/
if you are running ubuntu and or mint you might find the same solution there. Google where your java is installed and play around setting the JAVA_HOME. Took me 2 or 3 attempts before I finally found the right one
TLDR: how to unlock POCO X3 PRO using linux mint / ubuntu in March 2022
elementtest8 said:
Thanks for the post guys. Unfortunately I couldn't get the thumb drives to work
I have solved the issue and I am posting the solution I found just in case anyone else happens to stumble on this post: fyi, I had a POCO x3 Pro and this worked in March 2022
sudo apt install git openjdk-11-jre openjdk-11-jdk gradle` - I am not sure all of this is required
mkdir xiaomi_unlock && cd xiaomi_unlock (make a directory before copying all the files over in step 3 to make it more organized
git clone https://github.com/francescotescari/XiaoMiToolV2.git && cd XiaoMiToolV2 && git checkout linux`
cd XiaoMiToolV2`
./gradlew build && ./gradlew run`
The xiaomi program should run. When prompted, I chose "Global" region and logged in
(possible step) had an error with my java version not syncing I had to set the home variable
I had to enter this command to make it work
export JAVA_HOME=/usr/lib/jvm/java-11-openjdk-amd64/
if you are running ubuntu and or mint you might find the same solution there. Google where your java is installed and play around setting the JAVA_HOME. Took me 2 or 3 attempts before I finally found the right one
TLDR: how to unlock POCO X3 PRO using linux mint / ubuntu in March 2022
Click to expand...
Click to collapse
People running into the captcha problem on login (it isn't shown) can try a patched version. Just replace step 3 with:
git clone https://github.com/Dav4555/XiaoMiToolV2_urlfix_captchafix && cd XiaoMiToolV2 && git checkout linux
homeboot said:
People running into the captcha problem on login (it isn't shown) can try a patched version. Just replace step 3 with:
git clone https://github.com/Dav4555/XiaoMiToolV2_urlfix_captchafix && cd XiaoMiToolV2 && git checkout linux
Click to expand...
Click to collapse
Apparently unlocking doesn't work anymore. I have to wait a week to check.
The original unlock tool works with a Windows guest inside Virtualbox on my Debian Testing. I used a developer VM one can download for free. Rename the downloaded file to windev_VM_virtualbox.zip, unzip it and import the appliance in virtualbox. Make sure your current user is a member of the vboxuser group to make USB pass-through work. You may or may not need the guest extensions, I installed them.