Search:
Asterisk presence
Asterisk presence
Current CVS -HEAD provides some support of SIP presence as defined in RFC 3856 - A Presence Event Package for the Session Initiation Protocol (SIP). The release version (1.0.9) has some support too.
To support this, you have to somehow tell which SIP user is mapped to the extension mentioned. A "hint" priority is used to describe this, as in this example:
exten => 100,hint,SIP/peername
(it says, that for presence purposes, extension 100's presence should be mapped the SIP peer)
- IMPORTANT: In Asterisk 1.4 the inner workings of the hint functionality have slightly changed. It is now imperative that you set a call-limit (even if it's an arbitrarily-high value like 100) and/or the new limitonpeers value in sip.conf. Presence will not work without this. If you are using friend instead of peer, you will need limitonpeers = yes as well as a call-limit statement (new in Asterisk 1.4) for each SIP device
- If you do not add a hint, the extension will be free ("open") always, more or less.
- If you add incominglimit=1 to your peer (in Asterisk 1.2 only) in sip.conf, the SIP channel will notify you when that extension is busy.
Extension and device state combined, no user state!
Asterisk - with or without the patch - does not currently support PUBLISH method for publishing presence documents in Presence Information Data Format (PIDF) defined in RFC 3863, but it can generate NOTIFY to SUBSCRIBEd users when REGISTER occurs and also when the client disconnects.This works for example with Xten's Eyebeam client, but can also work with several other phones that support SIP presence. Due to the lack of PUBLISH method support, there's no support of extended states (Away, Do not disturb, Busy). You can subscribe to extension state for any channel that supports device state notification. In CVS head, the Agent channel, SIP and IAX2 supports it.
In order to fix this, we need a user abstraction in Asterisk, something that will be worked on in development version 1.3.
Phones known to work with the current implementation of SIP Presence
- Snom (various models)
- Polycom IP30x/IP50x/IP600
- Xten EyeBeam
- Grandstream GXP2000 (Firmware >= 1.0.1.13)
- Aastra 480i
- Aastra 9133i
- Thomson ST2030
- Linksys SPA962/932 - Tutorial
- Jin302 (Firmware > 1.7)
Specific Phone Configuration
Polycom Phones
To enable presence on the Polycom phones you must add a contact to the contact directory. The CONTACT parameter must match the extension of the phone you wish to monitor and the WATCH BUDDY parameter must be set to "enabled". Also, make sure that the first line of the Polycom is registred with your Asterisk server. Polycom tends to use the configuration from the first line for all subscriptions.With SIP v1.5.2, The Polycom phones may "forget" their subscription for presence information, and return a 450 error to the presence notification. There is no indication on the phone that this has happened, except that the buddy status no longer changes. The only workarounds is to this is to reboot the phone or toggle the WATCH BUDDY parameter to disabled, then to enabled. This bug does not affect other operations on the phone.
Note: There is a quoted limit of 8 (I've found an actual limit of 7) watchable buddies, so if you go to buy the attendant console solution, don't expect to be able to monitor more than 7 other extensions. (see below)
Note: As of firmware version 1.6.6 the limit has been raised on the 601 to 48 watchable buddies. Still 8 on the 501s tho. Yay polycom!
Parking and BLF
This can be achieved in asterisk 1.2 with a patch, and is built in to asterisk 1.4.Parking BLF in Asterisk 1.2
- Patch/bug 5779 added hint support for the Local channel construct which allows for monitoring of the parking lot/ parked calls (by checking for existence of a dialplan extension).
- NOTE: In order to set up a parking BLF with this patch in Asterisk 1.2.X, you must set up the following in the context where your SIP phone registers:
exten => 701,1,ParkedCall(701)
exten => 701,hint,Local/701@ParkedCalls
exten => 701,hint,Local/701@ParkedCalls
Parking BLF in Asterisk 1.4
- NOTE: In order to set up the built-in parking BLF functionality in Asterisk 1.4, you must set up the following in the context where your SIP Phone registers...
include => parkedcalls
exten => 701,1,ParkedCall(701)
exten => 701,hint,park:701@parkedcalls
exten => 701,1,ParkedCall(701)
exten => 701,hint,park:701@parkedcalls
This differs from the syntax originally described in the patch/bug report for 1.2 above. If you are using metermaid patch with Asterisk 1.2.X and decide to upgrade to 1.4 expecting it to 'just work' you are in for a harsh and poorly documented surprise.
Update for Asterisk 1.6 (under development)
Russel (Digium) has implemented a DEVSTATE function that is described here in more detail. There is a new version that works with 1.4 herePresence across PBXs
Nuitari wrote a PHP script which connects to the manager of multiple PBXs and uses Russel's (Digium) devstate to set blf across PBXs. You can find it here
See also
- Asterisk Presence for Cisco 79x1 Phones
- Asterisk standard extensions
- Asterisk cli show hints
- Asterisk SIP Messaging: A hack/patch
- Asterisk Jabber
- BLF
- Asterisk SLA
- Asterisk func Devstate
- Unified communications DialApplet
Created by: juraj,Last modification on Sat 21 of Mar, 2009 [15:28 UTC] by dialapplet

Page Changes
