# Modalai Server Client Issue

Source: https://forum.modalai.com/topic/4065/modalai-server-client-issue
Category: General Questions (https://forum.modalai.com/category/2/general-questions)
Posted: 2025-01-07 06:27:09 UTC by Karl-pan
Replies: 6 · Views: 1058

## Karl-pan · 2025-01-07 06:27:09 UTC

I've been working with the ModalAI server and encountered a warning while creating a client that subscribes to the server. The warning states: "too many clients are trying to connect," even when the machine has just been rebooted.

Upon inspecting the source code, the warning occurs when no channels are available (i.e., no channel is uninitialized or disconnected). This behavior seems abnormal during a reboot.

Has anyone experienced similar issues or have insights into why channels might be occupied right after a reboot? Any suggestions for further debugging or resolving this would be appreciated.

## Reply by Alex Kushleyev (ModalAI staff) · 2025-01-08 20:17:47 UTC

@Karl-pan ,

Are you able to provide a minimal example to help reproduce? All of our services that have MPA servers are running fine, as far as we know, so this may be related to an implementation detail in your code.

Please try to reduce the server / client code to bare minimum to reproduce the error.

It would also be helpful to know which version of VOXL2 SDK you are using (please confirm VOXL2 / VOXL2 mini).

Alex

## Reply by Karl-pan · 2025-01-09 06:52:16 UTC (in reply to Alex Kushleyev)

Hi @Alex-Kushleyev,

Thank you for your response. Attached below is a screenshot of my subscription code for your reference:
![Screenshot from 2025-01-09 14-33-51.png](https://forum.modalai.com/assets/uploads/files/1736405512488-screenshot-from-2025-01-09-14-33-51.png) 
![Screenshot from 2025-01-09 14-48-36.png](https://forum.modalai.com/assets/uploads/files/1736405521532-screenshot-from-2025-01-09-14-48-36.png) 
I suspect the issue might be related to the pipe_client_get_next_available_channel() function. Please let me know if there are any specific tests you would recommend to further diagnose this issue.

Karl

## Reply by Karl-pan · 2025-01-10 03:53:52 UTC (in reply to Alex Kushleyev)

Hi @Alex-Kushleyev,

Here are links to the relevant parts of my source code:
https://pastebin.com/aXYrE9qZ
https://pastebin.com/CkHsVC5N
Additionally, I have attached another image below showing the version of the VOXL2 SDK I am using for your reference
![Screenshot from 2025-01-10 11-44-21.png](https://forum.modalai.com/assets/uploads/files/1736480729509-screenshot-from-2025-01-10-11-44-21.png) 

Karl

## Reply by Alex Kushleyev (ModalAI staff) · 2025-01-13 17:20:19 UTC (in reply to Karl-pan)

@Karl-pan , thank you, i will take a look shortly.

Alex

## Reply by tom (ModalAI staff) · 2025-01-13 18:04:18 UTC (in reply to Karl-pan)

@Karl-pan It looks as though you're running a pretty old version of the SDK. I'd recommend for development loading the latest version of the SDK (1.4.0). Otherwise when developing you'd have to reference the source of the packages at the tagged version in which was included in the older SDK.

## Reply by Alex Kushleyev (ModalAI staff) · 2025-01-13 22:31:07 UTC (in reply to tom)

Agreed! thanks for noticing, Tom. Definitely should be tested on a recent SDK..

Alex
