maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   cloudsync.sh, replacement to DropBox and whatever you have (https://talk.maemo.org/showthread.php?t=89875)

juiceme 2013-04-28 18:45

Re: cloudsync.sh, replacement to DropBox and whatever you have
 
Quote:

Originally Posted by knobtviker (Post 1339392)
Just a question:
When you update an existing file, do you upload/download a whole file or just the part of the file that changed?

Well, that's up to the implementation of rsync on the platform.

As far as I know (and now checking from wikipedia confirms this) the linux rsync divides all files into fixed size blocks and only transmits the differing blocks based on checksumming algorithm. (source: http://en.wikipedia.org/wiki/Rsync, see the section "Determining which parts of a file have changed")

A short test of my own; I transferred a binary file of about 9MB with cloudsync.sh, then hexedited it so that I changed just one byte somewhere about middle of the file, and resent it.

Code:

Apr 29 08:25:50 (2013) cloudsync: Triggered upload from filesystem
Apr 29 08:25:50 (2013) cloudsync: Using WLAN connection to server
Apr 29 08:26:02 (2013) cloudsync: sending incremental file list ./ rsync-muutostesti  sent 9176267 bytes  received 34 bytes  734104.08 bytes/sec total size is 9175040  speedup is 1.00
Apr 29 08:26:02 (2013) cloudsync: Upload tranfer succeeded
Apr 29 08:26:54 (2013) cloudsync: Triggered upload from filesystem
Apr 29 08:26:54 (2013) cloudsync: Using WLAN connection to server
Apr 29 08:27:01 (2013) cloudsync: sending incremental file list ./ rsync-muutostesti  sent 15267 bytes  received 18244 bytes  5155.54 bytes/sec total size is 9175040  speedup is 273.79
Apr 29 08:27:01 (2013) cloudsync: Upload tranfer succeeded

From this simple test you can see that on the second serving, only 15kB needed to be sent to transfer the changes to the file. (and most of this is transferring the MD5 hashes of the file blocks I guess, plus the changed block when it is detected...)

The "speedup is 273.79" means that the filesize/(sent_bytes+received_bytes) = 273.79, so only 2.7% of the total file size needed to be sent on the second round.

N9uwu 2013-07-13 12:43

Re: cloudsync.sh, replacement to DropBox and whatever you have
 
First of all, thanks for the script. After using it for some time I wanted to have easy access to the log, as well as a way of knowing when a sync is done. This is how I do it:

1) Redirect all output/logging to a log file (.txt extension)
2) After removing the lock file, open the txt-file via xdg-open (launches the document viewer)

Code:

G_LOGFILE="/home/user/logs/cloudsync.txt"

echo "logger text and output.." >> $G_LOGFILE

# after removing the lock file
xdg-open /home/user/logs/cloudsync.txt


xman 2018-11-27 05:12

Re: cloudsync.sh, replacement to DropBox and whatever you have
 
Would this still work? I'm thinking about dropping the owncloud cli-tool and use this. Since currently owncloud is holding me back from using newer vers of nextcloud on the desktop.

x

juiceme 2018-11-27 09:51

Re: cloudsync.sh, replacement to DropBox and whatever you have
 
Quote:

Originally Posted by xman (Post 1551163)
Would this still work? I'm thinking about dropping the owncloud cli-tool and use this. Since currently owncloud is holding me back from using newer vers of nextcloud on the desktop

Yes, as cloudsync uses basic shell tools it works pretty much on anything you could want to try it on.

xman 2018-11-28 01:42

Re: cloudsync.sh, replacement to DropBox and whatever you have
 
Okay I might need your assistance once I get around to trying this. Since I'm hoping to have it sync in both ways. which I know you didn't want for your use.

Would be amazing if I could get this going reliably. Since I then can still sync my caldav & cardiac with the newer nextcloud and then all is well again.

x


All times are GMT. The time now is 22:01.

vBulletin® Version 3.8.8