KNX2 stopps working after a while (received disconnect response status 0x21)

Hello all,
I have just set up a fresh openhabian install and now I encounter the same problems. On my bus system I do have a GIRA X1 (which can act as an KNX/IP Gateway) and also a GIRA KNX-IP GW.
I do not have a knxd running because it was my understanding that this is only an intermediate service between the bus and the openhab2 instance which is not needed.
This set up has been working on openhab pre 2.4 flawlessly.

Are there any new thoughts regarding the root cause of this problem?

My situation is exactly as desribed here: knx works fine for about 2 hours, then it disconnects and cannot reconnect.

Below is my knx.things [only the connection part]

Any thoughts?
Best,
Hanns-Joerg

Bridge	knx:ip:GIRAKNXIP "GIRA X1 " @ "KNX" [
	type="TUNNEL",
	ipAddress="192.168.0.4", //war .93 fĆ¼r KNX-IP-GW
	portNumber=3671,
	localIp="192.168.0.11",
	readingPause=50,
	responseTimeout=10,
	readRetriesLimit=3,
	autoReconnectPeriod=1,
	localSourceAddr="0.0.2" ]
	{
                Thing device KNXDUMMY "KNXDEVICE" @ "KNX" [ fetch=false, pingInterval=600, readInterval=0 ]
                { ..... }

Hello
Same issue on my Raspi. Iā€™m using MDTā€™s Ā«SCN-IP000.02 IP InterfaceĀ».
It works like i charm but only for a few hours, then the KNX is disconnected.
All other bindings are not affected, only the KNX Binding (binding-knx - 2.4.0).
I have absolute no clue what to change in my config. (see some excerpts and netstat below)
Is there anyone who solved the issue?
Thanks to all in advance who provide any hints or solutionā€¦

BR, urs

openHABianPi

Ip = 192.168.10.23
Release = Raspbian GNU/Linux 9 (stretch)
Kernel = Linux 4.14.79+
Platform = Raspberry Pi Model B Rev 2
Updates = 0 apt updates available.

knx.things

Bridge knx:ip:bridge [
ipAddress=ā€œ192.168.10.11ā€,
portNumber=3671,
localIp=ā€œ192.168.10.23ā€,
type=ā€œTUNNELā€,
readingPause=50,
responseTimeout=10,
readRetriesLimit=3,
autoReconnectPeriod=1,
localSourceAddr="0.0.0*
] {
Thing device generic [
address=ā€œ1.1.209ā€,
fetch=true,
pingInterval=300,
readInterval=3600
]
{
Type switch : Licht_Aussen_Terasse ā€œTerrasseā€ [ ga=ā€œ1/1/137ā€ ]
Type switch : Licht_Aussen_Eingang ā€œEingang & Garageā€ [ ga=ā€œ1/1/144ā€ ]
}
}

netstat -i

Kernel-Schnittstellentabelle
Iface MTU RX-OK RX-ERR RX-DRP RX-OVR TX-OK TX-ERR TX-DRP TX-OVR Flg
eth0 1500 308838 0 265 0 194660 0 0 0 BMRU
lo 65536 837 0 0 0 837 0 0 0 LRU

All:

not a solution yet. But I installed knxd on the raspi running openhabian. I have set up knxd so that I can connect to the bus manually (knxtool commandline). However, I did not change my thing definition. This means, I do not use knxd for openhabian, but I have a constantly working connection right now.

Best,
Hajoka

@hajoka could you please share the config of your knxd?
Thanks

Dear,
Iā€™ve the same problem. Are there news about it?
Iā€™m try to restart knx binding as write from andrzej_szymkowicz but Iā€™m using sendCommand without good results because I receive a message where OH say to me problems with accessing permission of rsa file. Iā€™m using openhabian and I donā€™t understand because there the openhab and the openhabian users. I think I need to use openhab user but I donā€™t fine its password on intenet.

Can you help me? My porting work for upgrate to KNX2 from KNX1 is not usable if KNX2 stop working.

Thanks

I solved it by programming a service restart every time it goes offline.

I got the result by creating in my raspberry openhabian installation this sh file (install sshpass before with: apt-get install sshpass):

// restartknx.sh
sudo -u [YOUR_SYSTEM_USER] sshpass -p [YOUR_SYSTEM_PASSWORD] ssh openhab@localhost -p 8101 'bundle:restart org.openhab.binding.knx'

and running it by this cron rule:

rule "Restart KNX"

when
        
	Time cron "0/10 * * ? * *" 

then
  
	val allThings = sendHttpGetRequest("http://192.168.1.81:8080/rest/things")

	  if(allThings.indexOf('BRIDGE_OFFLINE"},"editable":false,"label":"KNK [ATT] 1.1.4')>0){
	
    logInfo("KNX", "KNX Autorestart")
    
	    var String esito = executeCommandLine("/etc/openhab2/scripts/restartknx.sh",5000)

	    if(esito!=''){
      
	        logInfo("KNX", "Autorestart completed (" + esito +")")
    
	    }
	
  }

end

In the sh file I check offline thing status searching ā€œBRIDGE_OFFLINEā€},ā€œeditableā€:false,ā€œlabelā€:ā€œKNK [ATT] 1.1.4ā€ string into json sendHttpGetRequest result. This is a specific string of a my knx thing and you must search a your specific different string.

Remember to change [YOUR_SYSTEM_USER] and [YOUR_SYSTEM_PASSWORD] with your openhabian credentials of a my knx thing and you can search a your specific different string.