Announcement

Collapse
No announcement yet.

Converting apt source files to "Modern Sources" may cause source breakage - FIX

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [Post-Install] Converting apt source files to "Modern Sources" may cause source breakage - FIX

    Playing with my 25.04 virtual machine, I launched Discover and it reported 386 updates were available. I attempted the upgrade using Discover and after just a few minutes it appeared frozen - no more progress on the downloads. So I cancelled it and opened Konsole for an old school "apt" upgrade starting with "sudo apt update". As expected, I was greeted with:

    386 packages can be upgraded. Run 'apt list --upgradable' to see them.

    but also

    Notice: Some sources can be modernized. Run 'apt modernize-sources' to do so.

    I knew what this meant. The older " *.list" files have been changed to a new format and named ending in " .sources" I had added the Chrome repo to apt as one of my experiments and it was still in the old school format. So I ran the command as suggested (with sudo, of course) When it completed, I ran 'sudo apt update' again and got a new error message:

    Notice: Skipping acquire of configured file 'main/binary-i386/Packages' as repository 'https://dl.google.com/linux/chrome/deb stable InRelease doesn't support architecture '1386'

    A couple minutes of searching revealed a bug report where the "modernize" feature does not convert the "arch=..." type lines to the new format. Opening the old and new chrome source files did show the "arch=amd64" line in the old version but nothing like that in the new version.

    If you encounter this, the fix is to manually edit the ".sources" file and add this:

    Architectures: amd64

    and save.

    The above changes allowed Discover to finish the update but I'm not entirely sure if this was the actual cause of it stalling the first time.

    Please Read Me

    #2
    Originally posted by oshunluvr View Post
    If you encounter this, the fix is to manually edit the ".sources" file and add this:

    Architectures: amd64
    Does it matter where this line is added?
    Windows no longer obstruct my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment


      #3
      Originally posted by Snowhog View Post
      Does it matter where this line is added?
      Good question but I'm not sure.

      I would say probably not to some degree - like as long as it's not first or last - because comparing different installs, I saw different orders of the entries and even a couple different entries. In this case the entries were in this order:

      Types:
      URIs:
      Suites:
      Components:
      Signed-By:


      I added "Architectures​:" after "Components:" and it worked.

      I also see this entry in KDEneon at the top;

      X-Repolib-Name:​

      "ubuntu.sources" has multiple paragraphs defining different "Suites":

      Types: deb
      URIs: http://archive.ubuntu.com/ubuntu/
      Suites: noble noble-updates
      Components: main restricted universe multiverse
      Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

      Types: deb
      URIs: http://security.ubuntu.com/ubuntu/
      Suites: noble-security
      Components: main restricted universe multiverse
      Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

      The manpage shows:

      Types: deb deb-src
      URIs: uri
      Suites: suite
      Components: [component1] [component2] [...]
      option1: value1
      option2: value2


      So I'm thinking "option" could be a large list. "Signed-By" must be an option so maybe it really doesn't matter what order.

      More reading

      List of "options"

      Please Read Me

      Comment

      Working...
      X