Closed bestxpp closed 1 month ago
@bestxpp - I don't think changing the length here won't help.
I'm assuming you're looking at the data path sending from xrdp to the client.
Let's start with the length itself (1048576). This comes from the application which is writing over the channel. You should be able to see this by running strace
on the application making the copy.
This moves through the FUSE filesystem, and ends up in the redirector in chansrv. The write happens in devredir_file_write()
which calls send_channel_data()
in chansrv.c:-
This doesn't however send a 1Mb PDU over the network! send_channel_data()
splits the large packet up into smaller ones of approximately 1600 bytes using fragmentation. These are then passed on to xrdp where they are sent as separate PDUs to the client.
There's an overview of the process in section 1.3.3 of [MS-RDPBCGR]
At the moment there's no mechanism for prioritising the PDUs - they're send by xrdp as they arrive.
If you want to try changing the length of the write, a cheap way to start will be to use a different utility to do the copy. Maybe try setting a block size with tar(?) As I said, you can use strace
to see the length used by the utility.
@bestxpp - I don't think changing the length here won't help.
I'm assuming you're looking at the data path sending from xrdp to the client.
Let's start with the length itself (1048576). This comes from the application which is writing over the channel. You should be able to see this by running
strace
on the application making the copy.This moves through the FUSE filesystem, and ends up in the redirector in chansrv. The write happens in
devredir_file_write()
which callssend_channel_data()
in chansrv.c:-This doesn't however send a 1Mb PDU over the network!
send_channel_data()
splits the large packet up into smaller ones of approximately 1600 bytes using fragmentation. These are then passed on to xrdp where they are sent as separate PDUs to the client.There's an overview of the process in section 1.3.3 of [MS-RDPBCGR]
At the moment there's no mechanism for prioritising the PDUs - they're send by xrdp as they arrive.
If you want to try changing the length of the write, a cheap way to start will be to use a different utility to do the copy. Maybe try setting a block size with tar(?) As I said, you can use
strace
to see the length used by the utility.
Ok thanks
xrdp version
0.9.21.1
Detailed xrdp version, build options
Operating system & version
debian 12
Installation method
dnf / apt / zypper / pkg / etc
Which backend do you use?
freerdp
What desktop environment do you use?
xfce
Environment xrdp running on
yes
What's your client?
freerdp
Area(s) with issue?
File transfer / drive redirection
Steps to reproduce
When I transfer files using rdpdr, the desktop is very laggy
✔️ Expected Behavior
How can I modify the file and its length to reduce the bandwidth usage during file copying
I debugged the RDPDR code and found that the file offset received in the IRP_MJ_READ event is always: [file_id=1] length=1048576, offset=0 [file_id=1] length=1048576, offset=1048576 [file_id=1] length=1048576, offset=2097152
❌ Actual Behavior
the desktop is very laggy
Anything else?
nothing