Page 1 of 1

I have a puzzling issue which may or may not be Linux/CMX

Posted: Wed 12 Jul 2023 4:00 pm
by broadstairs
Now I don't know how many (if any) run CMX using Linux not on an RPi. I have been running now for a while using a Gigabyte Brix BABT 1900 Celeron powered mini PC with Baytrail graphics and Linux using openSUSE Leap 15.4. I also started to get WXSim running under Linux using Wine on the same PC. Initially I thought that my issue was related to WXSim/Wine but now I'm not sure, hence asking others here.

Now to the issue. Over time the number of clients connected to the display increases to a point where I get

Code: Select all

Maximum number of clients reached
Maximum number of clients reached0024:err:winediag:x11drv_init_thread_data x11drv: Can't open display: :0.
where my OS has a limit of 255 clients. Now since this still happens albeit more slowly running only CMX it is puzzling since in theory CMX or Mono do not open any display connections. I do not want to up the number of possible clients since this only delays the inevitable!

Has anyone else seen this issue? Has anyone any ideas about this?

Stuart

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Wed 12 Jul 2023 5:04 pm
by freddie
I use Linux and know a bit about it.

It's generally due to buggy Wine applications not clearing up their resources properly. Depending on how often you experience this error, it might be an idea to have a scheduled reboot - perhaps daily.

If you Google the error (wine Maximum number of clients reached) you get some examples of workarounds, but they can be application-specific.

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Wed 12 Jul 2023 6:51 pm
by broadstairs
You missed my point, this is still happening without wine being used. Only Mono/CMX running. Yes Wine may make it worse but right now after a reboot is still happening.

Stuart

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Wed 12 Jul 2023 7:01 pm
by freddie
The error message you supplied suggests wine is still running somehow...

MX doesn't touch x11 code.

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Wed 12 Jul 2023 9:16 pm
by broadstairs
Yes but the point is that I am still seeing display clients increasing despite not now running Wine with anything. Obviously the error will only show up if something tries to open the display so now I'm waiting for it to hit 255 again and see what happens. You can monitor display clients by command in Linux which is what I'm doing and with no visible open windows it has hit now 130 from less that 90 first thing this morning.

I just wanted to know if anyone had seen such an error from any application while running Mono/CMX or if anyone else was using similar hardware.

Stuart

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Wed 12 Jul 2023 9:26 pm
by freddie
I've been running MX for 8 years and have never seen a single display client listed. I don't use Wine so don't have the x11 libraries installed.

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Thu 13 Jul 2023 7:47 am
by HansR
broadstairs wrote: Wed 12 Jul 2023 9:16 pm Yes but the point is that I am still seeing display clients increasing despite not now running Wine with anything. Obviously the error will only show up if something tries to open the display so now I'm waiting for it to hit 255 again and see what happens. You can monitor display clients by command in Linux which is what I'm doing and with no visible open windows it has hit now 130 from less that 90 first thing this morning.

I just wanted to know if anyone had seen such an error from any application while running Mono/CMX or if anyone else was using similar hardware.

Stuart
I think your config is pretty unique so don't count too much on others.

What you can do is find out which process is the parent process of those display clients (use pstree and pid and ppid when necessary)
See also: https://en.wikipedia.org/wiki/Pstree

The parent of the display clients should tell your where it comes from.

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Thu 13 Jul 2023 8:46 am
by broadstairs
The issue is that xrestop displays the active clients but does not show the PID values for those marked unknown so I have no PID to compare to either pstree or anything else which shows active tasks. Also xlsclients does not list any active clients at all even when I get the error message!

The more I think about this I believe it is a problem in this version of Linux with this hardware and nothing to do with either CMX or Wine.

Stuart

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Thu 13 Jul 2023 8:51 am
by HansR
broadstairs wrote: Thu 13 Jul 2023 8:46 am The more I think about this I believe it is a problem in this version of Linux with this hardware and nothing to do with either CMX or Wine.
Definitely not with CMX :D
Anyway, you will need to research what spawns the client processes and then try to inhibit that.
Good luck !

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Thu 13 Jul 2023 7:32 pm
by jlmr731
you can try lsof -U (might have to pipe it to less to page through it all like lsof -U|less )
you should be able to see what process taking it all up, then whatever process is is you can use killall nameofprocess

once you know what it is then you can look into why it doing bad things

Re: I have a puzzling issue which may or may not be Linux/CMX

Posted: Fri 14 Jul 2023 9:18 am
by broadstairs
For those who might have a passing interest.....
I decided last evening to update to the latest stable openSUSE 15.5 to see if it made any difference and the answer so far is yes. So far today the number of display clients connected has been stable around 30 since the update. So it is hopeful that this might be solved, although there were no reports of the issue on the forums or bugzilla database. Now to let it run including Wine/WXSim for 24 hours to see how things go.

Stuart