CNAM Cache Option

Hi,

Had a question and didn’t really find anything on Google

I definitely want to make use of the CNAM query cache option in the Caller ID Lookup module. We are using it with OpenCNAM.

How would I clear up the cache? Every once in a while I would definitely want to clear it up

I also researched on how to use astDB, and how to clear up one specific part of it, but also very unclear.

Thanks in advance

Cached names are stored in the Asterisk phone book, you can use the phone book module to edit delete entries directly.

Thank you. I tested and it worked. Now the question is - how do we get asterisk to read the cache entries on an incoming call?

I researched and saw that superfecta can pull data from asterisk phonebook. When I tested - it worked. However, it’s “complicated”

  • Superfecta doesn’t have an option to cache results, so it is not saving any data
  • On the DID section, I still have the option to enable a CID lookup source. When I do enable it and use superfecta at the same time, the CID lookup source still runs a query, which defeats the purpose.

I don’t mind putting in a small script in extensions_custom where it uses the “if” command, where if a db entry already exists for this phone number, skip the CID lookup check. I just don’t exactly know how to write that up, if this is the end result needed

Using freepbx 2.11

Thanks again

You can use either CallerID Lookup or Superfecta on an inbound route, not both.

I don’t use the CallerID Lookup module much, IIRC it will automatically pull CNAM from the phonebook if cache results is enabled.

Superfecta does have a cache, look in the list of modules for “Superfecta Cache” and you will see it there to configure. You can’t easily browse the cache to clean up entries, but entries do expire after a user selectable number of days so cache pollution is not that much of an issue. One person’s ‘complicated’ is another’s ‘feature rich’.