ubuntu 18.04 Generating a new ubuntu-keyring .deb to sign your CD failed

Asked by Shalom David on 2018-05-16

i am trying to create customize ISO base on ubuntu 18.04.
i followed https://help.ubuntu.com/community/InstallCDCustomization guide.
first the section of the kerying need to be change cause the keys now are not 8 Bytes its 16 Bytes.
the fail is when i tried to build the packages again:

root@isoMaker18:/opt/build/ubuntu-keyring-2018.02.28# dpkg-buildpackage -d -m"Shalom David <email address hidden>" -k982935729B2F5DD
dpkg-buildpackage: info: source package ubuntu-keyring
dpkg-buildpackage: info: source version 2018.02.28
dpkg-buildpackage: info: source distribution bionic
dpkg-buildpackage: info: host architecture amd64
 dpkg-source --before-build ubuntu-keyring-2018.02.28
 debian/rules clean
dh clean
 dpkg-source -b ubuntu-keyring-2018.02.28
dpkg-source: warning: no source format specified in debian/source/format, see dpkg-source(1)
dpkg-source: info: using source format '1.0'
dpkg-source: info: building ubuntu-keyring in ubuntu-keyring_2018.02.28.tar.gz
dpkg-source: info: building ubuntu-keyring in ubuntu-keyring_2018.02.28.dsc
 debian/rules build
dh build
   create-stamp debian/debhelper-build-stamp
 debian/rules binary
HOME=/opt/build/ubuntu-keyring-2018.02.28 gpg --no-default-keyring --keyring /usr/share/keyrings/debian-keyring.gpg --decrypt SHA512SUMS.txt.asc | sha512sum -c -
keyrings/ubuntu-archive-keyring.gpg: FAILED
keyrings/ubuntu-archive-removed-keys.gpg: OK
keyrings/ubuntu-cloud-keyring.gpg: OK
keyrings/ubuntu-cloud-removed-keys.gpg: OK
keyrings/ubuntu-cloudimage-keyring.gpg: OK
keyrings/ubuntu-cloudimage-removed-keys.gpg: OK
keyrings/ubuntu-dbgsym-keyring.gpg: OK
keyrings/ubuntu-dbgsym-removed-keys.gpg: OK
keyrings/ubuntu-keyring-2012-archive.gpg: OK
keyrings/ubuntu-keyring-2012-cdimage.gpg: OK
keyrings/ubuntu-keyring-2012-cloud-archive.gpg: OK
keyrings/ubuntu-keyring-2016-dbgsym.gpg: OK
keyrings/ubuntu-master-keyring.gpg: OK
gpg: Signature made Tue 06 Feb 2018 07:15:42 PM IST
gpg: using RSA key 773C99EBD0A11172217A7C3FCAC2D8B9CD2CA5F9
gpg: Can't check signature: No public key
gpg: can't create `/opt/build/ubuntu-keyring-2018.02.28/.gnupg/random_seed': No such file or directory
sha512sum: WARNING: 1 computed checksum did NOT match
debian/rules:18: recipe for target 'checkkeyrings' failed
make: *** [checkkeyrings] Error 1
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2

its failed on the keyrings/ubuntu-archive-keyring.gpg: FAILED
i did exactly as written in the guide, can you verify and update the guide?
shalom david

Question information

English Edit question
Ubuntu Edit question
No assignee Edit question
Solved by:
Jam Risser
Last query:
Last reply:
Jam Risser (codejamninja) said : #1

I am having the same problem

Shalom David (shaloda) said : #2

what more information then that you need?
just do the procedure you public and you will see the problem...

Best Jam Risser (codejamninja) said : #3

I figured out why it wasn't working. The checksum wasn't updated to match the new Ubuntu keyring. I ended up manually updating the checksum.

Shalom David (shaloda) said : #4

can you write the procedure in steps that need to be done to solve that?

Shalom David (shaloda) said : #5

ok i manage to change SHA512SUMS.txt.asc
and its work.

Jam Risser (codejamninja) said : #6

So, the reason it failed for me was that the hash in the SHA512SUMS.txt.asc file was not being updated for some reason.

The solution was to manually update it myself using sha512sum.

    cat ubuntu-archive-keyring.gpg | sha512sum

Copy the hash and replace it in the SHA512SUMS.txt.asc file

You can see a python example at the following link . . .

I'm not sure if that's the same reason your checksum isn't matching, but it's worth trying