Search This Blog

Wednesday, 3 June 2015

Xperia Z3 Compact Tethering Problems



I have been using Android now for many years now. Since Genesis, if you will. My first Android handset was the first Android handset; the T-Mobile G1 (A.K.A. the HTC Dream) I still to this day have fond memories of that old chunky device, with it's flip out screen, and little rollerball.

Times change, hardware fails and software is updated, and I find myself today using a Sony Xperia Z3 Compact (D5803) running Android 5.0.2 (Lollipop), this is build number 23.1.A.1.28. This originally shipped with Android 4.4.4 (KitKat), and was upgraded earlier this year. I am also on the Three UK network.

Since the upgrade, I have had troubles with the Tethering functions on the phone. When I enable the Tethering (via WiFi or USB), I received an error message stating "An error occurred during tethering". No further explanation or error, just nothing. The service is enabled, and my laptop can obtain an IP Address via DHCP, however when trying to browse the web, no DNS names are resolved. I tried all manner of things to try to work around this; manually specifying DNS entries, manually specifying IP Addresses, using third party apps from the Google Play Store, but nothing would fix the issues.

ThreeUK have been unable to provide any sensible support, and Sony have confirmed that there is some sort of issue which they would fix in a future update. However, tethering is a very useful function, which I tend to rely on when travelling.

After much frustration, and hours of trawling the Internet, I came upon a couple of posts, which in combination have fixed this issue for me, and I can now tether my phone. In fact, I'm writing this blog post whilst travelling into London on a train.

DISCLAIMER: The steps below fixed my issue, however I am an impatient sod, who doesn't mind getting my hands dirty and risk "bricking" my phone. If you are uncertain of the steps you are taking, and if you are more risk averse, then please do not follow these steps. I am listing them here in the hopes that some other people out there the world wide web will benefit from them. Please do not approach me if your phone does not function after following these steps, I can not be held accountable.

Now, on with the story...

I used an Ubuntu based distribution installed on my laptop to complete these steps, if you are a Windows user, you will need to obtain the Android SDK from the Android Developers site in order to conduct this fix. The steps for obtaining this are well documented and LifeHacker have a great article about this, you'll also need the relevant drivers for your Xperia phone, which you can obtain from the Sony Developers website (links will open in a new browser window).


OK, so for Linux, you firstly need to launch a Terminal window. This can be done from the Applications Menu, or on some distributions, by pressing CTRL+ALT+T.
type the following command into the Terminal window to install the tools:

sudo apt-get update
sudo apt-get install android-tools-adb

Enter your current user account password to authorise the install, you may also need to type Y to accept the installation.

Once the software installation is complete, grab your phone and enable USB Debugging:

This can be found in Settings > Developer Options > tick USB Debugging

If you don't see "Developer Options" in your settings menu, go to Settings > About Phone, find the entry for "Build Number", and the tap on it repeatedly until you see a message stating that you are now a developer. Head back a page to your Settings menu, and you should now have Developer Options available to you.

Plug your phone into your PC/Laptop, and if prompted, accept any pop-up messages on your phones screen relating to debugging connections from your PC/Laptop.

Now head back to the terminal, and type the following command:

adb devices -l

This should show you an android device connected to your PC/Laptop and look something along the lines of:

user@laptop:~$ adb device -l
0123456ab789 device usb:2-1.1 product: Sony model: D5803


Next, type the following to enter the Shell Prompt for ADB:

adb shell

Once in the Shell, we need to alter a setting within Android itself. This is the point of no return. If you're unsteady or nervous, quit the ADB shell now.

Type the following command to make the required change:


settings put global tether_dun_required 0

That should be that. Now reboot your phone by typing the following command into the ADB Shell:

reboot

Your phone will now reboot, and you can now quit the ADB Shell and close the Terminal window.

Once your phone has rebooted (if indeed it has), go to your Settings menu, and enable tethering. You should find that everything is now working as it should be.

If you have any questions or comments, please leave them in the section below, and I'll do my utmost to answer them.

Thanks go to:
conceptxo on Redditand also to the good folks at tamingthedroid.com