Error in do-release-upgrade from saucy to trusty

Asked by Graeme Merrall

Attempting in in-place upgrade of saucy to trusty using "do-release-upgrade". I get an error returned "The value 'saucy' is invalid for APT::Default-Release as such a release is not available in the sources". From some reading this seems to be an issue with 3rd party sources but I've commented those out.

1. Edit /etc/apt/sources.list to pull out everything not critical. This was just "saucy main restricted" and "saucy-updates main restricted"
2. Removed anything 3rd party from sources.list.d
3. sudo apt-get update
4. sudo apt-get dist-upgrade
5. sudo do-release-upgrade

There's a failure when manipulating the sources.list file in the upgrade process. The log file shows the following
2014-10-19 03:17:15,237 DEBUG updateSourcesList()
2014-10-19 03:17:15,301 DEBUG rewriteSourcesList()
2014-10-19 03:17:15,303 DEBUG examining: 'deb http://us.archive.ubuntu.com/ubuntu/ saucy main restricted'
2014-10-19 03:17:15,303 DEBUG entry 'deb http://us.archive.ubuntu.com/ubuntu/ trusty main restricted' updated to new dist
2014-10-19 03:17:15,303 DEBUG examining: 'deb http://us.archive.ubuntu.com/ubuntu/ saucy-updates main restricted'
2014-10-19 03:17:15,303 DEBUG entry 'deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates main restricted' updated to new dist
2014-10-19 03:17:15,304 DEBUG examining: 'deb http://security.ubuntu.com/ubuntu saucy-security main restricted'
2014-10-19 03:17:15,304 DEBUG entry 'deb http://security.ubuntu.com/ubuntu trusty-security main restricted' updated to new dist
2014-10-19 03:17:15,305 DEBUG running doUpdate() (showErrors=True)
2014-10-19 03:17:19,499 DEBUG openCache()
2014-10-19 03:17:19,499 DEBUG failed to SystemUnLock() (E:Not locked)
2014-10-19 03:17:20,686 ERROR not handled exception:
Traceback (most recent call last):

  File "/tmp/ubuntu-release-upgrader-7kj7sk/trusty", line 10, in <module>
    sys.exit(main())

  File "/tmp/ubuntu-release-upgrader-7kj7sk/DistUpgrade/DistUpgradeMain.py", line 244, in main
    if app.run():

  File "/tmp/ubuntu-release-upgrader-7kj7sk/DistUpgrade/DistUpgradeController.py", line 1827, in run
    return self.fullUpgrade()

  File "/tmp/ubuntu-release-upgrader-7kj7sk/DistUpgrade/DistUpgradeController.py", line 1736, in fullUpgrade
    self.openCache(restore_sources_list_on_fail=True)

  File "/tmp/ubuntu-release-upgrader-7kj7sk/DistUpgrade/DistUpgradeController.py", line 219, in openCache
    return self._openCache(lock)
  File "/tmp/ubuntu-release-upgrader-7kj7sk/DistUpgrade/DistUpgradeController.py", line 247, in _openCache
    lock)

  File "/tmp/ubuntu-release-upgrader-7kj7sk/DistUpgrade/DistUpgradeCache.py", line 116, in __init__
    apt.Cache.__init__(self, progress)

  File "/usr/lib/python2.7/dist-packages/apt/cache.py", line 105, in __init__
    self.open(progress)

  File "/usr/lib/python2.7/dist-packages/apt/cache.py", line 150, in open
    self._cache = apt_pkg.Cache(progress)

SystemError: E:The value 'saucy' is invalid for APT::Default-Release as such a release is not available in the sources

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
Manfred Hampl
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

http://askubuntu.com/questions/444463/e-the-value-saucy-is-invalid-for-apt

States:

SOLVED: edit (change "saucy" to "trusty") /root/.synaptic/synaptic.conf

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#2

Personally, I have seen too many issues with online upgrades and suggest you do a final full backup of your data then clean install Trusty. You could always clean install with Trusty if the upgrade fails but be sure you have the backup before you start any of this stuff so that your important data is safe.

Revision history for this message
Graeme Merrall (graeme-h) said :
#3

This is server so I can't use synaptic. All cmdline only. As a result there's no synaptic files to edit.

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#4

If it's a desktop OS, try installing synaptic and use that

Revision history for this message
Manfred Hampl (m-hampl) said :
#5

what is the output of

cat /etc/apt/apt.conf

Revision history for this message
Manfred Hampl (m-hampl) said :
#6

and the output of

grep saucy /etc/apt/apt.conf.d/*

Revision history for this message
Graeme Merrall (graeme-h) said :
#7

$ cat /etc/apt/apt.conf
APT::Default-Release "saucy";

$ grep saucy /etc/apt/apt.conf.d/*
<no output>

Revision history for this message
Best Manfred Hampl (m-hampl) said :
#8

Try

sudo rm /etc/apt/apt.conf

and retry updating.

Revision history for this message
Graeme Merrall (graeme-h) said :
#9

That did the trick. Thanks very much!

Revision history for this message
Graeme Merrall (graeme-h) said :
#10

Thanks Manfred Hampl, that solved my question.