Quantcast
Channel: All VoIP / SIP Phones posts
Viewing all articles
Browse latest Browse all 13863

Re: Corporate ldap listing goes missing after search

$
0
0

Hey, 

 

I had the same Issue and I think I just solved it. 

Note: I have a configured corporate Directory. Which is an OpenLDAP Server, with an amount of 5000 entries.

 

So, sometimes (and I couldn't figured out which actions exactly causes this problem) I dont receive any results when Im using the Directory. All I see is the screen with "Search: XXX). 

 

This seems to happen, always when I close the Directory and then re-open it. But not every time, very confusing. A reboot always fixed it. But I just can't always reboot the phone to use the directory

 

So I made some analyses on my OpenLDAP-Server and I figured out, that always when this happens. The Phone didn't close the TCP-Connection to my OpenLDAP properly. Its still established. This can lead to times, that a single phone has 3 TCP-Connections to the LDAP-Server (Port 389). 

 

When you close these Ports. It works for me. So I wrote script, which does that and put it in a cronjob.

 

Here you see the script:

 

"#!/bin/bash

 

# Get Array of ESTABLISHED TCP PORTS, FROM LDAP SOCKET
PORTS=($(ss -t '( dport = :389 or sport = :389 )' | grep ^ESTAB | cut -d ':' -f3))

PORTSLENGTH=${#PORTS[@]}

 

# KILL ESTABLISHED PORTS
for ((i=0;i<${PORTSLENGTH};i++ ));
do
(tcpkill -i ens32 -9 port ${PORTS[$i]} &)


done"

 

What does this script do:

It gets all established Source-Ports (from the Phones), and kills them synchron. Put this in a cronjob, which execute it every hour and u should be fine.

Note: You may need to install tcpkill to run this. 

 

My Setup:

Polycom Soundstations IP6000 / IP 7000

UCS: 4.0.11.0583

BootROM: 5.0.11.0282

OpenLDAP: 2.4.42

 

 


Viewing all articles
Browse latest Browse all 13863

Trending Articles