LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This 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


Reply
  Search this Thread
Old 10-15-2018, 04:04 AM   #1
Quilthor
LQ Newbie
 
Registered: Oct 2018
Location: Sweden
Posts: 4

Rep: Reputation: Disabled
Error message when trying to install software


To start with I would like to say that I really suck at Linux, but I try, and in trying I usually fail.

I started to download WineHQ using their instructions and somewhere in there I must have screwed up, because now, every time I try to download and install a new software I get the same type message.

"E: Malformed entry 2 in list file /etc/apt/sources.list.d/additional-repositories.list (Component)
E: Sourcelist could not be read."

I don't know enough to fix this problem.

Please Help
 
Old 10-15-2018, 05:48 AM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware & Android
Posts: 9,493

Rep: Reputation: 991Reputation: 991Reputation: 991Reputation: 991Reputation: 991Reputation: 991Reputation: 991Reputation: 991
Welcome to LQ.

It's OK if you suck at linux; all of us did at one stage, and many of us still do :-).
Quote:
Originally Posted by Quilthor
E: Malformed entry 2 in list file /etc/apt/sources.list.d/additional-repositories.list (Component)
E: Sourcelist could not be read.
Have you made friends with a text editor yet? If not use vi, which will point to some editor. The basic instructions are:
Insert key (once) = enter write mode; Insert again = replace mode
Escape key = exit any mode
: (colon) = command mode.
You need Esc :wq = write and quit or Esc :q! = Don't write and quit
Try
Code:
sudo vi /etc/apt/sources.list.d/additional-repositories.list
Examine line 2 because it's wrong, fix it and try 'sudo apt-get update' Then try installing wine. If that doesn't work, post /etc/apt/sources.list.d/additional-repositories.list
 
Old 10-15-2018, 06:46 AM   #3
Quilthor
LQ Newbie
 
Registered: Oct 2018
Location: Sweden
Posts: 4

Original Poster
Rep: Reputation: Disabled
Thank you for your help, although for me it's all ancient greek.

I managed to open the repositories list, but there i really didn't know what to do. I deleted the incorrect line. So far so good, but I could not exit the text edit with any other means than to close the window. I retried the command and got a new error, that I already had one open(of course), I followed the instructions to open the old list and came back to the same problem...I cannot exit the text edit.
I am fairly sure I am doing something terribly wrong.

If I can only exit the text edit and do the update command I think I'll be alright...for now
 
Old 10-15-2018, 10:10 AM   #4
hazel
Senior Member
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: Debian, Crux, LFS, AntiX
Posts: 2,375
Blog Entries: 6

Rep: Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046
It would help if you say which editor you are using. Even with text editors, there's more than one way to skin a cat!

With vi or vim, you save the altered file with ":w" and then quit with ":q". Or you can do both at once with ":wq". With nano, you use the list of control key combinations displayed at the bottom of the screen. I think it's ctrl+w to save and ctrl+q to quit, but I could be wrong.

You mention a window, so perhaps you're using a graphical editor like leafpad or gedit. Those are fine too; you don't need to use a text editor if you have a working graphical desktop. In those cases of course, you can use File->Save followed by File->Exit.

What is essential in all these cases though is that you do the edit as the root user, because ordinary users aren't allowed to edit system files. You can go through the motions using any editor you like, but you won't be allowed to save the result.

You haven't said what distro you are using but it's obviously something in the Debian family because you have apt. If it is Debian, you can use su to get to root, but if it's Ubuntu or Mint, you will need to use sudo.
 
Old 10-15-2018, 10:44 AM   #5
Quilthor
LQ Newbie
 
Registered: Oct 2018
Location: Sweden
Posts: 4

Original Poster
Rep: Reputation: Disabled
Thanx again.
I'm about to turn into an ol' geezer m'self, but the difference is I can be dazzled.

Anywho...Now I understand a little more, thanx to you.
I was using the vi editor, since it was what suggested. I wouldn't have the foggiest idea how to use any other, at this point.
The window I mentioned was just the terminal window.Again, no idea what I would call it otherwise (I suck, remember?)
Finally, and again thank you...Before your last message I had no idea what a distro was. Now I do, and its Mint I have.

Now I am going to attempt this again. You will be the first to know if I succeed or if I once again fail miserably.
 
Old 10-15-2018, 11:11 AM   #6
Quilthor
LQ Newbie
 
Registered: Oct 2018
Location: Sweden
Posts: 4

Original Poster
Rep: Reputation: Disabled
So I thought I was clever. Turned out I'm not.

You asked what text editor i was using. I said vi. I wasn't. I was in the terminal window.
So now I am trying to download vim, and of course there is an error in the download.
Time for more drastical measures...
 
Old 10-15-2018, 11:24 AM   #7
hazel
Senior Member
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: Debian, Crux, LFS, AntiX
Posts: 2,375
Blog Entries: 6

Rep: Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046
Don't get too drastic too soon! In fact, if you are in that kind of mood, you might want to go off and have a cup of tea before proceeding further.

You probably were using vi, because you do use that in a terminal window. And if I were you, I would continue with vi for the time being. Don't try to install anything else until you get your apt files sorted.

Use "sudo vi" to do your edit and correct what was wrong. Don't try anything new until you have done that!

PS: Distro is short for distribution.

Last edited by hazel; 10-15-2018 at 11:26 AM.
 
Old 10-15-2018, 11:44 AM   #8
DavidMcCann
LQ Veteran
 
Registered: Jul 2006
Location: London
Distribution: CentOS, Xubuntu
Posts: 5,113

Rep: Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706Reputation: 1706
Look in your menu for an editor and find out what it's called — perhaps it's gedit. Then you can use it from the terminal with something like
Code:
sudo gedit /etc/apt/sources.list.d/additional-repositories.list
Vi is a geek tool: I have to go and consult a book if I need it, as I can never remember how it works! If ever you are stuck without a GUI, you can use nano, which comes with Ubuntu.

Incidentally, if you run Synaptic, you can manage your repositories by clicking on Settings - Repositories.
 
Old 10-15-2018, 11:50 AM   #9
hazel
Senior Member
 
Registered: Mar 2016
Location: Harrow, UK
Distribution: Debian, Crux, LFS, AntiX
Posts: 2,375
Blog Entries: 6

Rep: Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046Reputation: 1046
A few other bits of advice of a general nature:

1) Don't panic! When you panic, you are likely to do foolish things. And in Linux, it really isn't necessary. Most problems can be fixed.
2) Work systematically. If you find an error in an important configuration file, you need to fix it before going any further. In particular, you can't run whatever program uses that file until you have fixed it.
3) Choose one editor and get to know it. It doesn't matter whether it's a text editor or a graphical one. You just need to have an editor in your toolkit. Remember that in Linux, all configuration files are plain text and can be edited, but you need to be root to do that. Which means using su or sudo.
4) When asking for help, give as much information as possible. Don't worry about not knowing the vocabulary; that comes with practice.
5) Don't be self-conscious. We were all newbies once.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Lite Software gives error message - Permission denied albionrt Linux - Newbie 3 07-07-2017 12:34 PM
cant open ubuntu software center (error message) carstensjacob Linux - Software 1 10-24-2012 07:09 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:48 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration