DanielBarker
Posts: 72
Joined: Tue May 29, 2012 7:53 am

Versioning file system?

Sun Dec 15, 2013 1:01 pm

I miss the automatic file versioning of VMS, which I used briefly long ago.

According to Wikipedia, there are a few projects for Linux (http://en.wikipedia.org/wiki/Versioning_file_system) - but maybe rather experimental, and certainly not yet mainstream.

The Pi seems a good place to experiment. I can set up a specific SD card for messing around and it doesn't matter if it goes wrong.

Does anyone have any recommendations for, or experience of, using a versioning file system under Rasbpian?

(I don't mean version-control systems or timed snapshots. I mean a file system that automatically keeps old versions of files available for the user, whenever the files are changed.)

Thank you,

Daniel Barker

MattF
Posts: 55
Joined: Tue Feb 12, 2013 10:01 am

Re: Versioning file system?

Mon Dec 16, 2013 12:27 am

Well NILFS has been mainstream for some time. That would be my starting point.

Given the nature of SD cards I'd be cautious about introducing the amount of additional writes such a thing would (in my simple brain) entail.

Perhaps an aufs/unionfs/... approach would be better? Depends on requirement of course.

User avatar
duberry
Posts: 379
Joined: Mon Jan 28, 2013 10:44 pm
Location: standing on a planet that's evolving. And revolving at nine hundred miles an hour

Re: Versioning file system?

Mon Dec 16, 2013 9:35 am

DanielBarker wrote:Does anyone have any recommendations for, or experience of, using a versioning file system under Rasbpian?

(I don't mean version-control systems or timed snapshots. I mean a file system that automatically keeps old versions of files available for the user, whenever the files are changed.)
Hi i don't have any recommendations or experience of vfs , in fact you post is the first iv heard of it ! but i do like the sound of it

However you saying you don't mean version-control made me think about then look for "git + fuse"
And it appears something called git-fs is out there https://github.com/g2p/git-fs
lend me your arms, fast as thunderbolts, for a pillow on my journey.
If the environment was a bank, would it be too big to fail
so long; and thanks for all the pi

User avatar
joan
Posts: 14475
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Versioning file system?

Mon Dec 16, 2013 9:42 am

VMS was pretty noddy. It just made an endless stream of backup copies. It didn't even diff them as far as I know.

If you typically use the same editor you could do something better with a script and RCS.

User avatar
rurwin
Forum Moderator
Forum Moderator
Posts: 4258
Joined: Mon Jan 09, 2012 3:16 pm
Contact: Website

Re: Versioning file system?

Mon Dec 16, 2013 10:36 am

It shouldn't entail any extra writes to the SD card. In fact it requires slightly fewer. The standard procedure when an editor changes a file is to save it under a temporary name, delete the original and then rename the new file to the original name. That ensures that if something goes wrong at any point, the file is not lost. In the case of a simple VFS, you would do the same except for the final delete and rename.

User avatar
duberry
Posts: 379
Joined: Mon Jan 28, 2013 10:44 pm
Location: standing on a planet that's evolving. And revolving at nine hundred miles an hour

Re: Versioning file system?

Fri Jan 17, 2014 10:20 am

fyi
I did a bit more digging around the vfs theme
@ projects using fuse

There is a VersioningFileSystems subsection , could be useful ?*

*I have as yet not used any
lend me your arms, fast as thunderbolts, for a pillow on my journey.
If the environment was a bank, would it be too big to fail
so long; and thanks for all the pi

Heater
Posts: 13926
Joined: Tue Jul 17, 2012 3:02 pm

Re: Versioning file system?

Fri Jan 17, 2014 11:23 am

What do you want to keep multiple versions of? And why?

Certainly for writing code a proper source code management system is a much better idea.

I can't live without git and github any more.
Memory in C++ is a leaky abstraction .

User avatar
duberry
Posts: 379
Joined: Mon Jan 28, 2013 10:44 pm
Location: standing on a planet that's evolving. And revolving at nine hundred miles an hour

Re: Versioning file system?

Fri Jan 17, 2014 11:49 am

Heater wrote:What do you want to keep multiple versions of? And why?
Personally i like the idea of tracking a document as it progress's

eg with ether pad you can 'play back' edit by edit from the a blank page to current document

IDK if its a good example but
I remember being asked to "show my working" on math problems
presumably to show the steps taken / thought process of working through the problem ?

Perhaps vfs can provide a similar facility ..
lend me your arms, fast as thunderbolts, for a pillow on my journey.
If the environment was a bank, would it be too big to fail
so long; and thanks for all the pi

Heater
Posts: 13926
Joined: Tue Jul 17, 2012 3:02 pm

Re: Versioning file system?

Fri Jan 17, 2014 12:56 pm

A versioning FS is nice in the situation that you accidentally mangle a file and just want to throw it away and get back the last good version.

An editor that can undo back to square one also alleviates this issue.

But when it comes to that "show your working" problem things get more complicated. Having a bunch of old versions does not help with that traceability. You are not going to remember all the changes in all those versions, you are going to have to use diff and such tools to find out.

That is why we have source code management systems. They can keep all your versions, along with version numbers or meaning full tags you have applied. They keep those little log messages that you give them that describe why the file was changed. They make it easy to see difference between versions. They make it easy to revert to any past version. You can even have multiple versions going on at the same time by branching. And importantly they make it very easy to keep a backup master repository of your work, or in the case of git multiple master repositories.

All in all if you use something like git, mercurial or subversion you won't feel the need for a versioning files system and you work will be far better organized anyway.
Memory in C++ is a leaky abstraction .

Joe Schmoe
Posts: 4277
Joined: Sun Jan 15, 2012 1:11 pm

Re: Versioning file system?

Fri Jan 17, 2014 1:37 pm

All in all if you use something like git, mercurial or subversion you won't feel the need for a versioning files system and you work will be far better organized anyway.
See .sig
And some folks need to stop being fanboys and see the forest behind the trees.

(One of the best lines I've seen on this board lately)

User avatar
duberry
Posts: 379
Joined: Mon Jan 28, 2013 10:44 pm
Location: standing on a planet that's evolving. And revolving at nine hundred miles an hour

Re: Versioning file system?

Fri Jan 17, 2014 1:48 pm

while i understand version control was created because it was needed , and it works well

I may be wrong but doubt any one need's /want's to see/work on my "code" :lol:
And while i could use something like git ect to track my progress or not as the case may be
For whatever im mucking about with
Its an extra step in the "think ,type ,test" 'work flow'

Some kind of vfs or similar could let me or any one else who wanted to continue mindlessly bashing the key's ect

With out any extra step ( other than setting up whatever to keep progress log )

Granted ether pad is no file-system but it has got continuous edit tracking (i think in the form of "Operation Transformation" algo )

*eg : http://beta.etherpad.org/test-ep/timeslider#0 (just press play )

*note the beta is not working in at least one old/ageing browser .

@Joe Schmoe lol

Heater
Posts: 13926
Joined: Tue Jul 17, 2012 3:02 pm

Re: Versioning file system?

Fri Jan 17, 2014 3:25 pm

duberry,
... may be wrong but doubt any one need's /want's to see/work on my "code"
Same here most of the time.

But what I found is that git, for example, is so easy to use it protects me from myself!

Gone are days of having a dozen versions of files or projects hanging around and then forgetting which one worked last or which one had what feature or the other.

I programming project does not have to get very big before these things pay off.

Joe Schmoe,
See .sig
Check :)
Memory in C++ is a leaky abstraction .

User avatar
DougieLawson
Posts: 36578
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Versioning file system?

Fri Jan 17, 2014 10:44 pm

Heater wrote: All in all if you use something like git, mercurial or subversion you won't feel the need for a versioning files system and you work will be far better organized anyway.
I run gitolite. Having a git repo that's resident on my NAS box has saved me when I wrote a nasty bug into my perl code.

Easy to install, easy to use and all the versions are safely stored until you deliberately purge them.

I'm even running gitweb on my Apache server.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

Return to “Raspbian”