Tux

...making Linux just a little more fun!

Talkback:132/renker.html

Peter Hoeg [peter at hoeg.com]
Tue, 7 Nov 2006 11:21:52 +0300

Any particular reason for not just using a tool, which already exists - such as Unison (http://www.cis.upenn.edu/~bcpierce/unison/) which is cross platform/OS ?

/peter


Top    Back


Kapil Hari Paranjape [kapil at imsc.res.in]
Tue, 7 Nov 2006 14:04:52 +0530

Hello,

On Tue, 07 Nov 2006, Peter Hoeg wrote:

> Any particular reason for not just using a tool, which already exists
> - such as Unison (http://www.cis.upenn.edu/~bcpierce/unison/) which is
> cross platform/OS ?

I also thought of the same thing as I started reading the article.

However, you should be aware of some of the issues that "unison" has with USB drives. (see http://bugs.debian.org/349674)

Also the Perl philosophy TMTOWTDI.

Also the Fun philosophy YDKHIWTYCI.

Regards,

Kapil. --


Top    Back


Benjamin A. Okopnik [ben at linuxgazette.net]
Fri, 10 Nov 2006 01:34:19 -0500

[I've just added the author to the CC list]

On Tue, Nov 07, 2006 at 11:21:52AM +0300, Peter Hoeg wrote:

> Any particular reason for not just using a tool, which already exists
> - such as Unison (http://www.cis.upenn.edu/~bcpierce/unison/) which is
> cross platform/OS ?

I recall hearing about Unison a while back; exploring the above URL now gives me the impression that it doesn't do what the article proposes - i.e., sync between an HD and a pen drive. Instead, it appears to require two active hosts, at least according to the description at the site:

It allows two replicas of a collection of files and directories to be
stored on different hosts (or different disks on the same host),
modified separately, and then brought up to date by propagating the
changes in each replica to the other.
and further on:

Unison works between any pair of machines connected to the internet,
communicating over either a direct socket link or tunneling over an
encrypted ssh connection. It is careful with network bandwidth, and runs
well over slow links such as PPP connections. Transfers of small updates
to large files are optimized using a compression protocol similar to
rsync.
Unison's site also says:

These binaries depend on glibc 2.3.
 
The gtk2 UI binaries additionally depend on GTK+ 2.
I just downloaded the (rather large) binary and manual and have tried to compile it... oops, it also requires installing OCaml and 'etags' for compilation, and LablGtk along with GTK+ 2 if you want a GUI - and OCaml alone is 38MB. I think I'll skip all of that; experimenting with it sounds like a major pain. Given Gerrit's script - 23kB including comments, nothing to compile, using what most people already have on their systems, and cross-platform as well - your question appears to have answered itself. :)

-- 
* Ben Okopnik * Editor-in-Chief, Linux Gazette * http://LinuxGazette.NET *


Top    Back


Peter Hoeg [peter at hoeg.com]
Mon, 13 Nov 2006 12:28:17 +0300

Well, the description you mention yourself, does in fact explicitly state two disks on one host:

> It allows two replicas of a collection of files and directories to be
> stored on different hosts (or different disks on the same host),

Think of it as a tool to synchronize two locations which just happen to not have not to reside on the same host.

With regards to size requirements, then doing apt-get install unison on Debian Sarge starts a download of 454kb which is not too bad in my opinion - this obviously excludes the GUI part.

Furthermore, unison comes prepackaged for Cygwin as well in different (379kb for version 2.9.1 which matches the version available in Sarge).

No need to compile anything.

While I fully understand the author's reason(s) to do it himself, when it comes to areas such as backup and replication, I would rather go for a solution in active use by thousands, which has undergone serious testing - not to belittle Gerrit's efforts.

But hey - choice is what free software is all about anyway!

/peter


Top    Back


Gerrit Renker [grrtrr at yahoo.co.uk]
Mon, 13 Nov 2006 13:50:41 +0000 (GMT)

> While I fully understand the author's reason(s) to do it himself, when
> it comes to areas such as backup and replication, I would rather go
> for a solution in active use by thousands, which has undergone serious
> testing - not to belittle Gerrit's efforts.

Why all the talking -- write an article.

I tried unison during my functional programming days but found it complicated to use.

Gerrit


Top    Back


Benjamin A. Okopnik [ben at linuxgazette.net]
Fri, 17 Nov 2006 10:53:45 -0500

On Mon, Nov 13, 2006 at 12:28:17PM +0300, Peter Hoeg wrote:

> Well, the description you mention yourself, does in fact explicitly
> state two disks on one host:
> 
> > It allows two replicas of a collection of files and directories to be
> > stored on different hosts (or different disks on the same host),
> 
> Think of it as a tool to synchronize two locations which just happen
> to not have not to reside on the same host.

Both of the above scenarios, though, presume an "active" connection - either via a direct hardware connection (two disks on the same machine) or a network connection. That is, Unison needs to be able to update its "private structures" (as mentioned at the site) in the 'remote' copy at the time that the transfer is made. However, in the scenario described, that's not an option: the host on which the remote copy is to reside may be as yet uknown... or for that matter may not yet exist. Not something that Unison can handle - at least going by the description. This makes Gerrit's script very useful indeed, and for exactly the purpose that he stated.

> With regards to size requirements, then doing apt-get install unison
> on Debian Sarge starts a download of 454kb which is not too bad in my
> opinion - this obviously excludes the GUI part.

You're right - I'd missed that option, since the only pointer to Unison I had was the page you cited.

> While I fully understand the author's reason(s) to do it himself, when
> it comes to areas such as backup and replication, I would rather go
> for a solution in active use by thousands, which has undergone serious
> testing - not to belittle Gerrit's efforts.
> 
> But hey - choice is what free software is all about anyway!

That was my point from the start (as it usually is, in this kind of discussions.) I'm glad to see that we agree. :)

-- 
* Ben Okopnik * Editor-in-Chief, Linux Gazette * http://LinuxGazette.NET *


Top    Back


Gerrit Renker [grrtrr at yahoo.co.uk]
Mon, 20 Nov 2006 09:47:28 +0000 (GMT)

Hi Peter,

I have used unison but found it complicated to use. What you expressed below is also known as a Perl of Wisdom: "There is More Than One Way To Do It".

If you have these considerations, why don't you write an article about your proposed backup solution - it would make an interesting follow-up to the article.

And ... writing should not at all be an issue for you -- since you already have the same name as my second favourite Danish author (the first being Peter Freuchen).

So - no excuses, get those pencils sharpened ;-)

-- grrtrr


Top    Back


Peter Hoeg [peter at hoeg.com]
Mon, 20 Nov 2006 13:05:24 +0300

Gerrit,

well, I guess you know that it is a lot easier to criticize other people's work than creating your own, so I think I will stick to pointing out flaws in articles written by others instead of doing any actual work myself... ;-)

I thought the perl saying was: WTTERWYCWIAFSIP (Why Take The Easy Road When You Can Write It All From Scratch In Perl)

But I guess you are right, I probably should write something up.

Ben, does LWN only post exclusive pieces? Because if I do write something up, I would want to post it on www.debian-administration.org as well.

/peter


Top    Back


Gerrit Renker [grrtrr at yahoo.co.uk]
Mon, 20 Nov 2006 10:30:05 +0000 (GMT)

Unless you really produce something tangible your postings remain empty talk and I am not prepared to answer empty talk.


Top    Back


Benjamin A. Okopnik [ben at linuxgazette.net]
Mon, 20 Nov 2006 08:11:58 -0500

On Mon, Nov 20, 2006 at 01:05:24PM +0300, Peter Hoeg wrote:

> 
> Ben, does LWN only post exclusive pieces? Because if I do write
> something up, I would want to post it on www.debian-administration.org
> as well.

I have no idea about LWN policy, actually; the number you have dialed is L-i-n-u-x-G-a-z-e-t-t-e-dot-N-E-T. :) Everything we publish, as the license link on our front page says, is released under OPL 1.0 (options A and B not applied.) Since the copyright, of course, remains with you, you can republish it anywhere you'd like - we don't even have (or want) a say in that.

I'm going to send you our New Author Guide in a separate email, and am definitely looking forward to seeing an article on an easy way to use Unison. :)

-- 
* Ben Okopnik * Editor-in-Chief, Linux Gazette * http://LinuxGazette.NET *


Top    Back


Peter Hoeg [peter at hoeg.com]
Tue, 21 Nov 2006 11:24:42 +0300

On 20/11/06, Benjamin A. Okopnik <ben@linuxgazette.net> wrote:

> On Mon, Nov 20, 2006 at 01:05:24PM +0300, Peter Hoeg wrote:
> >
> > Ben, does LWN only post exclusive pieces? Because if I do write
> > something up, I would want to post it on www.debian-administration.org
> > as well.
>
> I have no idea about LWN policy, actually; the number you have dialed is
> L-i-n-u-x-G-a-z-e-t-t-e-dot-N-E-T. :) Everything we publish, as the
> license link on our front page says, is released under OPL 1.0 (options
> A and B not applied.) Since the copyright, of course, remains with you,
> you can republish it anywhere you'd like - we don't even have (or want)
> a say in that.
>
> I'm going to send you our New Author Guide in a separate email, and am
> definitely looking forward to seeing an article on an easy way to use
> Unison. :)

