Reload failed because retrieve_conf encountered an error: -1

Hello I have FreePBX 12.0.76.2 and asterisk 13 installed, this error would happen to me from time to time when I hit the Apply Config button, this is a full stack trace :

eload failed because retrieve_conf encountered an error: 255

exit: 255
PHP Fatal error:  Uncaught exception 'Exception' with message 'Unable to start GPG, the command was: [/usr/bin/gpg --homedir /var/spool/asterisk/.gnupg --no-permission-warning --keyserver-options auto-key-retrieve=true,timeout=5 --status-fd 3 --list-keys 2016349F5BC6F49340FCCAF99F9169F4B33B4659]' in /var/www/html/admin/libraries/BMO/GPG.class.php:354
Stack trace:
#0 /var/www/html/admin/libraries/BMO/GPG.class.php(190): GPG->runGPG('--list-keys 201...')
#1 /var/www/html/admin/libraries/BMO/GPG.class.php(249): GPG->getKey()
#2 /var/lib/asterisk/bin/retrieve_conf(23): GPG->trustFreePBX()
#3 {main}
  thrown in /var/www/html/admin/libraries/BMO/GPG.class.php on line 354

I usually solve this by running the amportal chown but it doesn’t always work. What else can I do to fix this permanently ?

My distribution is Centos 6.7 and I followed the installation guide from the wiki, and I m not allowed to put a direct link to it

Hi!!

Is the gpg package installed?

Good luck and have a nice day!

Nick

Yes it is, didn’t have it installed, sorry for being a idiot just getting started with all this.

No problem…

Have a nice day!

Nick