LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 11-24-2023, 12:25 AM   #1
RealNikkiB
LQ Newbie
 
Registered: Nov 2023
Location: Virginia, USA
Distribution: Debian Bullseye
Posts: 4

Rep: Reputation: 0
Question (Bullseye) type ‘“deb’ is not known on line 1 in source list /etc/apt/sources.list.d/backports.list


Hi, all. I’m new to the forums and a little bit tech illiterate so please be kind. I have Bullseye and I was trying to update so I can install Firefox, but I’m getting:

E: Type ‘“deb’ is not known on line 1 in source list /etc/apt/sources.list.d/backports.list
E: The list of sources could not be read

I know that means there’s a mistake in line 1 of the backports file in sources.list.d but how do I fix it?? Obviously I’ve Googled but all I’m finding is how to edit the source list and how to add sources.list.d files, and I wasn’t about to start editing files or anything in my source list and just cross my fingers and hope it works. I’m sure it’s something stupid like that “ shouldn’t be there but I’d really like some advice from someone who knows what they’re doing before I mess with anything. Thanks in advance.
 
Old 11-24-2023, 01:51 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,976

Rep: Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337Reputation: 7337
it would be nice to show what this line looks like, otherwise we won't be able to answer
 
1 members found this post helpful.
Old 11-24-2023, 11:43 AM   #3
RealNikkiB
LQ Newbie
 
Registered: Nov 2023
Location: Virginia, USA
Distribution: Debian Bullseye
Posts: 4

Original Poster
Rep: Reputation: 0
photo

Sorry, I should have known that. Thanks for replying.
Click image for larger version

Name:	Screenshot 2023-11-24 12.29.28 PM.png
Views:	45
Size:	33.4 KB
ID:	42112
 
Old 11-24-2023, 12:23 PM   #4
boughtonp
Senior Member
 
Registered: Feb 2007
Location: UK
Distribution: Debian
Posts: 3,616

Rep: Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555
Quote:
Originally Posted by RealNikkiB View Post
... I wasn’t about to start editing files or anything in my source list and just cross my fingers and hope it works.
Well someone/thing has already done that, hence why this error is occurring.

Pan64 was referring to seeing the line in the file /etc/apt/sources.list.d/backports.list

If you use the command "head /etc/apt/sources.list.d/backports.list" (without quotes) it will show the first few lines of the file (10 by default), and we can advise you on whether to remove the line that is causing the error, or to change it to something valid.

Possibly it should simply read as below (so may be enough to remove any stray quotes) - but it also may be different, depending on what the file contains:
Code:
deb http://deb.debian.org/debian bullseye-backports main
(Also, ideally this should be as text within "[code]..[/code]" tags to preserve formatting, rather than a screenshot.)


Last edited by boughtonp; 11-24-2023 at 12:28 PM.
 
1 members found this post helpful.
Old 11-24-2023, 12:39 PM   #5
boughtonp
Senior Member
 
Registered: Feb 2007
Location: UK
Distribution: Debian
Posts: 3,616

Rep: Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555

Also, using Backports is not required to get a current Firefox for Debian 11. (It may or not be required for other software on the machine.)

For Firefox it is enough to have the "bullseye-security" repo enabled (usually in the main /etc/apt/sources.list file), so if - after repairing the config and updating Apt - you get offered Firefox v102 (instead of Firefox v115) then we can check that.

 
1 members found this post helpful.
Old 11-24-2023, 09:31 PM   #6
RealNikkiB
LQ Newbie
 
Registered: Nov 2023
Location: Virginia, USA
Distribution: Debian Bullseye
Posts: 4

Original Poster
Rep: Reputation: 0
img code is off for this thread, probably because I'm a new member. I'm going to go to the questions/feedback thread and see if there's any way I can get it turned on. I don't know if I should use an attachment or copy/paste the photo itself, so I just copied the actual text from the terminal for now and pasted it below. Please let me know if you need a photo. Thanks again for your help.

Code:
reallifenikkib@penguin:~$ head /etc/apt/sources.list.d/backports.list
“deb http://ftp.debian.org/debian buster-backports main contrib”
reallifenikkib@penguin:~$
 
Old 11-25-2023, 06:42 AM   #7
boughtonp
Senior Member
 
Registered: Feb 2007
Location: UK
Distribution: Debian
Posts: 3,616

Rep: Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555Reputation: 2555

(No need for photo. Attachments for screenshots/photos is fine, when appropriate, but copy-pasting text into code tags, as you did, is the best option.)

There's two main problems with that file:
1) the quotes (which are causing the error)
2) if you're running Bullseye (11), you shouldn't be referencing backports for Buster (10)

You can confirm which version of Debian you're running with "head /etc/os-release", but probably, the simplest solution is to disable the file, which you can do by renaming it like so:
Code:
sudo mv -v /etc/apt/sources.list.d/backports.list /etc/apt/sources.list.d/backports.list.disabled
The sudo command runs whatever follows as superuser (admin/root) whilst mv is short for move.

Whenever entering a command someone suggests online you should be sure you check/understand what the command actually does, but especially so if that command contains "sudo" (or "su") anywhere within it.

Also, whilst deleting the file would also disable it, it's usually a good idea to disable things by renaming/moving them, as it can be undone if a mistake was made.

Finally, if you actually need Backports, then for Debian 11 Bullseye the file could be edited to match as below, but - unless you have a known reason for having backports enabled - you probably don't need it.
Code:
deb http://deb.debian.org/debian bullseye-backports main contrib

Last edited by boughtonp; 11-25-2023 at 06:43 AM.
 
1 members found this post helpful.
Old 11-25-2023, 10:00 AM   #8
RealNikkiB
LQ Newbie
 
Registered: Nov 2023
Location: Virginia, USA
Distribution: Debian Bullseye
Posts: 4

Original Poster
Rep: Reputation: 0
Disabling it worked. Thank you so much for your help!
 
  


Reply



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
"Type 'sudo' is not known on line 2 in source list /etc/apt/sources.list.d/signal-xenial.list" jameswilson0609 Linux - Newbie 3 05-29-2019 12:04 PM
E: Type 'sudo' is not known on line 1 in source list /etc/apt/sources.list.d/mono-official.list 221B Linux - Newbie 6 09-07-2017 12:14 PM
E:Type 'Reading' is not known on line 53 in source list /etc/apt/sources.list, E:The hunterclan0405 Linux - Newbie 2 01-15-2011 11:08 PM
apt-get; E: Type 'GPG' is not known on line 20 in source list /etc/apt/sources.list tomorrow Linux - Newbie 9 05-21-2009 08:42 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 02:58 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
Open Source Consulting | Domain Registration