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

Fabric/Paramiko fails when uploading big files #31

Open
sebastien opened this issue Oct 31, 2011 · 4 comments
Open

Fabric/Paramiko fails when uploading big files #31

sebastien opened this issue Oct 31, 2011 · 4 comments

Comments

@sebastien
Copy link
Owner

the file_write and file_upload method should support big (10M+) files. I had consistent failures with a 47Mb file.

The idea would be to split the file in chunks, and make sure that the chunks are transferred (using bz2 to compress the content, base64 to transfer as string and SHA256 as checksum).

@cybermnemosyne
Copy link
Contributor

I was wondering why you don't just use scp ? I hit this error (along with another base64 alignment problem) and so switched to just using run scp followed by file_ensure

@sebastien
Copy link
Owner Author

Actually, that's a pretty good idea -- the only possible problems is that because scp will be run locally we'll have to resend the credentials (instead of using the already authenticated SSH channel used by Fabric).

@cybermnemosyne
Copy link
Contributor

It seems to work ok and also has the benefit of not spitting out a dump of the file in the output - let me know if you want me to have a go at adding the method or changing it

@sebastien
Copy link
Owner Author

Hi David, it would be great if you could contribute something! For now I'd like to keep the current file_write as default until we know that the scp method works, so I would suggest that you write a file_write_scp(...) method and I'll add an option to use file_write_scp instead of file_write (it might be possible with variants).

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