Error while upgrading from 15.10 to 16.04 Beta 2

i tried to upgrade from Ubuntu Mate 15.10 to 16.04 but i get this error message :

ubuntu@ubuntumate:~$ sudo update-manager -d
Checking for a new Ubuntu release
Gtk-Message: GtkDialog mapped without a transient parent. This is discouraged.
java version “1.7.0_95”
OpenJDK Runtime Environment (IcedTea 2.6.4) (7u95-2.6.4-0ubuntu0.15.10.2)
OpenJDK Server VM (build 24.95-b01, mixed mode)
authenticate ‘xenial.tar.gz’ against ‘xenial.tar.gz.gpg’
extracting ‘xenial.tar.gz’
Traceback (most recent call last):
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/xenial”, line 8, in
sys.exit(main())
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/DistUpgrade/DistUpgradeMain.py”, line 229, in main
app = DistUpgradeController(view, options, datadir=options.datadir)
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/DistUpgrade/DistUpgradeController.py”, line 159, in init
self.quirks = DistUpgradeQuirks(self, self.config)
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/DistUpgrade/DistUpgradeQuirks.py”, line 63, in init
self._uid = os.environ[‘SUDO_UID’]
File “/usr/lib/python3.4/os.py”, line 633, in getitem
raise KeyError(key) from None
KeyError: ‘SUDO_UID’
Error in sys.excepthook:
Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/problem_report.py”, line 480, in add_to_existing
self.write(f)
File “/usr/lib/python3/dist-packages/problem_report.py”, line 435, in write
crc = zlib.crc32(block, crc)
TypeError: ‘str’ does not support the buffer interface

Original exception was:
Traceback (most recent call last):
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/xenial”, line 8, in
sys.exit(main())
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/DistUpgrade/DistUpgradeMain.py”, line 229, in main
app = DistUpgradeController(view, options, datadir=options.datadir)
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/DistUpgrade/DistUpgradeController.py”, line 159, in init
self.quirks = DistUpgradeQuirks(self, self.config)
File “/tmp/ubuntu-release-upgrader-2_7u7qq5/DistUpgrade/DistUpgradeQuirks.py”, line 63, in init
self._uid = os.environ[‘SUDO_UID’]
File “/usr/lib/python3.4/os.py”, line 633, in getitem
raise KeyError(key) from None
KeyError: ‘SUDO_UID’

Hi Med_Medin

I had a look here

and I wonder if you still have a active ppa. If so, you need to shut it down. During a version upgrade, all ppa’s should be disabled.

Thanks, i disabled all active ppas and tried upgrade process again but i got the same error message as above.

Hmmm

With PPAs disabled run a upgrade

Code:
sudo apt-get update && sudo apt-get dist-upgrade

and try a version upgrade again. Also…

Anything in your regular sources that could cause this?

Code:
inxi -r

What method did you use to update?:

See also:

Don’t run update-manager as root – don’t use sudo.

“update-manager -d” is all you need.

i always do those steps before running an upgrade.

I did an upgrade without sudo, but while upgrading it prompts to enter super user password and it gives the same error.

I use the following steps :

  1. run sudo apt-get update
  2. run sudo apt-get upgrade
  3. run sudo apt-get dist-upgrade
  4. run sudo update-manager -d

A bug report has just been filed:

https://bugs.launchpad.net/ubuntu/+source/ubuntu-release-upgrader/+bug/1570947

Thanks i will follow reponses to that bug :slight_smile: .

Hi Dave,

I thought you could only do a complete system update with “sudo” if integral parts of the system are updating?. :confused:

The complete complicated answer involves dbus permissions and keeping the system
from sleeping while upgrading. The latter is why there was an upgrade problem.

The simple answer is: It is considered bad practice to run any GUI tool and the
GUI libraries as ROOT. sudo {gui tool} elevates privilege for a lot of code and
can cause a lot of damage if there is a bug. Let the tool ask for elevated
privilege only for the code that it needs to run as ROOT.


I just upgraded a test system from 15.10 to 16.04 and it seems that the upgrade
problem is fixed for now.

I don’t think you need the -d now either.

I would do the upgrade a step at a time looking for any errors:

sudo apt update
sudo apt upgrade
sudo do-release-upgrade -d

You should see that you downloaded a new “xenial” update script.

1 Like

That bug is fixed now :slight_smile:

1 Like

Hi @Dave_Barnes,

this is what I meant which is also what I put in the upgrade via terminal guide!. :smiley: