Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 2 Feb 2009 13:23:21 -0600
From:      Dan Nelson <dnelson@allantgroup.com>
To:        Wayne <testcat2003@yahoo.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: ls -lh show file not displaying correct size
Message-ID:  <20090202192320.GK75802@dan.emsphone.com>
In-Reply-To: <832987.51059.qm@web33107.mail.mud.yahoo.com>
References:  <20090131213315.GE75802@dan.emsphone.com> <832987.51059.qm@web33107.mail.mud.yahoo.com>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
In the last episode (Feb 02), Wayne said:
> Thanks for the answer so now for the next question. How do I sync this
> file to other FreeBSD servers. I tried using rsync with the --spares
> but the size on the other server was on it's way to being the 256G size
> and fill up the other server. How would I go about making an exact
> duplicate. 

rsync --sparse seems to work fine for me:

(dan@dan.13) /usr/tmp> truncate -s 512M bigfile1
(dan@dan.13) /usr/tmp> ls -lsk bigfile*
1 -rw-r--r--  1 dan  wheel  5368709120 Feb  2 13:09 bigfile1
(dan@dan.13) /usr/tmp> rsync --sparse -v bigfile1 dan:/usr/tmp/bigfile2
sent 536936517 bytes  received 31 bytes  2958328.09 bytes/sec
total size is 536870912  speedup is 1.00
rsync: U:98.46s S:16.08s E:181.03s CPU:63% Faults:0/1343 I/O:0/0 Swaps:0
(dan@dan.13) /usr/tmp> ls -lsk bigfile*
1 -rw-r--r--  1 dan  wheel  536870912 Feb  2 13:11 bigfile1
1 -rw-r--r--  1 dan  wheel  536870912 Feb  2 13:14 bigfile2
 
-- 
	Dan Nelson
	dnelson@allantgroup.com



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?20090202192320.GK75802>