Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
No you don't. I was hoping you'd take over - I'm running out of ideas! It's almost as if there has been damage caused by a repo belonging to another version at some point in the past. I guess I'll need to go back to the beginning and review everything we've done.
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04 LTS
Release: 16.04
Codename: xenial
This may be the problem -it should be all Minty goodness, not Ubuntu, or else mintSources.py looks at the wrong config file. Can you run cat /etc/lsb-release (it should be the same as you reported above but it's good to check anyway)?
No you don't. I was hoping you'd take over - I'm running out of ideas! It's almost as if there has been damage caused by a repo belonging to another version at some point in the past. I guess I'll need to go back to the beginning and review everything we've done.
There's 2 pythons installed on LinuxMint (maybe others), python2 is the glue that holds the system together. NEVER TOUCH IT, EVER.
python3 is forward-looking to the future.
hydrurga:
You're spot on in my book.
anytime system-level stuff goes bananas it is "usually" the result of inexperience on behalf of the user
when they think python2 should be upgraded. I'm not saying that is what happened but it looks like it from here.
Neither Ubuntu nor Mint is so busted by just "adding a ppa for Kodi" is doing this.
xbmc is in the repo, btw so they don't need to add a repo.
I have to go off now, so I'll write down my conclusions here (at the very least, so that I remember them in the morning. :-)).
I should have done this from the start: go and take a look at the source code.
A reminder of the error message:
Code:
sudo add-apt-repository ppa:team-xbmc/ppa
Traceback (most recent call last):
File "/usr/lib/linuxmint/mintSources/mintSources.py", line 1551, in <module>
codename = config_parser.get("general", "base_codename")
File "/usr/lib/python2.7/ConfigParser.py", line 330, in get
raise NoSectionError(section)
ConfigParser.NoSectionError: No section: 'general'
The lines surrounding line 1551 of /usr/lib/linuxmint/mintSources/mintSources.py (the Python program that Mint uses to organise the software sources) are:
From the third line, lsb_release -sc should return the version of Mint, in this case serena. It gets this information from the /etc/lsb-release file. This is then used on line 5 to point to the relevant mintsources.conf configuration file at /usr/share/mintsources/serena/mintsources.conf (have a look at /usr/share/mintsources/ to see all the versions listed).
However, for some reason, your /etc/lsb-release file is set up as Ubuntu, not Mint, and lsb_release -sc returns xenial (check this). So, when the Python code checks /usr/share/mintsources/xenial/mintsources.conf, it produces an error (it can't find "general" in the config file because the file doesn't exist).
So, to remedy this, or attempt to remedy it (who knows what else might be wrong, but fingers crossed), you need to run:
sudo cp /etc/lsb-release /etc/lsb-release-backup
gksudo xed /etc/lsb-release
and change that file to contain:
Code:
DISTRIB_ID=LinuxMint
DISTRIB_RELEASE=18.1
DISTRIB_CODENAME=serena
DISTRIB_DESCRIPTION="Linux Mint 18.1 Serena"
(I assume that you're running Mint 18.1 - if not, don't do this, and we'll edit it to 18 Sarah).
hydrurga. I followed your instructions and changed the contents of the file and it worked a treat!! Software Sources loaded immediately and I was able to add the repo! many thanks. Habitual was right, lack of experience on my part. One last question: I have Kodi installed already, think it's version 15.2, it's the default one available by using the command that Habitual mentioned. What I'm wanting to do is install the latest version hence adding the repo. Do I need to completely uninstall the current version and install from the new repo or can I overwrite? If I need to uninstall can you tell me what steps I need to take?
Excellent news, dissposablehero. As I said, I should have thought of that earlier. I don't know what the statue of limitations is as regards editing a post, but perhaps you might want to edit your opening post to mention that the solution can be found in post #34 to avoid any future folk from having to wade through this roller-coaster of a thread! Although we've probably both learned quite a bit in the process.
Now that the repo is in place, you should be able to update the package in question with the normal
sudo apt-get update
sudo apt-get upgrade
However, if for some reason you just want to focus on an individual package rather than updating everything, you could use:
sudo apt-get update
sudo apt-get install package
This will prompt you if there is a more up-to-date version of package available in the repos.
What I'm wanting to do is install the latest version hence adding the repo. Do I need to completely uninstall the current version and install from the new repo or can I overwrite? If I need to uninstall can you tell me what steps I need to take?
Thanks again.
I guess this is where the advice comes in about PPAs. They are the user's responsibility - Clem has said so.
You my good man, have fallen under version-itis, a common Windows affliction.
No harm, No Foul. Been there, trashed that.
In Linux. Latest does not mean greatest.
The versions in the repos are known to work with your OS. It's almost a Lock. Under normal conditions software in the repos will work on the installed system(s).
I am not familiar with Kodi, or xbmc (and I typo that every time) but I know the repo has a version that works, barring exotic variables.
It's all new, but Trust me. 22 years in IT, I could use any desktop/distro except the *BSD inside of 20m.
There is nothing special about software repositories in Linux.
and using them is the recommended method.
Couple of sites I am going to toss at you.
I'm a fan of Links. I may not be able to convey information on a personal level,
so I usually let the Documentation do the conveying.
Using PPAs is "at your own risk" and not it's not just about security or features.
It should be about stability, but that is my opinion based on my experiences.
But the choice is yours.
and another method of investigation when your "toaster" is sick is to ask yourself,
"Self, What are the toaster's defaults?".
Again thanks for the info. I will mark as solved and try and edit the post as you have suggested.
Habitual,
Thanks for all the info. I'll have a read through those pages you've linked to. The reason I wanted the latest Kodi is the features they've added since 15.2 that I am used to using on Andriod & my Windows machines. It isnt of great importance but to be honest, more than anything I wanted to learn more about Linux and solve an issue rather than just wiping the hard drive and starting again (which is what I usually do with Linux).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.