Backup and update not working.

If none of the more specific forums is the right place to ask

Backup and update not working.

Postby Gnigma » 2020-09-03 14:12

I keep getting an error message on both of these:

E: Malformed entry 26 in list file /etc/apt/sources.list (Component)
E: The list of sources could not be read.

I don't know what this means, and there are not 26 of anything in any of my sources lists.
Gnigma
 
Posts: 11
Joined: 2020-02-05 14:02

Re: Backup and update not working.

Postby sgosnell » 2020-09-03 14:19

It means line 26 (!) of your /etc/apt/sources.list file. If you post the contents of the file, perhaps someone can find the error. But without that, no one can possibly help you further.
sgosnell
 
Posts: 781
Joined: 2011-03-14 01:49

Re: Backup and update not working.

Postby Gnigma » 2020-09-03 14:27

Then there must be a way to get the contents of the file, but I'm telling you, there are not 26 lines in anything I can look at.
Gnigma
 
Posts: 11
Joined: 2020-02-05 14:02

Re: Backup and update not working.

Postby LE_746F6D617A7A69 » 2020-09-03 14:35

Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 342
Joined: 2020-05-03 14:16

Re: Backup and update not working.

Postby Gnigma » 2020-09-03 14:51

It annoys the hell out of me, too.
Gnigma
 
Posts: 11
Joined: 2020-02-05 14:02

Re: Backup and update not working.

Postby sgosnell » 2020-09-03 14:53

You can get the contents of the file, just like with any other file, by opening it with a text editor or by running in a terminal
Code: Select all
cat /etc/apt/sources.list

Just like you did in one of the threads linked above. You said you cleaned it up, but apparently the cleaning went awry.
sgosnell
 
Posts: 781
Joined: 2011-03-14 01:49

Re: Backup and update not working.

Postby Gnigma » 2020-09-03 15:04

Yeah, well, that gives me this:

cat /etc/apt/sources.list
#


# deb cdrom:[Debian GNU/Linux 10.2.0 _Buster_ - Official amd64 NETINST 20191116-09:56]/ buster main

deb http://ftp.us.debian.org/debian/ buster main contrib
deb-src http://ftp.us.debian.org/debian/ buster main contrib

deb http://ftp.us.debian.org/debian/ buster/updates main contrib
deb-src http://ftp.us.debian.org/debian/ buster/updates main contrib

# buster-updates, previously known as 'volatile'
deb http://ftp.us.debian.org/debian/ buster-updates main contrib
deb-src http://ftp.us.debian.org/debian/ buster-updates main contrib

# This system was installed using small removable media
# (e.g. netinst, live or single CD). The matching "deb cdrom"
# entries were disabled at the end of the installation process.
# For information about how to configure apt package sources,
# see the sources.list(5) manual.


I still do not see 26 lines.
Gnigma
 
Posts: 11
Joined: 2020-02-05 14:02

Re: Backup and update not working.

Postby sgosnell » 2020-09-03 15:22

Try this. You don't need the source code, so comment those out to save time and bandwidth.
Code: Select all
deb http://ftp.us.debian.org/debian/ buster main contrib
#deb-src http://ftp.us.debian.org/debian/ buster main contrib
deb http://security.debian.org/debian-security/ buster/updates main contrib
#deb-src http://security.debian.org/debian-security/ buster/updates main contrib

# buster-updates, previously known as 'volatile'
deb http://deb.debian.org/debian/ buster-updates main contrib
#deb-src http://deb.debian.org/debian/ buster-updates main contrib 
Get rid of everything else. There may be stray unprintable characters in the file somewhere.
sgosnell
 
Posts: 781
Joined: 2011-03-14 01:49

Re: Backup and update not working.

Postby LE_746F6D617A7A69 » 2020-09-03 15:50

sgosnell wrote:Get rid of everything else.
There's a catch in this sentence: most likely the sources.list has been damaged by using wrong editor/text encoding ;)
I would say that it's better to backup the old file and create a completely new one using f.e. the nano editor as root.

Anyway, it would be nice to see the output of:
Code: Select all
xxd -g1 /etc/apt/sources.list
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 342
Joined: 2020-05-03 14:16

Re: Backup and update not working.

Postby Gnigma » 2020-09-03 15:57

