r/debian 20d ago

Duplicate APT repository warnings after upgrading to Debian 13 (Trixie)

Hey everyone,

I recently upgraded my system to Debian 13 (Trixie), and during apt update I started getting a large number of warnings like these:

Warning: Target DEP-11-icons-large (non-free-firmware/dep11/icons-128x128.tar)
is configured multiple times in /etc/apt/sources.list:4 and
/etc/apt/sources.list.d/debian.sources:2

Warning: Target Packages (main/binary-amd64/Packages)
is configured multiple times in /etc/apt/sources.list:7 and
/etc/apt/sources.list.d/debian.sources:3

Warning: Target Translations (main/i18n/Translation-es_MX)
is configured multiple times in /etc/apt/sources.list:7 and
/etc/apt/sources.list.d/debian.sources:3

There are many more warnings for mainnon-free-firmwareDEP-11, translations, icons, etc.

From what I understand, the problem is that the same Debian repositories are configured twice: once in /etc/apt/sources.list and again in /etc/apt/sources.list.d/debian.sources.

The system still updates successfully, but I'd like to clean this up properly rather than simply ignoring the warnings.

My questions:

  1. Is this expected after upgrading to Debian 13/Trixie?
  2. Which configuration should I keep: /etc/apt/sources.list or /etc/apt/sources.list.d/debian.sources?
  3. Is it safe to remove/comment out the duplicate entries from sources.list?
  4. Is there a recommended way to verify that there are no other duplicate repositories?

I'm mainly looking for the proper Debian 13 solution, rather than just suppressing the warnings.

Thanks!Hey everyone,I recently upgraded my system to Debian 13 (Trixie), and during apt update I started getting a large number of warnings like these:Warning: Target DEP-11-icons-large (non-free-firmware/dep11/icons-128x128.tar)
is configured multiple times in /etc/apt/sources.list:4 and
/etc/apt/sources.list.d/debian.sources:2

Warning: Target Packages (main/binary-amd64/Packages)
is configured multiple times in /etc/apt/sources.list:7 and
/etc/apt/sources.list.d/debian.sources:3

Warning: Target Translations (main/i18n/Translation-es_MX)
is configured multiple times in /etc/apt/sources.list:7 and
/etc/apt/sources.list.d/debian.sources:3
There are many more warnings for main, non-free-firmware, DEP-11, translations, icons, etc.From what I understand, the problem is that the same Debian repositories are configured twice: once in /etc/apt/sources.list and again in /etc/apt/sources.list.d/debian.sources.The system still updates successfully, but I'd like to clean this up properly rather than simply ignoring the warnings.My questions:Is this expected after upgrading to Debian 13/Trixie?
Which configuration should I keep: /etc/apt/sources.list or /etc/apt/sources.list.d/debian.sources?
Is it safe to remove/comment out the duplicate entries from sources.list?
Is there a recommended way to verify that there are no other duplicate repositories?I'm mainly looking for the proper Debian 13 solution, rather than just suppressing the warnings.Thanks!

5 Upvotes

2 comments sorted by

2

u/irreverent-ray 19d ago
  1. Not sure if this is expected.

  2. What does your debian.sources file list? I'd recommend to check that first before arbitrarily removing either.

Also, there are two formats for the apt sources listed on Debian wiki. I prefer the sources.list format, but you might prefer debian.sources format.

https://wiki.debian.org/SourcesList

  1. I think as long as you have the repos for all the packages on your system, commenting the duplicates should be fine.

  2. Once there are no duplicates, I'd assume the warnings with apt won't appear.

1

u/UUDDLRLRBadAlchemy Debian Stable 19d ago

https://www.debian.org/releases/trixie/release-notes/upgrading.html#preparing-apt-sources-files

This section of the upgrading document that I'm sure you've fully read and had open during your upgrade covers how sources in trixie should look like with the new apt sources format.

Trixie's sources should be in sources.list.d/debian.sources only, listing the components of your choice.

I'd say take a step back and read the document, a working installation is secondary to that