Auto provisioning of Yealink phones after factory reset?

Discussion in '3CX Phone System - General' started by ProudCanadian, Jan 12, 2018.

Thread Status:
Not open for further replies.
  1. ProudCanadian

    Joined:
    Aug 24, 2017
    Messages:
    41
    Likes Received:
    5
    Scenario: I have a Yealink T46S at my desk on the latest firmware. After playing around with the settings, I want to get it back to stock condition so I factory reset it.

    Currently, after doing so it appears bold in the phones list in 3CX, and I have to manually click assign extension and choose myself again before 3CX provisions it.

    Is there some way to have 3CX see this new phone appear, realize its already assigned to an extension and then just provision it automagically?
     
  2. eddv123

    eddv123 Active Member

    Joined:
    Aug 15, 2017
    Messages:
    995
    Likes Received:
    153
    Hi Proudcanadian,

    I would agree in that you would need to select and re-assign it to the extension I have experienced the same behaviour.

    I have used DHCP option 66 provisioning before and that is pretty slick albeit you have to setup the preliminary environment first.
     
  3. ProudCanadian

    Joined:
    Aug 24, 2017
    Messages:
    41
    Likes Received:
    5
    Could you elaborate on how the DHCP 66 would function with these phones?
     
  4. eddv123

    eddv123 Active Member

    Joined:
    Aug 15, 2017
    Messages:
    995
    Likes Received:
    153
  5. ProudCanadian

    Joined:
    Aug 24, 2017
    Messages:
    41
    Likes Received:
    5
    I do actually have an SBC at multiple sites, so that could be an option for me. Any chance you could elaborate on that portion? (Sorry, still new to all this stuff)
     
  6. eddv123

    eddv123 Active Member

    Joined:
    Aug 15, 2017
    Messages:
    995
    Likes Received:
    153
    Disregard that point, SBC provisioning is only if you are setting up to a cloud PBX, if local LAN your only options are manual setup, DHCP Option 66 or Plug and Play (if using a supported preferred phone with 3CX).

    Please elaborate further on what your issue is with re-assigning the phone to extension ?
     
  7. ProudCanadian

    Joined:
    Aug 24, 2017
    Messages:
    41
    Likes Received:
    5
    The issue is that after factory resetting a phone thats assigned an extension, I want it to automatically see that the mac address is assigned to an extension and provision instead of having to select the bold detected phone and choosing assign extension and assigning it to the same one again.
     
  8. eddv123

    eddv123 Active Member

    Joined:
    Aug 15, 2017
    Messages:
    995
    Likes Received:
    153
    As i said DHCP options maybe the way to go then but prepare the environment as per the guide, this method is not normally used for fully supported phones within their local LAN subnet however.
     
  9. accentlogic

    accentlogic New Member

    Joined:
    Nov 14, 2013
    Messages:
    161
    Likes Received:
    67
    Currently, plug and play behind an SBC requires you to manually assign the phones. We have tested using RPS (Remote Provisioning Server) and found that the phones will provision after a factory reset, but then will not respond to console requests to re-provision or update firmware. My guess is DHCP option 66 will have the same issue, as it provides the same provisioning URL as RPS.

    I posted a request in the Ideas forum some time ago to allow the SBC and extensions to be pre-configured so that what you are trying to do would work. The title was worded poorly, but the end result is the same - if a new phone hits the PBX, and it has already been assigned to an extension, then send the provisioning file. I am hoping the new SBC integration into the console re-works this a little.

    Feel free to vote this one up:

    https://www.3cx.com/community/threads/make-session-border-controllers-sbc-an-object.47583/
     
  10. eddv123

    eddv123 Active Member

    Joined:
    Aug 15, 2017
    Messages:
    995
    Likes Received:
    153
    DHCP options provisioning downloads the file on picking up a DHCP address, there should be no manual intervention required if i recall, as you have already set the string in your boot server and it is picked up from here - see the guide i sent through.
     
  11. accentlogic

    accentlogic New Member

    Joined:
    Nov 14, 2013
    Messages:
    161
    Likes Received:
    67
    Yes, DCHP Option 66 does get the phones configured when they are behind an SBC, but the problem is they do not respond to future re-provision requests or firmware updates from the console. We ran this by 3CX support with a ticket, and they were able to replicate the issue. So, they currently only support manual assignment by plug and play from the phones tab when using an SBC.
     
    NickD_3CX likes this.
  12. eddv123

    eddv123 Active Member

    Joined:
    Aug 15, 2017
    Messages:
    995
    Likes Received:
    153
    This is not the case, DHCP Option 66 is not normally used behind an SBC. It is used with VPN configurations, or other situations where you have phones in a different subnet (2 NIC cards for example). Also it is used for the "Legacy Limited feature set" Phones like Polycom and Cisco for local provisioning (as they cannot take advantage of PnP).

    The SBC is used for "preferred" models remotely as they can take advantage of plug and play provisioning. But yes you would need manual intervention to assign phones from the "phones" list in 3CX to the extensions.
     
  13. accentlogic

    accentlogic New Member

    Joined:
    Nov 14, 2013
    Messages:
    161
    Likes Received:
    67
    Sorry if I was not clear, that was my point. You can use it, but not behind an SBC and for the reasons I described. I brought up the issue because the OP had an issue with a phone that did not reprovision after a factory reset. Your original reply to the OP seemed to suggest using DHCP option 66, but then the OP mentioned the use of an SBC, so I tried to describe what happens if you try doing that behind an SBC - it appears to work, but then you cannot make any changes down the road.

    This is actually something I have asked 3CX to support, so that we can ship new phones or do factory resets at sites behind an SBC, and if they are configured for the extension they will provision without manual intervention.
     
  14. ProudCanadian

    Joined:
    Aug 24, 2017
    Messages:
    41
    Likes Received:
    5
    I actually got this to start fully working as I wanted using DHCP option 66 and our Yealink phones.
    For both local phones and SBC phones, I set option 66 to http://ourserver:5000/provisioning/provdir
    As long as the handset is setup with an extension (meaning as long as the mac address is registered and the handset type selected under an extension) when plugged into our network it will now auto provision. Additionally, I can manage the phones after provisioning this way (But had to change the template to change an unrelated security setting for our certificate)
     
  15. accentlogic

    accentlogic New Member

    Joined:
    Nov 14, 2013
    Messages:
    161
    Likes Received:
    67
    Thanks for the update. We have not tried this since pre SP2. We would like to preconfigure and ship so phones work when connected without a phone call and manual configuration. I'll check with 3CX if this can be a supported config before we proceed in production.
     
  16. ProudCanadian

    Joined:
    Aug 24, 2017
    Messages:
    41
    Likes Received:
    5
    I just tested with a remote site. We had a new Yealink phone in the box, had someone read me the MAC address. I went under an extension, added a phone and enter the model and MAC and saved it. Then had the remote worker plug the phone in for the first time. It pulled its configuration automatically and configured with nothing required of the remote worker.
     
  17. NickD_3CX

    NickD_3CX Support Team
    Staff Member 3CX Support

    Joined:
    Jun 2, 2014
    Messages:
    1,281
    Likes Received:
    66
    This caught my eye an thought I should add my 2 cents. Actually, everybody is right in this thread.

    Provisioning a phone to use the SBC is completely possible using DHCP Option 66, the phone will pick up its config and will register and operate, HOWEVER, as @accentlogic said, some operations initiated from the Management Console may not work, like for example going to "Phones" and pressing "Re-provision". If that is not a problem, then fine, but it is something you should ave in mind.

    A scenario though that is more troublesome is the Hotdesking extensions behind and SBC that rely on PnP Provisionig. What will happen in this case is that when the next user logs in, the phone won't auto-restart/reprovision, rather you would have to manually restart the phone.
    This scenario would require manual assignment of extensions from the Management Console using the PnP entries in the "Phones" node.
     
  18. ProudCanadian

    Joined:
    Aug 24, 2017
    Messages:
    41
    Likes Received:
    5
    Morning Nick!
    I am not sure I follow, as reprovisioning and hotdesking seems to be fully working with this config?
     
  19. Imaxinar DM

    Joined:
    Mar 4, 2017
    Messages:
    9
    Likes Received:
    1
    I am also having similar trouble getting my new Yealink T46S to show up and provision. I have tried via local and STUN (resetting phone to factory etc. each time).

    My Details:
    3CX Free Version (PBX Edition 15.5.0 ) until things are all working & tested, installed on:

    Debian GNU/Linux 8.7 (jessie)
    Linux IDM-3CX 3.16.0-4-amd64 #1 SMP Debian 3.16.43-2+deb8u5 (2017-09-19) x86_64 GNU/Linux

    3 Cisco SPA525G local phones working just fine

    New Phone: Yealink T46S with updated firmware download from 3CX: T4xS-66.82.0.20.rom
    (confirmed in status on phone)

    After firmware update I Reset phone to Factory Defaults so PnP would do it's thing.

    1. Phone from cold start gets DHCP IP Address OK and I can sign in to it's webpage if needed
    2. Displays: "Sending Provision Requests"
    3. Displays: "Config Updating"
    4. Displays: "Update Skipped"

    Does NOT appear as NEW in the Phones page .. or at all.

    If I add the extension and Add the Yealink phone, it stores it, but still does not show up in Phones page.

    A) I have looked at netstat -g which seems OK:

    IPv6/IPv4 Group Memberships
    Interface RefCnt Group
    --------------- ------ ---------------------
    lo 1 all-systems.mcast.net
    eth0 1 sip.mcast.net
    eth0 1 all-systems.mcast.net
    lo 1 ip6-allnodes
    lo 1 ff01::1
    eth0 1 ff02::1:ffbc:17d1
    eth0 1 ip6-allnodes
    eth0 1 ff01::1
    wlan0 1 ip6-allnodes
    wlan0 1 ff01::1



    B) IP Phone and PBX are in the Same Local LAN Subnet

    C) "Switch Must Support MultiCast"
    Modem/Router is ZyXEL C1000Z
    My Port Forwarding:
    192.168.0.10 TCP/UDP 5060
    192.168.0.10 TCP/UDP 5090
    192.168.0.10 UDP 9000 - 9255
    192.168.0.10 TCP/UDP 5000 - 5001

    UPnP settings:
    UPnP: Enabled
    UPnP NAT-T: Enabled


    D) Yealink says this phone does PnP Provisioning

    E) I have manually entered directly into the phone the provisioning URL, with no luck.
    for local it shows: http://192.168.0.10:5000/provisioning/w0qxrt91zols6
    for STUN it shows: https://MyCompany.3cx.us:5001/provisioning/w0qxrt91zols6

    F) I cannot seem to get to the Provisioning Config file URL? - is it not being built properly?

    G) The only mention of the phone in the event log has when I did STUN:
    3CX Phone System Management Console ID: 10018
    RPS request for Yealink T46S IP Phone of BMAG Studio (401) delivered successfully

    Any clues folks? What am I missing and not seeing?
    I don't want to buy more of these new phones until this works. My old Cisco SPA525G's work fine btw.. I just need more modern phones.
     
    #19 Imaxinar DM, Jan 18, 2018
    Last edited: Jan 18, 2018
  20. NickD_3CX

    NickD_3CX Support Team
    Staff Member 3CX Support

    Joined:
    Jun 2, 2014
    Messages:
    1,281
    Likes Received:
    66
    The way this is done in the background is a bit complex, so there are many scenarios, that is why I said "...may not work...".

    I will just say this:
    If you want to be sure absolutely sure that re-provisioning from the Management Console will work, especially for IP Phones using the SBC, prefer the PnP Provisioning avenue...


    @Imaxinar DM
    A few key pieces of information, The Yealink phone and the 3CX Server, and they on the same LAN/Subnet? I ask because you said that you tried Remote STUN as well.
    Also, if the Yealink and the 3CX Server are behind the same ZyXEL Router, NATing should not play any role, although it does look correct. Mutlicast of course must be allowed.

    So, working with the assumption that the phone and the server are on the same physical LAN and Subnet, the first thing I would suggest looking for is why the phone is not showing up in the Management Console. Run a packet capture on the server, you can do that from the MC as well, Factory Reset the phone amd wait until it comes back online. If it doesn't show up in the "Phones" node, open the capture file with Wireshark and check for the source IP of the phone with something like:
    Code:
    ip.addr==[IP of Phone]
    This should tell you if the server received any information at all from the phone (so its a good starting point).
    Remember, if phone and server are on different subnets, usually multicast packets won't reach one another...
     
Thread Status:
Not open for further replies.