How to tell Yealink phones to upload user changes to the FreePBX provisioning directory
Expanding on what I did here: How to backup your Yealink local contacts to the FreePBX provisioning directory, thanks again to @xrobau for posting that polycom script. It was my genesis to create all of this.
Yealink offers a great setting in their phones to let you protect user settings. If you enable this, it will look for a
mac-local.cfgfile during the provisioning process and those settings will override any settings in the common config (
y0000000000XX.cfg), and the device config (
mac.cfg). Additionally, the phones can be told to sync any changes of non-static settings back to provisioning server.
Here are the relevant settings, they are only settable via auto-provisioning.
static.auto_provision.custom.protect = static.auto_provision.custom.sync = static.auto_provision.custom.sync.path = static.auto_provision.custom.upload_method =
From page 59 (or 79 according to the PDF viewer) of the Administrator Guide V83_30, here is what you can do with those settings.
To make use of this I had to add some handling to the
put.yealinkfile, but that is the only change to the repository.
The rest is simply deciding where you want your values and such.
As the administrator guide notes, when using the value
custom.protect = 1there is a forced priority applied to the configuration files.
The highest priority is the Phone/Web UI. And those settings are read from the
mac-local.cfgon every reboot.
So to make this work:
simply follow the instructions in the other post to get the
yealink.conffiles on your FreePBX server in the right place, with the right permissions.
Then in your
y0000000000XX.cfgfile set protect = 1
static.auto_provision.custom.protect = 1
- Reboot your phone or tell it to auto provision.
At this point your phone will internally begin tracking changes to non-static settings and putting them in the mac-local.cfg file internally.
- If you want them to sync up to your FreePBX system, add the sync line to the
static.auto_provision.custom.sync = 1
Now here is a big catch if you implement this to a system where you already have everything set up. Notice that I said it will begin tracking changes. All the settigns you push down in the existing
mac.cfgfiles are still valid.
Simply if the same setting is found in the
mac-local.cfgit will override the other files.
JaredBusch last edited by
The IT benefit to this entire thing is, by enabling this feature, IT will now have a backup of the configuration of all the phones. Even if a user changes a button. Now a phone can die and IT will simply change the MAC on the provisioning server and put the new phone on the desk.
To the business, the benefit is to let users control their own buttons without IT getting involved. Buttons can easily be programmed by a user simply holding it down until the menu pops up. It takes very little instruction to teach users to pick Speed Dial or BLF and enter the number or extension.
For most small shops, this doesn't matter in the first place. They rarely change anything.
But for an organization over 20, it is very common to have users all needing different configurations on their phone buttons. Their Boss, their Queue Pause, their specific parking lots, etc.
If you upgrade to FreePBX 16, the script handler needs updated to reflect PHP7.
gitrepository is updated, but if you have an existing install, this will fix it for you
sudo sed -i "s/php5/php7/" /etc/httpd/conf.d/yealink.conf sudo systemctl restart httpd