Best way to increase "contacts_max_subscriptions"?

We have around 45 folks in our company and the last 5 in our phonebook have no status on the D70s on the rapid dials. Not a huge deal, but if I wanted to increase this what would be the best way? I would imagine if I edited the res_digium_phone_devices.conf it would simply get overridden. So is there a way to do this properly? If I was to edit a file I would imagine the res_digium_phone_additional.conf would be my best bet? Another question would be is there a consideration that I need to give to the amount of overhead I may be adding to my FreePBX server in doing this? Seems this would require very little resource.

So…this isn’t the best way, but in the absence of the add-on providing you a GUI handle for it, this will get you there. Note that this won’t get carried forward if you update the add-on version at any time.

in /var/www/html/admin/modules/digium_phones, you’ll find all of the logic for the add-on.

You’re going to be looking for
conf/res_digium_phone_devices.php

and you’re looking for the res_digium_phone_devices function, e.g.

function res_digium_phone_devices($conf) {

    global $amp_conf;

    $queues = $conf->digium_phones->get_queues();
    $firmware_manager = $conf->digium_phones->get_firmware_manager();
    $default_locale = $conf->digium_phones->get_general('active_locale');
    $output = array();

    foreach ($conf->digium_phones->get_devices() as $deviceid=>$device) {
            $doutput[] = "[{$deviceid}]";
            $doutput[] = "type=phone";
            $doutput[] = "full_name={$device['name']}";
            /* collect which custom ringtones need to be loaded for this device */
            $ringtones = array();

            $parkext = "";

…
etc.

You’ll wanna add in your custom option $doutput, e.g.:

function res_digium_phone_devices($conf) {

    global $amp_conf;

    $queues = $conf->digium_phones->get_queues();
    $firmware_manager = $conf->digium_phones->get_firmware_manager();
    $default_locale = $conf->digium_phones->get_general('active_locale');
    $output = array();

    foreach ($conf->digium_phones->get_devices() as $deviceid=>$device) {
            $doutput[] = "[{$deviceid}]";
            $doutput[] = "type=phone";
            $doutput[] = "full_name={$device['name']}";

            $doutput[] = "contacts_max_subscriptions=45"; //Stuff you added here

            /* collect which custom ringtones need to be loaded for this device */
            $ringtones = array();

            $parkext = "";

etc…

That’s going to apply 45 as the max subscriptions for each and every phone.

2 Likes

Thanks Malcolm. I appreciate this. We went live with our new phone system this week so I haven’t had a chance to do this yet. I looked initially and couldn’t find the file you referenced but I’m sure I was just in the wrong spot. I’ll do some digging in this weekend while the offices are quiet and I have some time. Are you aware of any plans to expose this setting in FreePBX in the future?

We’ve got a list of things that aren’t currently provided as options, this isn’t the only thing. It’s not difficult, it’s just a matter of having the time and no other pressing priorities.

Understood. Your solution worked perfectly btw. Thanks again!

Awesome :slight_smile:

(some characters to meet the minimum of 20 requirement)