Edubuntu / Elementary OS  troubleshooting.

'How do I fix'

I was trying to get an old Edubuntu / Elementary OS Luna laptop with a broken software centre and update manager to update and install apps again.

Typical errors include 404 errors on the update manager or apt-get or strange curl errors that give the impression the CA list is broken.(hint: it isnt)

Equally under the software centre you would get strange dependancy errors or worse.

Examples:

In apt-get 404 Not Found
In software centre elementary luna error =0.3.1-1 and a missing install button
In apt-get - pycurl.error: (60, 'server certificate verification failed. CAfile: /etc/ssl/certs/ca-certificates.crt CRLfile: none')

 

The problem turned out to be as simple as the sources file being out of date - because the stupid millenials running the repositories decided they were "obsolete" or "discontinued" without telling anybody or releasing a placeholdher update to point to the new repository if someone tried to to use the update manager. That is on them, for being lazy.

This repositories are listed in here:
/etc/apt/sources.list

To fix the issue all you need to do is update your sources file then run 'sudo apt-get update'
after that your software centre and update manager will work again.

elementary OS / edubuntu came in several versions based on hacked ubuntu vresions
so you may need to figure out what yours is before you read further . 

This list was helpful for me:

Ubuntu "vanilla" versions:
    elementary OS 0.2 Luna -> Ubuntu 12.04 LTS (Precise Pangolin)
    elementary OS 0.3 Freya -> Ubuntu 14.04 LTS (Trusty Tahr)
    elementary OS 0.4 Loki -> Ubuntu 16.04 LTS (Xenial Xerus)

Oddly enough the important part is in the brackets:  (Precise / Trusty / Xenial) in the items to paste below replace 'precise' with whatever version you actually have. eg trusty

Incidentally the same fix will repair broken software centres and update managers in the normal ubuntu too, check here ubuntu version history to figure out whatever the heck your version code name is. Chances are most of them will be marked "obsolete" and tossed into the too hard basket eventually.. so this guide will probably work for years of later releases until someone actually can be bothered to add a forwarding entry in the official repos that update the sources file. (dont hold your breath, millenials are often a$$holes where anything they consider 'obsolete' is concerned)
note: 'old-releases' used to be 'archive' the stupid millenials changed that too without telling anyone, if they disable the http and enforce https, (which seems the next likely A$$ move they will probably make) you will probably have to download the entire repository using https and upload it to your own port 80 webserver and up date the domain appropriately.. because the CA support at that point may become a problem. Cant help you there.

Fix Guide for source repositories

To update your sources file use this command(nano can replace pico depending on your system, both are basically the same, newer versions may move the file google reserach as appropriate):

sudo pico /etc/apt/sources.list

Now Paste in the following: (dont forget you may need to change the code name to match your ubuntu kernel version refer the link earlier)


## http://old-releases.ubuntu.com/ubuntu/dists/precise/
deb-src http://old-releases.ubuntu.com/ubuntu precise main
deb http://old-releases.ubuntu.com/ubuntu precise main
deb http://old-releases.ubuntu.com/ubuntu precise universe
deb-src http://old-releases.ubuntu.com/ubuntu precise universe

## Major bug fix updates produced after the final release of the
## distribution.
deb http://old-releases.ubuntu.com/ubuntu precise-updates main restricted
deb http://old-releases.ubuntu.com/ubuntu precise-updates universe
deb-src http://old-releases.ubuntu.com/ubuntu precise-updates restricted main multiverse universe 

deb http://old-releases.ubuntu.com/ubuntu precise-security universe
deb http://old-releases.ubuntu.com/ubuntu precise-security multiverse

#elementaryos tweaks?
deb http://old-releases.ubuntu.com/ubuntu precise main restricted
deb-src http://old-releases.ubuntu.com/ubuntu precise restricted main multiverse universe 
deb http://old-releases.ubuntu.com/ubuntu precise-security main restricted
deb-src http://old-releases.ubuntu.com/ubuntu precise-security restricted main multiverse universe 

## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://old-releases.ubuntu.com/ubuntu precise-backports main restricted universe multiverse
deb-src http://old-releases.ubuntu.com/ubuntu precise-backports main restricted universe multiverse 


## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://old-releases.ubuntu.com/ubuntu precise multiverse
deb http://old-releases.ubuntu.com/ubuntu precise-updates multiverse
deb http://old-releases.ubuntu.com/ubuntu precise partner

 

Now press ctrl-x and 'yes' to saving the file.

Once done run:

sudo apt-get update

 

Now your upgrade manager and software centre should all be working again and apt-get should also work too now. You probably have some security updates to apply.
This may also allow apt-get upgrade or forcing dist upgrades too although you will end up on some frankenstein version merging Elementary OS and ubuntu if it does. So be careful if you have any files you cant live without.