Ubuntu 12.10 to 13.04 Server Upgrade Error

computer 26 April 2013 | 9 Comments

Are you Googl’ing around trying to figure out why you’re getting this error when trying to `do-release-upgrade’ your Ubuntu 12.10 system, even though you’re pretty much up to date?

root@mia:~# do-release-upgrade
Checking for a new Ubuntu release
Traceback (most recent call last):
File “/usr/bin/do-release-upgrade”, line 145, in <module>
fetcher.run_options += [“–mode=%s” % options.mode,
AttributeError: type object ‘DistUpgradeFetcherCore’ has no attribute ‘run_options’
Error in sys.excepthook:
Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/apport_python_hook.py”, line 137, in apport_excepthook
os.O_WRONLY | os.O_CREAT | os.O_EXCL, 0o640), ‘wb’) as f:
OSError: [Errno 2] No such file or directory: ‘/var/crash/_usr_bin_do-release-upgrade.0.crash’

Original exception was:
Traceback (most recent call last):
File “/usr/bin/do-release-upgrade”, line 145, in <module>
fetcher.run_options += [“–mode=%s” % options.mode,
AttributeError: type object ‘DistUpgradeFetcherCore’ has no attribute ‘run_options’
root@mia:~#
deb http://gb.archive.ubuntu.com/ubuntu/ quantal-updates main restricted
deb-src http://gb.archive.ubuntu.com/ubuntu/ quantal-updates main restricted

I just burned a couple hours trying to figure out why I only got this error on one specific server. It turns out that it’s a bug in the version of ¬†the¬†ubuntu-release-upgrader-core package, and you must be pulling updates from a “quantal-updates” repository to get the fixed package when you `apt-get upgrade’. To fix this, edit your /etc/apt/sources.list and make sure you have the following two lines:

deb http://gb.archive.ubuntu.com/ubuntu/ quantal-updates main restricted
deb-src http://gb.archive.ubuntu.com/ubuntu/ quantal-updates main restricted

After making sure you have these lines, get yourself updated again and re-try the release upgrade script:

apt-get update
apt-get upgrade
do-release-upgrade

…and you should be rollin’ towards Raring!

Tagged in , , ,

9 Responses on “Ubuntu 12.10 to 13.04 Server Upgrade Error”

  1. Chris says:

    Thanks, this worked perfectly for my PPC upgrade as well.

  2. apanloco says:

    Thanks. That’s why I haven’t gotten any updates on my Quantal server for half a year. Anyone knows why quantal-updates isn’t added as default?

  3. Alexander Malahov says:

    Just curious, how have you figured this out ? And thanks for sharing, it worked.

  4. preston.lee says:

    I don’t recall, but glad you got it working!

  5. Marco says:

    Thanks,
    it worked for me…

  6. Jarek says:

    Thanks Preston. I couldn’t solve it myself. Probably the problem lies in the fact, that I didn’t find any decent description of the correct sources.list file for ubuntu and I was editing it by trial-and-error.

  7. Tom says:

    Preston, thank you so much for this! No doubt this saved me hours of detective work. If you’re ever in Newark, Delaware, consider yourself due at least a few tall, cool, frothy beverages at the Deer Park!

  8. Dickie says:

    Thanks for this info, very helpful.

  9. Run says:

    thank you

Leave a Reply