You are not logged in.
I did the following
repo-add /mnt/packages/repo.db.tar.gz /var/cache/pacman/pkg/*
cp /var/cache/pacman/pkg/* /mnt/packageson one computer
connected the hard drive to another computer and did the following:
added the pacman.conf configurations as follows
[repo]
SigLevel = PackageRequired
Server = file:///mnt/packagesthen ran
pacman -Sy which worked.
and then I tried to install a package using pacman -S.but all the packages give me :
error: packagename: missing required signature,File:///var/cache/pacman/pkg/packagename is corrupted(invalid or corrupted package(PGP Signature))
then i tried:
pacman-key --init
pacman-key --populate archlinux
pacman -Syywhich didn't work and made no difference.what can I do?
Offline
What about the key used to sign these packages? Is it your key?
Offline
What about the key used to sign these packages? Is it your key?
I don't know how to determine that.They were downloaded from the official repositories using pacman -S
(maybe I should have posted this in the newbie corner)
Last edited by jriz (2014-07-13 18:45:10)
Offline
Is your clock OK? Do you have any *.part files in /mnt/packages ?
Why is it complaining about /var/cache/pacman/pkg/packagename ? Your packages should be in /mnt/packages , right?
Offline
One thing that comes to my mind is that repo directories have *.sig files next to the packages, see file structure here http://mirrors.kernel.org/archlinux/testing/os/x86_64/
But cache directory /var/cache/pacman/pkg/ does not have these sign files and it is why pacman complains. Where to find the sign files locally? I do not know the recommended way, but I see that /var/lib/pacman/sync/$REPO.db contains signature information, so you can write a script that extracts it.
Or you can use `repo-add --sign` and sign packages with your key, but it is not very secure.
PS Instead of using repo-add you might want just use repo files from /var/lib/pacman/sync/
Last edited by anatolik (2014-07-13 19:39:22)
Read it before posting http://www.catb.org/esr/faqs/smart-questions.html
Ruby gems repository done right https://bbs.archlinux.org/viewtopic.php?id=182729
Fast initramfs generator with security in mind https://wiki.archlinux.org/index.php/Booster
Offline
Is your clock OK? Do you have any *.part files in /mnt/packages ?
Why is it complaining about /var/cache/pacman/pkg/packagename ? Your packages should be in /mnt/packages , right?
Actually my clock is NOT ok.I'll fix that and report.
I do not have any *.part files.
And from what I gather pacman first "downloads" the packages to it's cache and then tries to install them.that's why it complains about the /var/cache...
Offline
Wrong time can be the problem.
Have you tried setting CacheDir in pacman.conf to the one in /mnt or do you need /var/cache/pacman/pkg/?
Offline
Wrong time can be the problem.
Have you tried setting CacheDir in pacman.conf to the one in /mnt or do you need /var/cache/pacman/pkg/?
I set the cahcedir using the --cachedir option , got the same error.just got the same error, with /var/cache/pacman/packagename changed to /mnt/packages/packagename.
Also my clock was fine.the only problem was it wasn't synced with windows.
Offline
One thing that comes to my mind is that repo directories have *.sig files next to the packages, see file structure here http://mirrors.kernel.org/archlinux/testing/os/x86_64/
But cache directory /var/cache/pacman/pkg/ does not have these sign files and it is why pacman complains. Where to find the sign files locally? I do not know the recommended way, but I see that /var/lib/pacman/sync/$REPO.db contains signature information, so you can write a script that extracts it.
Or you can use `repo-add --sign` and sign packages with your key, but it is not very secure.
PS Instead of using repo-add you might want just use repo files from /var/lib/pacman/sync/
I will try the above and report.
but it shouldn't be necessary according to https://wiki.archlinux.org/index.php/Pacman_tips
Offline
I tried doing it with --sign and it gave me a :
warning: failed to sign package databseso maybe there's a bigger underlying cause
Offline
a google search for this(--sign) yielded absolutely no useful results.seems like no one's ever had this problem before
Last edited by jriz (2014-07-14 12:14:21)
Offline
Also when I use the verify option, it gives me this:
warning: no existing signature found.skipping verificationsurprisingly I get this error on both of my systems.So maybe I've missed something with key generation, but can't find what it is.
Offline
I tried doing it with --sign and it gave me a :
warning: failed to sign package databseso maybe there's a bigger underlying cause
I think it tries to tell you don't have your own private key. What gpg says `gpg -b $SOMEFILE`?
But let's make a step back. Are you trying to share your cache between several machines? There are several existing solutions for this. Check https://wiki.archlinux.org/index.php/Ne … cman_cache and https://wiki.archlinux.org/index.php/Pacserve
Read it before posting http://www.catb.org/esr/faqs/smart-questions.html
Ruby gems repository done right https://bbs.archlinux.org/viewtopic.php?id=182729
Fast initramfs generator with security in mind https://wiki.archlinux.org/index.php/Booster
Offline
I looked at the code for repo-add and understood this: like Anatolik said there have to be *.sig files present( I'm not sure if it's packagename.sig or reponame.sig, maybe both), and pacman doesn't save those files .so how should I get these .sig files?
p.s:I remember getting a "failed to commit transaction" error from pacman -S, when somehow there were reponame.db.sig files in /var/lib/pacman/sync and removing those files fixed the problem.so something seems off here
Offline
I lost track what are we talking about.
Official repos don 't have signed dbs, so unless some mirror was overeager and tried to "fix" this, there should be no reponame.db.sig for the official repos.
Offline
I lost track what are we talking about.
Official repos don 't have signed dbs, so unless some mirror was overeager and tried to "fix" this, there should be no reponame.db.sig for the official repos.
I think that's why it was causing problems.
right now i've narrowed the problem down to fetching the packagename.pkg.sig.tar.xz along with the packagename.pkg.tar.xz.but I can't find a way to do that automatically.at least I can't find a way using
pacman Offline
https://bugs.archlinux.org/task/33091 ?
Is your clock working?
Offline
If you trust your local repository, then you can configure the repository to work without signatures, e.g.
[local]
SigLevel = Optional
Server = file:///some/dir/| alias CUTF='LANG=en_XX.UTF-8@POSIX ' | alias ENGLISH='LANG=C.UTF-8 ' |
Offline
Offline
If you trust your local repository, then you can configure the repository to work without signatures, e.g.
[local] SigLevel = Optional Server = file:///some/dir/
I know. but in the wiki at https://wiki.archlinux.org/index.php/Pacman_tips in the usb stick section, it uses PackageRequired, so i thought it should work
Offline