xxd -g1 /etc/apt/sources.list
00000000: 23 20 0a 0a 0a 23 20 64 65 62 20 63 64 72 6f 6d # ...# deb cdrom
00000010: 3a 5b 44 65 62 69 61 6e 20 47 4e 55 2f 4c 69 6e :[Debian GNU/Lin
00000020: 75 78 20 31 30 2e 32 2e 30 20 5f 42 75 73 74 65 ux 10.2.0 _Buste
00000030: 72 5f 20 2d 20 4f 66 66 69 63 69 61 6c 20 61 6d r_ - Official am
00000040: 64 36 34 20 4e 45 54 49 4e 53 54 20 32 30 31 39 d64 NETINST 2019
00000050: 31 31 31 36 2d 30 39 3a 35 36 5d 2f 20 62 75 73 1116-09:56]/ bus
00000060: 74 65 72 20 6d 61 69 6e 0a 0a 64 65 62 20 68 74 ter main..deb ht
00000070: 74 70 3a 2f 2f 66 74 70 2e 75 73 2e 64 65 62 69 tp://ftp.us.debi
00000080: 61 6e 2e 6f 72 67 2f 64 65 62 69 61 6e 2f 20 62 an.org/debian/ b
00000090: 75 73 74 65 72 20 63 6f 6e 74 72 69 62 20 6d 61 uster contrib ma
000000a0: 69 6e 0a 64 65 62 2d 73 72 63 20 68 74 74 70 3a in.deb-src http:
000000b0: 2f 2f 66 74 70 2e 75 73 2e 64 65 62 69 61 6e 2e //ftp.us.debian.
000000c0: 6f 72 67 2f 64 65 62 69 61 6e 2f 20 62 75 73 74 org/debian/ bust
000000d0: 65 72 20 6d 61 69 6e 20 63 6f 6e 74 72 69 62 0a er main contrib.
000000e0: 0a 64 65 62 20 68 74 74 70 3a 2f 2f 66 74 70 2e .deb http://ftp.
000000f0: 75 73 2e 64 65 62 69 61 6e 2e 6f 72 67 2f 64 65 us.debian.org/de
00000100: 62 69 61 6e 2f 20 62 75 73 74 65 72 2f 75 70 64 bian/ buster/upd
00000110: 61 74 65 73 20 6d 61 69 6e 20 63 6f 6e 74 72 69 ates main contri
00000120: 62 0a 64 65 62 2d 73 72 63 20 68 74 74 70 3a 2f b.deb-src http:/
00000130: 2f 66 74 70 2e 75 73 2e 64 65 62 69 61 6e 2e 6f /ftp.us.debian.o
00000140: 72 67 2f 64 65 62 69 61 6e 2f 20 62 75 73 74 65 rg/debian/ buste
00000150: 72 2f 75 70 64 61 74 65 73 20 6d 61 69 6e 20 63 r/updates main c
00000160: 6f 6e 74 72 69 62 0a 0a 23 20 62 75 73 74 65 72 ontrib..# buster
00000170: 2d 75 70 64 61 74 65 73 2c 20 70 72 65 76 69 6f -updates, previo
00000180: 75 73 6c 79 20 6b 6e 6f 77 6e 20 61 73 20 27 76 usly known as 'v
00000190: 6f 6c 61 74 69 6c 65 27 0a 64 65 62 20 68 74 74 olatile'.deb htt
000001a0: 70 3a 2f 2f 66 74 70 2e 75 73 2e 64 65 62 69 61 p://ftp.us.debia
000001b0: 6e 2e 6f 72 67 2f 64 65 62 69 61 6e 2f 20 62 75 n.org/debian/ bu
000001c0: 73 74 65 72 2d 75 70 64 61 74 65 73 20 6d 61 69 ster-updates mai
000001d0: 6e 20 63 6f 6e 74 72 69 62 0a 64 65 62 2d 73 72 n contrib.deb-sr
000001e0: 63 20 68 74 74 70 3a 2f 2f 66 74 70 2e 75 73 2e c http://ftp.us.
000001f0: 64 65 62 69 61 6e 2e 6f 72 67 2f 64 65 62 69 61 debian.org/debia
00000200: 6e 2f 20 62 75 73 74 65 72 2d 75 70 64 61 74 65 n/ buster-update
00000210: 73 20 6d 61 69 6e 20 63 6f 6e 74 72 69 62 0a 0a s main contrib..
00000220: 23 20 54 68 69 73 20 73 79 73 74 65 6d 20 77 61 # This system wa
00000230: 73 20 69 6e 73 74 61 6c 6c 65 64 20 75 73 69 6e s installed usin
00000240: 67 20 73 6d 61 6c 6c 20 72 65 6d 6f 76 61 62 6c g small removabl
00000250: 65 20 6d 65 64 69 61 0a 23 20 28 65 2e 67 2e 20 e media.# (e.g.
00000260: 6e 65 74 69 6e 73 74 2c 20 6c 69 76 65 20 6f 72 netinst, live or
00000270: 20 73 69 6e 67 6c 65 20 43 44 29 2e 20 54 68 65 single CD). The
00000280: 20 6d 61 74 63 68 69 6e 67 20 22 64 65 62 20 63 matching "deb c
00000290: 64 72 6f 6d 22 0a 23 20 65 6e 74 72 69 65 73 20 drom".# entries
000002a0: 77 65 72 65 20 64 69 73 61 62 6c 65 64 20 61 74 were disabled at
000002b0: 20 74 68 65 20 65 6e 64 20 6f 66 20 74 68 65 20 the end of the
000002c0: 69 6e 73 74 61 6c 6c 61 74 69 6f 6e 20 70 72 6f installation pro
000002d0: 63 65 73 73 2e 0a 23 20 46 6f 72 20 69 6e 66 6f cess..# For info
000002e0: 72 6d 61 74 69 6f 6e 20 61 62 6f 75 74 20 68 6f rmation about ho
000002f0: 77 20 74 6f 20 63 6f 6e 66 69 67 75 72 65 20 61 w to configure a
00000300: 70 74 20 70 61 63 6b 61 67 65 20 73 6f 75 72 63 pt package sourc
00000310: 65 73 2c 0a 23 20 73 65 65 20 74 68 65 20 73 6f es,.# see the so
00000320: 75 72 63 65 73 2e 6c 69 73 74 28 35 29 20 6d 61 urces.list(5) ma
00000330: 6e 75 61 6c 2e 0a 23 20 64 65 62 2d 73 72 63 20 nual..# deb-src
00000340: 68 74 74 70 3a 2f 2f 66 74 70 2e 75 73 2e 64 65 http://ftp.us.de
00000350: 62 69 61 6e 2e 6f 72 67 2f 64 65 62 69 61 6e 2f bian.org/debian/
00000360: 20 62 75 73 74 65 72 20 6d 61 69 6e 20 63 6f 6e buster main con
00000370: 74 72 69 62 0a trib.
Gnigma
 
