### Setup Description + Problem Description
I am running a open5gs (4G Core network) in an OpenStack VM with internal IP 10.4.128.6 and Floating IP 172.24.15.10 and entire (Kamailio IMS + FoHSS) system in another OpenStack VM with internal IP 10.4.128.21 and Floating IP 172.24.15.30. eNB (srslte) is running on a physical machine with IP 192.168.49.125.
Kamailio is built from the sources using the forked repo in this [link](https://github.com/herlesupreeth/kamailio/tree/5.3). This forked repo has a fix for handling IMS registration when 4G Core Network is behind a NAT among other fixes.
IMS config files - [Kamailio_IMS_Config.zip](https://github.com/kamailio/kamailio/files/4255538/Kamailio_IMS_Config.zip)
PCSCF, SCSCF, ICSCF are run as separate systemctl process
LTE UEs are configured with two APNs - "internet" APN for best effort traffic - IP range 192.168.100.0/24 - "ims" APN for IMS - IP range 192.168.101.0/24.
Upon performing the IMS registration, uac module is being used to achieve NATPING by sending OPTIONS message as per the PCSCF script. However, I observe a strange behaviour where the first OPTIONS message sent by the PCSCF is replied with 200 OK and the subsequent message times out with 408 (most of the times even the first OPTIONS message does'nt gets a 200 OK)
!!! IMPORTANT NOTE !! This behaviour is not seen if I run the 4G Core Network and Kamailio IMS + FoHSS is run in a single VM i.e. CN not behind a NAT
#### Reproduction
Upon performing the IMS registration, uac module is being used to achieve NATPING by sending OPTIONS message as per the PCSCF script. However, I observe a strange behaviour where the first OPTIONS message sent by the PCSCF is replied with 200 OK and the subsequent message times out with 408 (most of the times even the first OPTIONS message does'nt gets a 200 OK)
#### Debugging Data
PCAP at eNB machine and VM running (Kamailio IMS + FoHSS) attached below - [pcaps.zip](https://github.com/kamailio/kamailio/files/4255628/pcaps.zip)
#### Log Messages
Since the log message from PCSCF, SCSCF and ICSCF is too long I am attaching it as file below. Following is the log from journalctl for PCSCF, SCSCF and ICSCF combined [kamailio_log.txt](https://github.com/kamailio/kamailio/files/4255561/kamailio_log.txt)
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
``` version: kamailio 5.3.2 (x86_64/linux) 842fef 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: 842fef compiled on 11:43:39 Feb 26 2020 with gcc 7.4.0 ```
* **Operating System**:
``` NAME="Ubuntu" VERSION="18.04.3 LTS (Bionic Beaver)" ID=ubuntu ID_LIKE=debian PRETTY_NAME="Ubuntu 18.04.3 LTS" VERSION_ID="18.04" HOME_URL="https://www.ubuntu.com/" SUPPORT_URL="https://help.ubuntu.com/" BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy" VERSION_CODENAME=bionic UBUNTU_CODENAME=bionic ```
I am not sure where to start looking for debugging this strange behaviour, any hints or pointer would be really helpful. Many thanks in advance.
Regards, Supreeth
Closing this issue as I solved it by syncing time/date in my VMs (they were out of sync by 1 hr)
Closed #2231.
Sorry re-opening this again as it was a false alarm and worked only once.
Reopened #2231.
Couple of remarks:
* we do not support forked deployments, if you did some fixes or added new features, consider making a pull request in order to review and merge in main tree and have the devs team trying to help on related issues
* uac module is not designed internally to send keepalives, so I guess you do something via kamailio.cfg , which means it is not an issue in the code, therefore it should not be reported via issue/bug tracker, but discussed and sorted out via sr-users@lists.kamailio.org mailing list. It is not a problem with kamailio code, but something about using kamailio.
Considering the above, I am closing this issue.
Closed #2231.