Not sure if i'm just being silly here or what.
I'm experimenting with casync
, trying to extract over HTTP a caidx
which is basically an Ubuntu server image. Both the server and the client are running Ubuntu 16.04 (Xenial), with casync
built from master
(this commit, specifically). The server is offering the files via HTTP using a pretty much out-of-the-box nginx set-up.
File system on server:
% ls -Al /srv/casync
total 4124
-rw-r--r-- 1 root root 1237504 Nov 27 23:43 fw.caidx
-rw-r--r-- 1 root root 1196024 Nov 27 23:39 fw2.caidx
-rw-r--r-- 1 root root 1240224 Nov 27 23:52 fw3.caidx
drwxr-xr-x 29324 root root 540672 Nov 27 23:52 default.castr/
I have a similar image already on my client's disk, so i'm trying to seed with that. When i do so, i find that i very consistently get a 'broken pipe' error, seemingly indicating that casync
is failing to retrieve the full index file. Here's what it looks like:
Commands run on client:
% sudo mkdir /data/fw
% {
> date
> sudo casync -v --seed=/data/myfw extract http://172.17.1.213/fw.caidx /data/fw
> date
> } 2>&1 | tee casync.log
Output on client:
Tue 28 Nov 00:57:15 CST 2017
Acquiring http://172.17.1.213/fw.caidx...
Seeding ./
Seeded ./
Seeding ./
Seeding bin
...
Seeded var/www
Seeded var
Seeding vmlinuz
Seeded vmlinuz
Seeded ./
Failed to acquire http://172.17.1.213/fw.caidx
Failed to run synchronizer: Broken pipe
Tue 28 Nov 01:00:08 CST 2017
Web-server logs on server:
172.17.66.1 - - [28/Nov/2017:00:58:15 -0600] "GET /fw.caidx HTTP/1.1" 200 493499 "-" "-"
Note that 493499
is not the full size of fw.caidx
. (Note also that the error is not actually returned until it finishes the seeding process almost 2 minutes later — that's kind of bothersome.)
I keep running this over and over and keep getting similar results — casync
only ever gets between maybe 400 and 700 kB of the index file, and then it gives that broken-pipe error. If i retrieve the index file with curl
it works fine, i get the full size shown in the log and it matches on the client.
I thought i would try the same thing but without the seeding bit, and it does seem to get further (in that i have a bunch of files extracted on the client), but now i get a different error:
Commands run on client:
% sudo mkdir /data/fw
% {
> date
> sudo casync -v extract http://172.17.1.213/fw.caidx /data/fw
> date
> } 2>&1 | tee casync.log
Output on client:
Tue 28 Nov 01:06:43 CST 2017
Acquiring http://172.17.1.213/fw.caidx...
Seeding ./
Seeded ./
Acquiring http://172.17.1.213/default.castr/7634/7634a8d3b747c84fa60c779497e95793a346603553af87b208e2abe0a59b620d.cacnk...
Acquiring http://172.17.1.213/default.castr/25fa/25fa6d80a0f122d8f0473dda8bf9a8d8703a875107e299b6f84730e11020928d.cacnk...
Acquiring http://172.17.1.213/default.castr/fd27/fd2741d59d832c5e81afd57122d0c648a5189cd3775d3df321fb6fcff243e37e.cacnk...
Extracting ./
Using feature flags: 32bit-uids user-names nsec-time symlinks device-nodes fifos sockets flag-hidden flag-system flag-archive flag-append flag-noatime flag-compr flag-nocow flag-dirsync flag-immutable flag-sync flag-nocomp flag-projinherit flag-subvolume flag-subvolume-ro xattrs acl selinux fcaps
Excluding files with chattr(1) -d flag: yes
Excluding submounts: no
Digest algorithm: sha512-256
...
Extracting etc/depmod.d/ubuntu.conf
Extracted etc/depmod.d/ubuntu.conf
Extracted etc/depmod.d
Extracting etc/dhcp
Extracting etc/dhcp/ddns-keys
Extracted etc/dhcp/ddns-keys
Failed to run synchronizer: No such process
Tue 28 Nov 01:06:52 CST 2017
The Web-server logs show something like 1000 chunks being fetched. I spot-checked the last few and they all seem to have returned the correct size, so it's not that. I guess don't know what the 'process' it's referring to is.
Any ideas as to how i could troubleshoot further? Thanks!