Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

usbmuxd[11535]: [12:02:18.961][1] device_control_input: ERROR (on device): asyncReadComplete, message was too large (65536 bytes, max = 6 #867

Open
Mark6222 opened this issue Feb 15, 2024 · 8 comments

Comments

@Mark6222
Copy link

is there a file size limit

@dorssel
Copy link
Owner

dorssel commented Feb 15, 2024

No, not within usbipd-win.

Maybe due to the extra delay introduced by the USBIP protocol, some reads arrive close together, and usbmuxd is not expecting that. For example: reads are requested 40kB per request. For local USB (real hardware) these requests and their replies are spaced apart normally. But due to USBIP some are completed slightly late, such that they arrives close to the next. And maybe usbmuxd then gets 2×40kB in a single read (just example numbers). Just guessing, though.

@Mark6222
Copy link
Author

how would i fix something like that

@dorssel
Copy link
Owner

dorssel commented Feb 15, 2024

First, try to see if this is indeed the problem. Make a capture while reproducing, see https://github.com/dorssel/usbipd-win/wiki/Troubleshooting. You can improve the timing (only a bit) by opening task manager and giving the usbipd.exe service process realtime priority.

@Mark6222
Copy link
Author

Hi Dorssel, I've believe the issue is to do with usbipd on the windows side as ive tested sideloading an app onto the phone from two Linux boxes using usbip and its worked. ive attached the troubleshooting file below.
log.zip

@Mark6222
Copy link
Author

setting the priority didn't fix the issue

@dorssel
Copy link
Owner

dorssel commented Feb 21, 2024

Yes, it is because of the packet latency introduced by usbipd. Linux does everything in the kernel, and therefore has much better timing. usbipd-win requires user mode software (the drivers themselves do not handle the network USBIP protocol). Therefore, the per packet timing has much more variance. Not really a bug, but unfortunately by design. Your logs show exactly what I meant earlier; the individual packets are not too large (49216 per packet, on line 485 and 489). This is not something that can be fixed.

@Mark6222
Copy link
Author

do you know of any other way to accomplish what I'm trying to do, as this is a brick wall for my project.

@dorssel
Copy link
Owner

dorssel commented Feb 21, 2024

You could try to increase the buffer size of usbmuxd; maybe it's configurable, or else modify the source. From a USB perspective everything seems to be working, it's just that the software on the client cannot handle the timing/bunching of data. Otherwise, I see no options other than to use the device on a native Linux platform instead of forwarding it from Windows.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants