@eschmidbauer - can you help testing somehow? Not having the possibility to test properly here, working mainly from home these days I can't use many devices. First would be to make sure existing your existing config is still working fine. I tried to be very non-intrusive as much as possible in the old code and operation mode.
Then, to test in-memory only presentity records, set:
```
modparam("presence", "publ_cache", 2)
```
You have to use latest master branch. I did basic tests with baresip for handling the PUBLISH requests and I could see they are in database presentity table if publ_cache!=2 as well as in memory via rpc command if publ_cache==2.
You can set also subscription records in memory with:
```
modparam("presence", "subs_db_mode", 0)
```
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/commit/f917318c1e5fefa4106eaaf46123506…
### Description
Much of this issue is repeated from [#2018](https://github.com/kamailio/kamailio/issues/2018). Since it's closed and has no activity, I'm opening this issue.
Kamailio 5.3.3 won't start when using `kamailio-tls-modules` on Ubuntu/18.04.4 unless `tls_force_run` is set in kamailio.cfg
```
$ grep CRITICAL /var/log/kamailio/kamailio
Apr 14 17:18:39 kam-01 /usr/sbin/kamailio[22073]: CRITICAL: tls [tls_init.c:677]: init_tls_h(): installed openssl library version is too different from the library the kamailio tls module was compiled with: installed "OpenSSL 1.1.1 11 Sep 2018" (0x1010100f), compiled "OpenSSL 1.1.0g 2 Nov 2017" (0x1010007f).#012 Please make sure a compatible version is used (tls_force_run in kamailio.cfg will override this check)
Apr 14 17:18:39 kam-01 /usr/sbin/kamailio[22073]: CRITICAL: <core> [main.c:2768]: main(): could not initialize tls, exiting...
```
```
$ cat /etc/apt/sources.list.d/kamailio.list
deb http://deb.kamailio.org/kamailio53 bionic main
deb-src http://deb.kamailio.org/kamailio53 bionic main
$
$ dpkg -l | awk '/kam/ { print $2 " " $3 }'
kamailio 5.3.3+bionic
kamailio-extra-modules:amd64 5.3.3+bionic
kamailio-mysql-modules:amd64 5.3.3+bionic
kamailio-snmpstats-modules:amd64 5.3.3+bionic
kamailio-tls-modules:amd64 5.3.3+bionic
kamailio-websocket-modules:amd64 5.3.3+bionic
$
$ /usr/sbin/kamailio -v
version: kamailio 5.3.3 (x86_64/linux)
flags: USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS, DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MMAP, PKG_MALLOC, Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES, TLS_PTHREAD_MUTEX_SHARED
ADAPTIVE_WAIT_LOOPS 1024, MAX_RECV_BUFFER_SIZE 262144, MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: unknown
compiled with gcc 7.3.0
$
$ /usr/bin/openssl version
OpenSSL 1.1.1 11 Sep 2018
```
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2288
Module: kamailio
Branch: master
Commit: 79d07fe00af8e30910a4e1b23b641ebcc96f0895
URL: https://github.com/kamailio/kamailio/commit/79d07fe00af8e30910a4e1b23b641eb…
Author: Kamailio Dev <kamailio.dev(a)kamailio.org>
Committer: Kamailio Dev <kamailio.dev(a)kamailio.org>
Date: 2020-04-20T17:31:14+02:00
modules: readme files regenerated - presence ... [skip ci]
---
Modified: src/modules/presence/README
---
Diff: https://github.com/kamailio/kamailio/commit/79d07fe00af8e30910a4e1b23b641eb…
Patch: https://github.com/kamailio/kamailio/commit/79d07fe00af8e30910a4e1b23b641eb…
---
diff --git a/src/modules/presence/README b/src/modules/presence/README
index d0f3e6fa1a..c4ba8ca1b1 100644
--- a/src/modules/presence/README
+++ b/src/modules/presence/README
@@ -604,12 +604,18 @@ modparam("presence", "subs_db_mode", 1)
3.19. publ_cache (int)
- To improve performance, the presence module holds by default a publish
- cache that says if a certain publication exists in database. This is
- only a list of URI + event, so it does not use much memory. The cache
- is used when a Subscription is received to check if there is any
- published state in database. This way unnecessary queries in presentity
- table are avoided.
+ To improve performance, the presence module can operate in a couple of
+ modes related to how PUBLISH data is stored. If publ_cache is 0, then
+ no information is store in memory.
+
+ If publ_cache is 1, then the module keeps in memory an index of the
+ records stored in database, In this mode it keeps only the list of URIs
+ and events, so it does not use much memory. The cache is used when a
+ Subscription is received to check if there is any published state in
+ database. This way unnecessary queries in presentity table are avoided.
+
+ If publ_cache is 2, then the module keeps everything related to PUBLISH
+ requests in memory, not storing anything in the database.
Setting this parameter to 0 will disable the usage of the publish
cache. This is desirable when you have more servers sharing the same
Module: kamailio
Branch: master
Commit: 6aafae5d2803387abe4d634c7d0e740386ca20b4
URL: https://github.com/kamailio/kamailio/commit/6aafae5d2803387abe4d634c7d0e740…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2020-04-20T17:21:08+02:00
presence: updated docs for publ_cache parameter
---
Modified: src/modules/presence/doc/presence_admin.xml
---
Diff: https://github.com/kamailio/kamailio/commit/6aafae5d2803387abe4d634c7d0e740…
Patch: https://github.com/kamailio/kamailio/commit/6aafae5d2803387abe4d634c7d0e740…
---
diff --git a/src/modules/presence/doc/presence_admin.xml b/src/modules/presence/doc/presence_admin.xml
index 8f65c394e2..850e929f67 100644
--- a/src/modules/presence/doc/presence_admin.xml
+++ b/src/modules/presence/doc/presence_admin.xml
@@ -525,12 +525,20 @@ modparam("presence", "subs_db_mode", 1)
<section id="presence.p.publ_cache">
<title><varname>publ_cache</varname> (int)</title>
<para>
- To improve performance, the presence module holds by default a
- publish cache that says if a certain publication exists in database.
- This is only a list of URI + event, so it does not use much memory.
- The cache is used when a Subscription is received to check if there
- is any published state in database. This way unnecessary queries in
- presentity table are avoided.
+ To improve performance, the presence module can operate in a couple of
+ modes related to how PUBLISH data is stored. If publ_cache is 0,
+ then no information is store in memory.
+ </para>
+ <para>
+ If publ_cache is 1, then the module keeps in memory an index of the
+ records stored in database, In this mode it keeps only the list of URIs
+ and events, so it does not use much memory. The cache is used when a
+ Subscription is received to check if there is any published state in
+ database. This way unnecessary queries in presentity table are avoided.
+ </para>
+ <para>
+ If publ_cache is 2, then the module keeps everything related to PUBLISH
+ requests in memory, not storing anything in the database.
</para>
<para>
Setting this parameter to 0 will disable the usage of the publish