Posts: 11
Joined: 2020-02-05 14:02

Re: Backup and update not working.

Postby LE_746F6D617A7A69 » 2020-09-03 16:10

The text encoding is correct (plain ASCII) - so the problem is somewhere else.

Side note: can You please learn how to use Code tags?
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 342
Joined: 2020-05-03 14:16

Re: Backup and update not working.

Postby Head_on_a_Stick » 2020-09-03 16:18

LE_746F6D617A7A69 wrote:I would say that it's better to backup the old file and create a completely new one using f.e. the nano editor as root

^ This.

But text editors are bloat:
Code: Select all
sudo tee /etc/apt/sources.list <<END
deb https://deb.debian.org/debian buster main contrib non-free
deb https://deb.debian.org/debian-security/ buster/updates main contrib non-free
deb https://deb.debian.org/debian buster-updates main contrib non-free
END

Here documents ftw!
Black Lives Matter

Debian buster-backports ISO image: for new hardware support
User avatar
Head_on_a_Stick
 
Posts: 12488
Joined: 2014-06-01 17:46
Location: /dev/chair

Re: Backup and update not working.

Postby LE_746F6D617A7A69 » 2020-09-03 20:31

Head_on_a_Stick wrote:But text editors are bloat

Got You!
If the text editors are so bad / bloated, then how are You writing/editing Your posts without using that bloated editors? hmm? :mrgreen:

But seriously:
That hex dump of sources.list shows that the file is correct - the count of bytes containing newlines (0x0A) is 21 -> 20 text lines + 1 newline at the end of the file -> so how it is possible that apt reports an error at line 26?

Something smells here ...
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 342
Joined: 2020-05-03 14:16

Re: Backup and update not working.

Postby CwF » 2020-09-03 21:40

I have navigated to etc/apt/sources.list in Thunar and right clicked to edit as root in Mousepad, but I usually edit the repositories in Synaptic itself. Works fine. No special chants or sacrifices.

OP should check in etc/apt/sources.d and etc/apt/preferences.d for oddities.
CwF
 
Posts: 767
Joined: 2018-06-20 15:16

Re: Backup and update not working.

Postby sgosnell » 2020-09-03 23:35

Apt also reads files in etc/apt/sources.list.d. Check if there are iany files in that directory, and if so, please post them. Seeing your history, I would bet a small sum that there are leftover files there, perhaps from the Ubuntu PPAs or other installed packages.
sgosnell
 
Posts: 781
Joined: 2011-03-14 01:49

Next

Return to General Questions

Who is online

Users browsing this forum: No registered users and 5 guests

fashionable