Hi, I am doing an AGI that logs to a database every Agent login/logoff. My idea is to be able to go to this database and check which agents where logged so that I can force their login in case Asterisk goes down for some reason. The problem is that I would need to reload their status from this AGI when Asterisk initializes. Is there a way to do this? One idea I had was to make safe_asterisk to generate a .call file that calls and extension that would call the AGI to log all the agents back on. Is there another way of running an AGI on initialization? Thank you Dov -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060106/4659420f/attachment.htm
There is a sample php script in the contribs folder that shows who is logged in - one of my clients uses it. PaulH ----- Original Message ----- From: Dov Bigio To: asterisk-users@lists.digium.com Sent: Saturday, January 07, 2006 8:24 AM Subject: [Asterisk-Users] Asterisk initialization Hi, I am doing an AGI that logs to a database every Agent login/logoff. My idea is to be able to go to this database and check which agents where logged so that I can force their login in case Asterisk goes down for some reason. The problem is that I would need to reload their status from this AGI when Asterisk initializes. Is there a way to do this? One idea I had was to make safe_asterisk to generate a .call file that calls and extension that would call the AGI to log all the agents back on. Is there another way of running an AGI on initialization? Thank you Dov ------------------------------------------------------------------------------ _______________________________________________ --Bandwidth and Colocation provided by Easynews.com -- Asterisk-Users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060107/fc6b7f55/attachment.htm
Do not know what version you are running, But there are a few ways to do this. There is a persistant setting: from agents.conf ; ; Define whether callbacklogins should be stored in astdb for ; persistence. Persistent logins will be reloaded after ; Asterisk restarts. ; persistentagents=yes If you want to handle it outside of Asterisk via an AGI you can have your AGI execute: AgentCallbackLogin([AgentNo][|[options][|[exten]@context]]): this is providing that you have the information saved in your DB. Personal Opinion: Use the builtin features with the persistentagents options and use the php script in the contribs directory to see who is on. ________________________________ From: asterisk-users-bounces@lists.digium.com [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of Dov Bigio Sent: Friday, January 06, 2006 4:24 PM To: asterisk-users@lists.digium.com Subject: [Asterisk-Users] Asterisk initialization Hi, I am doing an AGI that logs to a database every Agent login/logoff. My idea is to be able to go to this database and check which agents where logged so that I can force their login in case Asterisk goes down for some reason. The problem is that I would need to reload their status from this AGI when Asterisk initializes. Is there a way to do this? One idea I had was to make safe_asterisk to generate a .call file that calls and extension that would call the AGI to log all the agents back on. Is there another way of running an AGI on initialization? Thank you Dov -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060107/e5a0596b/attachment.htm
That's great... I didn't know about the persistentagents features! I'll test it asap! Thank you Dov ----- Original Message ----- From: Alexander Lopez To: Dov Bigio ; Asterisk Users Mailing List - Non-Commercial Discussion Sent: Saturday, January 07, 2006 5:16 PM Subject: RE: [Asterisk-Users] Asterisk initialization Do not know what version you are running, But there are a few ways to do this. There is a persistant setting: from agents.conf ; ; Define whether callbacklogins should be stored in astdb for ; persistence. Persistent logins will be reloaded after ; Asterisk restarts. ; persistentagents=yes If you want to handle it outside of Asterisk via an AGI you can have your AGI execute: AgentCallbackLogin([AgentNo][|[options][|[exten]@context]]): this is providing that you have the information saved in your DB. Personal Opinion: Use the builtin features with the persistentagents options and use the php script in the contribs directory to see who is on. ---------------------------------------------------------------------------- From: asterisk-users-bounces@lists.digium.com [mailto:asterisk-users-bounces@lists.digium.com] On Behalf Of Dov Bigio Sent: Friday, January 06, 2006 4:24 PM To: asterisk-users@lists.digium.com Subject: [Asterisk-Users] Asterisk initialization Hi, I am doing an AGI that logs to a database every Agent login/logoff. My idea is to be able to go to this database and check which agents where logged so that I can force their login in case Asterisk goes down for some reason. The problem is that I would need to reload their status from this AGI when Asterisk initializes. Is there a way to do this? One idea I had was to make safe_asterisk to generate a .call file that calls and extension that would call the AGI to log all the agents back on. Is there another way of running an AGI on initialization? Thank you Dov -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20060109/c436cc0a/attachment.htm