[SOLVED] Trouble installing Ubuntu Touch on LG Nexus 5
-
This post is deleted! -
This post is deleted! -
Couple of quick things windows works best with 15 sec adb https://forum.xda-developers.com/showthread.php?t=2588979 and try a few different usb cables. Someone tried 5 before the install worked without changing anything else. If your phone was encrypted factory reset it(which you have). Good luck back later.
-
I made it work with a bootable usb of 18.04, not a VM. It might make a difference...
i also remember while struggling in windows that I gave a try to the manual install. so if I had a lot of luck the install through linux failed in the middle for me as well, but I had the correct files pushed on the memory from before and it worked:/
i don't know if you refer to my previous post were I suggest using bootable usb, but I'll edit it anyway after I know more about the story if its induces mistakes!
-
You might want to check out "Nexus Root Toolkit". It's a Windows program that wraps up various solutions. For example, it will walk you through installing the proper drivers, adb, fastboot just so. Also, it can restore stock roms which is nice if you're getting worried about owning a brick. It is a little out-of-date (still wants an older version of TWRP for one of its steps, not a big deal), but I found it worked well for my Nexus 7 2013.
Note that the UT installer didn't recognize my device either. I always had to select it by hand.
I also installed Ubuntu 18 in a VM using VirtualBox. Then, also Ubuntu 16 the same way. What ultimately worked for me was ubuntu-device-flash (only available in 16 afaik, it's the old way I think), though my case was strange and I'm not recommending that for you.
It was definitely a bit tricky to get my usb ports working in the VM. I had to go into the vm setting and add them (and they changed a few times as I re-installed windows drivers). My impression is that you still need to get the usb drives for windows right as the VM piggybacks on those. Even so, I was still unplugging and re-plugging the device at times to get the usb connection to wake up.
The manual install is doable, probably a little easier on Ubuntu as it needs wget and a couple other things that are not native to Windows (but I was able to install them without much trouble). Doing it manual can help you zero-in on the problem as I found certain steps would fail. The UT installer doesn't seem to check for errors much, so it's hard to tell where it went wrong (imho). You can also use "adb shell" while in recovery to poke around on your device to see how things look (it's like a pathetic little linux install in there). If you're comfortable with that, not essential.
I had 3 cables, one of which was definitely bad. "adb devices" did not work at all for that cable. So, I doubt your cable is bad as it seems to work mostly.
I think your best bet would be to use Nexus Root Toolkit to do it's "Full driver installation guide..." (button near top). It has like 4 steps as it makes sure every little piece is right. I suspect I had initially some issue with not being in MTP mode or having some old windows drivers still installed (it made me delete devices, etc.)
Anyway, good luck!
-
This post is deleted! -
@Coluix It sounds to me as if you are almost there! A new cable may help. It does take longer than you might expect for the installation to complete.
You are not alone. It has taken me some frustrating time to migrate from one Nexus 5 on Ubports to a "new" one bu,t with help from this forum, I am at last there ...
Good luck!
-
Just wanted to update the thread as to my conclusions and potential solutions. From what I have gathered, my phone seems to have well and truly soft-bricked itself, because even on Windows and the Ubuntu VM it is not recognized properly. Both machines read the Nexus LG 5 as a generic Android device, but cannot successfully connect to it. I think this is distinct from the connectivity problems some other people in the thread encountered because the device is connecting to my computer, but the software I have cannot properly see it.
I have tried the Nexus Root Toolkit as flowbee suggested, and although it was a great resource, it too had the same problem: my device just isn't recognized when it's in bootloader mode. This means I cannot restore it to its factory settings.
I have also tried swapping USB cables, and that made no difference.
I think at this point I will be getting a new Nexus LG 5 through Kijiji or something, and then trying to install UBTouch more carefully. I am still very interested in having a glorified PDA that isn't beholden to either Apple or Google, and fortunately getting another LG 5 won't cost me more than $80 at the upper end. If nothing else, this was a learning experience.
-
Don't give up! Your device is almost certainly not bricked. If holding Power and Volume Down gives you the Fastboot bootloader screen (it looks like this), your device is perfectly recoverable.
When you told Workstation to pass through the Nexus 5 whenever it was detected, you may not have passed through the device in bootloader mode, only in booted or recovery mode. Both of these modes present different hardware IDs to the system. Can you check to make sure that the device is still passed through when it's booted in bootloader mode?
-
@UniSuperBox
Thank you for your encouragement. I just checked the thread now and for whatever reason it hadn't occurred to me that the installer would be able to recover from a partial installation. I did what you suggested (connected the device to my Windows machine, then connected it to the Ubuntu VM and ran the installer from the terminal), and it detected the device correctly.Then the following happened:
- terminal displayed some messages
info: Welcome to the UBports Installer version 0.2.6-beta! info: hammerhead selected info: Instructing manual reboot info: Press and hold the volume down and power buttons until the phone reboots. info: fastboot: wait for device info: Download complete info: Flashing images... info: Booting into recovery image... info: bootstrap done: rebooting automatically
- the device rebooted into UBports Recovery mode
- the device disconnected from my Windows machine and the Ubuntu VM, and does not appear in the Player > Removable Devices menu
- UBPorts installer currently says "Waiting for device to enter recovery mode . . ." > "Flashing recovery and boot images"
I think this is where I had disconnected it during the first installation because nothing appeared to be happening and the device seems to have disconnected. I will keep it connected now, because it's not as though I have anything else to do with it. I read a few other forum posts from people in similar situations, and one thing a couple of them had said was that the process of actually installing and booting the Ubuntu Touch files can take a very long time.
If it works itself out, I will update the thread. In the meantime, ask away if anyone has any questions.
UPDATE: I ran
adb devices
andsudo adb devices
to confirm whether or not the VM sees the device attached, and both command return an empty list of devices. I think the installation process is frozen now, but I am unsure what to do. Logically, it seems like I should reboot the device in the UBports Recovery menu, but I am not sure if that would snarl things further. -
@Coluix If all still fails try this https://github.com/ubports/ubports-installer/issues/593 scroll down till you see problem solved or such.
-
SOLVED!
It turns out that the post you linked was the ticket: one of the responses said that he had used a VM installation and that when he arrived at the same point I had, it was a simple matter of reconnecting the device. I had initially not investigated this solution because I had tried reconnecting many times, but I decided to give it a try because everything else had not worked, and it seems to have worked. My device is currently displaying "Installing update" with the UBPorts mascot and an orange dot indicating it is doing some work. I will be leaving it like that overnight just to ensure I do not bork any important operations.
For posterity, I will include a step-by-step description of what I did in case anyone else has this problem in the future. I feel pretty stupid right now, but I'm just so glad to have it working properly:
- Do the steps I described in my first post
- Get to the point in the GUI installer where it boots the device out of the Android bootloader and into the UBPorts Recovery mode (with the UBPorts mascot on the top right)
- You should have received a message from your Windows host machine that the device is unrecognizable. This does NOT mean you cannot connect it.
- Disconnect and reconnect the device to the Windows machine. If you have properly installed adb and the other preliminary files, then you should be able to connect it to the VM. In my case, I received a prompt from the VM because it recognized a device being connected.
- At this point, the GUI installer should recognize the device and its state, and begin downloading files.
- I did not experience any other issues to the end of the installation, and my device is now operational.
Thank you so much for your help, everyone. Now I just need to do this a couple more times so I have backup phones and I'll be set to check out of the Google/Apple mobile ecosystem.
-
@Coluix Good work. Enjoy UT