FreePBX 13 to 17 Voicemails Not Working

I am trying to upgrade a FreePBX 13 installation to FreePBX 17 with Debian 12. The restore is working mostly fine with the exception of the voicemails. During the restore process I receive the following error message :

Failed to copy the whole content of "/tmp/backup/bbe287fe-189c-4945-a151-10132059acf5/etc/asterisk/voicemail.conf" to "/etc/asterisk/voicemail.conf" (0 of 6193 bytes copied). on line 76 of file /var/www/html/admin/libraries/Composer/vendor/symfony/filesystem/Filesystem.php

All the voicemail files get copied over fine. However, I cannot do a reload due to this error.

Following advice in other threads I dug into the backup file and copied the contents of voicemail.conf file into the new server which did seem to at least show the voicemails in the voicemail report module and does allow a successful reload to occur. However, once the reload happens it blanks out the voicemail.conf file and does not allow any further reloads so I am assuming there is some kind of error or corruption in the mysql database. I also tried manually setting up one extension with voicemail to see if that would put at least that one in the conf file but it still does not reload.

Any ideas on how to go about troubleshooting this? I started digging through the mysql script in the backup file but it is a little overwhelming and I don’t really know what I am looking for. FYI, there are about 80 or so extensions with voicemail so I could manually recreate each if I had to as long as it would sync their old voicemails back up and if I could get past the reload error.

Thanks.

Hi @KBliven

/etc/asterisk/voicemail.conf is generated based on DB configuration during reload so please check if you voicemail DB is properly restore in mysql ?

After spending way too much time digging into this, I noticed Line 76 of the voicemail.conf was sitting close to some virtual extension that were created in the past but never used much. I proceeded to deleted all the virtual extensions in FreePBX 13, created a new backup, and then restored that on the new FreePBX 17 box. After doing this, the restored completed successfully and allowed subsequent reloads so those virtual extension must have been what was causing the issue. Thanks!

Thanks for clearing this up for me. Everything I read previously said the voicemails didn’t use the db and went solely off the conf files as well as the wav and txt files. This didn’t seem correct to me but since voicemail.conf was getting cleared out after each reload it seem to be a db problem after all. The problem was fixed by deleted some old virtual extensions that were not longer being used. Thanks for the help.