You know, I have heard people in the past suggesting that I should switch my brain on before I start writing mails and now I finally see what they were on about... ;-)

I naturally meant LG and not LWN - and I got your guide, thanks!

/peter


Top    Back


Bob McConnell [rvm at CBORD.com]
Tue, 14 Nov 2006 10:54:10 -0500

The idea of using a USB drive to move files between systems is not new, but was a big improvement over CD-R transfer. Your idea of automating the sync function is another significant step up. However, is there any way to extend this to other systems?

At work I have MS-W2KPro on my workstation (w/Cygwin and ActiveState Perl), while my development targets are an eclectic mix of MS-Windows, FC5, RHEL-AS4, Xinu, FreeBSD and a couple of proprietary kernels. At home I use Slackware for servers and workstations. I do have VNC/SSH access between the home systems and the workstation, but TightVNC doesn't appear to support file transfers between MS-Windows and Linux. How difficult will it be to modify this package to at least synchronize files between the workstation and Slackware?

Note that while I do know some basic Perl, I do not do abstraction well. I am most fluent in assembler and C since most of my work for the past 25 years has been for embedded targets.

Thank you,

-- 
Bob McConnell
Principal Communications Programmer
The CBORD Group, Inc.
61 Brown Road
Ithaca NY, 14850
Phone 607 257-2410
FAX 607 257-1902
Email rvm@cbord.com


