Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have problems importing my GPG-Keys into my new installation of debian. I exportet the private-key a few years ago. Now I am trying to get everything running under a new debian.

I tried to do

  gpg --allow-secret-key-import --import private-key.asc

But I only get this:

gpg: Keine gültigen OpenPGP-Daten gefunden.
gpg: Anzahl insgesamt bearbeiteter Schlüssel: 0

which translates to:

gpg: No valid OpenPGP-Data found
gpg: Number of processed Keys : 0

The file looks correct and starts with

Version: GnuPG v1.4.9 (GNU/Linux)

and ends with


what could be wrong?

share|improve this question
up vote 2 down vote accepted

Found the answer. There were some --- missing at the beginng.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.