Presence not working

Hi,

I have a very basic problem, I'm using a vanilla asterisk with the latest FOP2. If I login in FOP2 and I change the status of my extension to Do Not Disturb in FOP2, my little icon is not updated in FOP2. I'm not talking about any integration between Asterisk and FOP2.

Thx

Comments

  • edited December 2016
    Hi,

    I was able to track down the issue and it seem to be a bug in fop2.

    If I have the following in buttong.cfg :

    [SIP/ABC299]
    type=extension
    extension=ABC299
    context=ABC
    label=299 - Test
    mailbox=299@ABC
    extenvoicemail=7299@ABC
    group=admin
    originatechannel=Local/299@originate

    and fop2.cfg :

    user=ABC299:1234:all

    The status is not updated because the event is not send the the Asterisk manager. (tested using : ./fop2_server -X 3 -i eth1)

    But If I have :

    [SIP/299]
    type=extension
    extension=299
    context=ABC
    label=299 - Test
    mailbox=299@ABC
    extenvoicemail=7299@ABC
    group=admin
    originatechannel=Local/299@originate

    and fop2.cfg :

    user=299:1234:all

    It his working. I have also tested with abc lowercase and it's also NOT working. I have also test with "sdfghjk" only and it's also not working. that mean as soon as you have alpha character the presence is not working. That also mean FOP2 presence won't work with XiVO/WAZO because they use random alpha numeric name for the sip peers.

    Also, if I manually put this in the asterisk manager using telnet :

    Action: UserEvent
    UserEvent: FOP2ASTDB
    Family: fop2state
    Key: SIP/sdfghjk
    Channel: SIP/sdfghjk
    Value: Out to lunch

    It's working as expected.
  • extension headers are supposed to be numeric, as you usually cannot dial letters from a dialpad. Not sure why are you using alphanumeric extensions, its fine for sip to sip dialing but not for regular phone dialing... in any case you can have a context that accepts numeric extensions and then does whatever you want to dial a device with any name like mixed letters/numbers, etc.

    Best regards,
  • Hi,

    I don't think you understand my problem. It has nothing to do with dialing or anything. It's only regarding the presence on the upper bar.

    FYI but it's not relevant to my issue I'm using alphanumeric sip peer name but using digit only to ring them. For exemple, in my dialplan I'm using 233,1,Dial(SIP/sdfghjk). The phone can then be reach by dialing 233.
  • In that case, in your configuration, you must set etension=233 and log with user=233 in fop2 configurations.

    Best regards,
  • edited January 2017
    HI,

    I'm confuse by your answer. From the test I did, "extension=" need to be equal to "sdfghjk" in my latest example to have the action bar. I'm not sure why are are telling me to use extension = 233 and user=233 because my sip peer name is "SIP/sdfghjk".

    To get back to my problem, do you plan on fixing the issue ? The problem is, if a peername have alphanumeric caracter, the presence dropdown is not working.
  • Consider this:

    [SIP/sdfhjk]
    type=extension
    label=John
    extension=100

    Notice that extension=xxx could be different from the [SIP/xxxx] device.

    That is the first thing I pointed out.. extension header should be numeric, it does not matter at all if the device name is numeric or alphanumeric, or mixed, it is not related, there is no need for them to match. Extension is numeric because it is used to match entries in the dialplan, when pattern matching is modeled around NUMERIC extensions.

    Presence works fine if you have alpha numeric devices with mixed case, but events might fail if the user/extension mapping is not correct.

    You can start fop2_server in debug mode, level 15 (-X 15) to see all interactions between the fop2 browser and fop2 server, and between fop2 server and asterisk ami, and compare actions, commands and event responses.

    Best regards,
  • Hi,

    It is working if I set the extension to 100 but CDR History is then broken. I found that you are using a query that look like this :

    SELECT * FROM cdr WHERE (src='100' OR channel LIKE 'SIP/100-________' OR dst='100' OR dstchannel LIKE 'SIP/100-________' )

    In my case, the channel is SIP/sdfhjk not SIP/100.

    I would really like to have this fix so I could better integrate FOP2 in my solution. Could you please PM me ?

    Thx !
  • Hi,

    You have the php code and queries at your disposal to adapt to your solution! If you want me to adapt it to your solution, I can do so for sure, for a fee. My hourly rates are published in www.fop2.com/buy.php.

    FOP2 comes as is, it will work mostly and if not, you can adapt it as it is very extensible. If you do not have the time or energy, then you can fund/sponsor/pay for new features or customizations.

    Best regards,
Sign In or Register to comment.