Top    Back


Benjamin A. Okopnik [ben at linuxgazette.net]
Fri, 17 Nov 2006 11:11:41 -0500

On Tue, Nov 14, 2006 at 10:54:10AM -0500, Bob McConnell wrote:

> The idea of using a USB drive to move files between systems is not new,
> but was a big improvement over CD-R transfer. Your idea of automating
> the sync function is another significant step up. However, is there any
> way to extend this to other systems?
> 
> At work I have MS-W2KPro on my workstation (w/Cygwin and ActiveState
> Perl), while my development targets are an eclectic mix of MS-Windows,
> FC5, RHEL-AS4, Xinu, FreeBSD and a couple of proprietary kernels. At
> home I use Slackware for servers and workstations. I do have VNC/SSH
> access between the home systems and the workstation, but TightVNC
> doesn't appear to support file transfers between MS-Windows and Linux.

Have you thought about using 'scp' and its Windows equivalent, 'pscp'? They both work well, in my experience.

> How difficult will it be to modify this package to at least synchronize
> files between the workstation and Slackware?

Even without examining the script in microscopic detail, a reasonably obvious solution would be to format your memory stick as VFAT, as Gerrit did, thus making it accessible from both Linux and Wind0ws.

> Note that while I do know some basic Perl, I do not do abstraction well.
> I am most fluent in assembler and C since most of my work for the past
> 25 years has been for embedded targets.

Sounds like a very interesting field. Have you considered writing an article for us? I'm sure that many of our readers would be fascinated to learn about it.

-- 
* Ben Okopnik * Editor-in-Chief, Linux Gazette * http://LinuxGazette.NET *


Top    Back