-
Notifications
You must be signed in to change notification settings - Fork 660
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
Error: list: Packet length 49989 exceeds max length of 34000 #1048
Comments
Does 4606d0e work for you? |
Thank you very much @mscdex! Your latest change did the trick. It now works without a problem. Do you know already when this feature will be available on npm? |
It seems fixed and released. Thanks! |
Do still exist, when user add something like "source /opt/intel/vtune_amplifier_xe_2013/amplxe-vars.sh" to
when read data length from first 4 bytes, would get a wrong length exceed max length, I think other sftp client would just ignore these data. Code should be in Line 207 in a56e70e
|
@zxdong262 There's nothing that can be done in that situation because SFTP is completely binary in nature so there is no way any (generic) SFTP client could reliably ignore any such data. Besides, most bashrc scripts exit immediately when they detect a non-interactive mode. |
How about ignore length seems impossible like 1349281121(or set a impossible const to compare) intead of throw error? Is that safe or right thing to do? |
It's not safe. |
A folder on a SFTP server does have a lot of files (history of 1 year so far, 340 files). I try to list that folder and i get this error:
Error: list: Packet length 49989 exceeds max length of 34000
If i adjust the max packet size (?) to 100000 it does list my files.
The questions are now:
Why is this limit there?
Update: it is specified as min packet length for servers: https://datatracker.ietf.org/doc/html/draft-ietf-secsh-filexfer-13#section-4
Can I adjust the limit by an option? (not possible as far as I can see)
Is there a better way to implement this?
Can you split the command in separate packets?
-> there could be even more files in this folder
So it makes not really sense to increase the limit. As the limit will be reached sometime again in the future.
Here is the limit that i adjusted on my machine:
ssh2/lib/protocol/SFTP.js
Line 157 in 0af296d
I hope we have a better way to implement this as the folder size should not depend on the packet size.
Thank you for your help
The text was updated successfully, but these errors were encountered: