Slashdot Mirror


Apple's "Time Machine" Now For Linux... Sort Of

deander2 writes "Apple's 'Time Machine' is cool, but I use Linux, not MacOSX. So here is a Linux implementation (built off of rsync, of course). No fancy OpenGL, but quite functional none-the-less."

20 of 425 comments (clear)

  1. No Open Source Invovation here! by jellomizer · · Score: 3, Informative

    I hate to sound like a fanboy but...
    Apple did spend many months working on the interface and desing to try to make backups as
    easy as possible... All the time they took was really in design time... A much smaller portion
    was used in actually coding.... (Find files that have been altered from last update -> Copy Said files
    to alternate drive in directory with the date as a name, make note of files that have deleted)

    To Restore data go to the date of backup when data existed merge with previous dates and account for
    deleted files.

    Once selected copy files back to origional drive...

    It really isn't a complex process... And I am not supprised that someone made it for Linux
    within a couple of weeks of Leopard being public...

    Apple did all the design work which was actually the hardest part the programming isn't that hard.
    I would be careful for patent issues though... Apple is a big pattenter... (Espctially after
    Microsoft stole their interface)

    --
    If something is so important that you feel the need to post it on the internet... It probably isn't that important.
    1. Re:No Open Source Invovation here! by ickoonite · · Score: 5, Informative

      (Find files that have been altered from last update -> Copy Said files to alternate drive in directory with the date as a name, make note of files that have deleted)

      Trivialising the technical underpinnings of Time Machine is unwise, and plays right into the hands of those who say Apple is all about show and lacks substance. In fact, the way Time Machine knows what files have been modified is really quite elegant and shouldn't be underplayed. I shan't go into the details of it all here, but if you are interested, see the relevant page of John Siracusa's excellent review of 10.5 over at Ars Technica.

      In the meantime, you might like to consider learning how to spell.

      :|

  2. Ubuntu TimeVault by phoebe · · Score: 5, Informative

    There's already been work on a Linux Time Machine, just not ready for prime time yet: TimeVault.

    1. Re:Ubuntu TimeVault by DragonWriter · · Score: 3, Informative

      BTW, except of Mark's past, why do they serve almost everything over HTTPS?


      Just curious, is there any really good reason not to serve everything over HTTPS?
  3. Yeah, makes me wonder ... by dazedNconfuzed · · Score: 4, Informative

    I just drag my important files onto an external drive.

    The whole point is that you don't have to do that, it happens automatically.
    AND it catches all the files that you didn't think were important, but are.
    AND it lets you roll the system back to the state it was in at any given time in the past (hence "time machine").
    AND it takes care of any problems that can happen during backup (like "disk full", "power failure", etc.).

    --
    Can we get a "-1 Wrong" moderation option?
  4. Re:Completely misses the point by santiago · · Score: 4, Informative

    What Leopard also did was add file system support for hard links to directories, so that backups from different points in time could be easily presented as complete volume images without any need for a special backup file format, yet still share storage for unchanged files.

  5. Re:Why not a simple SCCS? by ajayrockrock · · Score: 3, Informative

    What I'd like to see is a very simple source code control system, built on the same design. Perhaps one that would just serve the needs of a single programmer.


    How about mounting a webdav file system with a subversion backend that has autoversioning turned on? That way, every time you write to the filesystem, SVN will make a new version. I did this for an office file server and installed track to point to the same repository. So now people have a cheap web interface to view revisions of documents.

    http://svnbook.red-bean.com/en/1.2/svn.webdav.autoversioning.html

    All the Mac's in the office mount the webdav repo, my linux box mounts it via fuse, and even windows has "web folders". It was kind of a fun project that turned out to be pretty useful.

    --Ajay
  6. Re:Not the interface by MouseR · · Score: 4, Informative

    Yeah. There's more to Time Machine than just a one-off backup of your data. TM aggregates changes and you can roll back to any point in time.

    Think of it as CVS. It tages backup times but actually only copies new data as it's checked in.

    Also, TM is not confined to the Finder per say. if you're in Address Book and lost a contact, type in the filter string to locate it. Still can't find it? Right there from Address Book, hit Time Machine and Address Book will be served with backed-up address book data, filtering on the fly, as you go back in time until you find what you've been looking for.

    Same thing for anything spotlight-able.

    So, yeah, it's got a pretty interface, but TM goes way beyon just file/backup management.

  7. Re:Not the interface by slashflood · · Score: 4, Informative

    It uses hard-links, including hard-links to directories, so in each and every time-stamped folder on the backup drive, you have a *FULL* copy of your HDD at that time (minus anything you excluded from the backups
    This is exactly how BackupPC works! The interface isn't as fancy as Time Machine (because it's web based), but even the workflow is the same. It is fully automated and you don't have to touch anything. As soon as your notebook is connected to the BackupPC server, it starts to make an incremental backup. The restore is as simple as selecting the date, the directory and clicking on a button.
  8. Rsnapshot by Urban+Garlic · · Score: 3, Informative

    When I first heard about "time machine", my first thought was that consumer-grade commercial software had finally discovered rsnapshot. It's packaged for Debian, and available in "sarge" -- that makes it at least three years old.

    Rsnapshot is an rsync-and-hard-links based scheme that also doesn't store duplicate data, and provides nice date-indexed browseable full file trees, much like the way both "time machine" and this flyback gizmo are described.

    I haven't been this excited since AOL re-invented "ytalk"...

    --
    2*3*3*3*3*11*251
    1. Re:Rsnapshot by phoebusQ · · Score: 5, Informative

      Except rsnapshot uses rsync, which must rescan the filesystem. With Time Machine, the FSEvents daemon makes that unnecessary in the common case. Also, Time Machine uses hard links to directories.

  9. Re:Question by DHalcyon · · Score: 4, Informative

    The tiny difference here is that apples FSEvents is basically a daemon following the fsevents device (OS X equivalent of inotify) all the time keeping a log (directory level, as to not bog everything up with a lot of small changes), so the backup app does not have to run in the background all the time. It also notices when the disk changed while not mounted in OS X (In which case it only tells you _that_ the disk changed, I believe. You still have to figure out what changed, exactly yourself).

  10. Re:Why not a simple SCCS? by pa-ching · · Score: 3, Informative

    Most of your requirements could easily be covered by git (or perhaps another DVCS). It takes very little disk space; doesn't store diffs; has great version control, file integrity checking, and backups; repos are self-contained and easily moved from computer to computer.

    For coding use-cases or the one you mentioned--writable working tree and read-only history--it's perfect. However, there are design tradeoffs in git that may not make it *completely* suitable. Its handling of large binary files is probably a little slow. You could probably lower the zlib compression to get that working faster.

    As for filesystem integration, Resier4's plugin system or something similar is suitable for the job. Unfortunately, reiser4's future is uncertain...

  11. Re:Question by krog · · Score: 5, Informative

    Unless you can produce a link or some debugger output or something, I'm gonna go ahead and trust ArsTechnica more than I trust you.

  12. Re:FS with snapshotting by krog · · Score: 3, Informative

    Sadly, ZFS did not quite make it into 10.5 (ZFS read support is there, read/write support is experimental and present only in developer versions).

  13. Introducing ext3cow! Time-Machine for Linux by SpzToid · · Score: 4, Informative

    from the website:
    http://www.ext3cow.com/

    Ext3cow is an open-source, versioning file system based on ext3. It provides a time-shifting interface that allows a real-time and continuous view of the past. This allows users to access their file system as it appeared at any point in time.

    Ext3cow was designed as a platform for regulatory compliance, and has been used to implement secure deletion, authenticated encryption, and incremental authentication. See the publications page for more details.

    Some advantages of ext3cow:

          1.
                  It does not pollute the name space with named versions
          2.
                  It has low storage and performance overhead
          3.
                  It is totally modular, requiring no changes to kernel or VFS interfaces

    --
    You can't be ahead of the curve, if you're stuck in a loop.
  14. Re:Not the interface by Anonymous Coward · · Score: 5, Informative
    Too long have I sat by and watched a great phrase be abused:

    ...Also, TM is not confined to the Finder per say. if you're in Address Book and lost a contact, type in the filter string to locate it. Still... It's PER SE, goddamnit! And it means "intrinsically!" You saying "TM is not confined to the Finder per se" would imply that either it IS somehow confined to finder (but not intrinsically) or you just like to use big-person words you don't understand. Please! Think about what you're saying!
  15. Re:Not the interface by BobPaul · · Score: 3, Informative

    The interface is the goofy 3d zooming through space view. The ease of use and he's referring to is that the incremental backups that are stored all appear like full backups from a file system perspective.

    One can set it up once with the goofy 3d zooming thingy and then it'll happen automatically in the background. Need a file that you know was good a week ago? In term, type "cp /mnt/backup/11-01-07/path/to/file/file ~/" etc. Or browse to it in the finder. Or use the goofy 3d zooming thingy.

    Most backup solutions require you use their software to restore from backup. If I interpreted the parent right, Leopard doesn't.

  16. Re:Time Machine has been around for a while... by Pausanias · · Score: 4, Informative

    That's not true. Read the link I posted above. rsync can create hard links, through the magical --link-dest option. This means that you never need to do full backups, or worry about keeping track of several versions.

    You can set up rsync to do hourly, daily, weekly, and monthly backups, all taking up minimal (and I mean minimal) disk space, using hard links.

    All you have to do is rm -rf your oldest directory of each kind (hourly daily, weekly, monthly) every time you run.

    Heck, I'll even give you the BASH script I use to do this. Call it via cron: e.g. snapshot daily

    #!/bin/bash
    # This script makes a snapshot of several directories using rsync.

    # Version 0.5, Rob Bos, September 8, 2002
    # Modified by Pausanias August 2004
    # This script is released under the terms of the
    # GNU General Public License, version 2.0.

    # run "hourly" from a crontab; run daily, weekly, and monthly from /etc/cron.{daily,weekly,monthly}/.

    [ -z "$1" ] && echo syntax: $0 snapshottype baselinesnapshottype && exit 1

    type=$1 # hourly, daily, monthly snapshot?
    logfile=/var/log/snapshot.log
    backuproot=/Volumes/Sutton/ibackup
    backup=`cat /etc/snapshot/include.txt`
    excludefile=/etc/snapshot/exclude.txt

    echo `date` >> $logfile

    [ ! -e "$backuproot" ] && echo "$backuproot not mounted." >> $logfile && exit 1

    # Assume that the baseline snapshot type is daily unless otherwise
    # specified.
    if [ "f$2" == "f" ]; then
    basetype="daily"
    else
    basetype="$2"
    fi

    # if you run every two hours, make it 12, every hour, 24, etc. try to span the entire day.
    # The below setting runs 8 times a day (every three hours), keeps 7 days, 4 weeks, and 12 months
    # of backup.

    hourlymax=8
    dailymax=10
    weeklymax=5
    monthlymax=8

    # This simplifies things down below so I can use $max to delete
    # the overrotated snapshot, as well as $hourlymax/$dailymax to do
    # rotation checks.
    [ $type == "hourly" ] && max=hourlymax
    [ $type == "daily" ] && max=dailymax
    [ $type == "weekly" ] && max=weeklymax
    [ $type == "monthly" ] && max=monthlymax

    # Rotate the current list of backups, if we can.
    if [ -d $backuproot/$type.1 ]; then
    oldest=`ls -dt $backuproot/$type.* | tail -n 1 | sed 's/^.*\.//'`
    echo Oldest is $type.$oldest >> $logfile 2>&1
    for i in `/usr/local/bin/seq $oldest 1 -1`; do
    mv $backuproot/$type.$i $backuproot/$type.$(( i + 1 ))
    done
    linkopt="--link-dest=$backuproot/$type.2"
    else
    linkopt=""
    fi

    if [ "$type" == "$basetype" ]; then
    rsync -xva $linkopt --safe-links --delete --delete-excluded --exclude-from=$excludefile $backup $backuproot/$type.1/ >> $logfile 2>&1
    elif [ "$type" == "daily" ]; then
    [ -d $backuproot/hourly.$hourlymax ] && mv $backuproot/hourly.$hourlymax $backuproot/daily.1
    elif [ "$type" == "weekly" ]; then
    [ -d $backuproot/daily.$dailymax ] && mv $backuproot/daily.$dailymax $backuproot/weekly.1
    elif [ "$type" == "monthly" ]; then
    [ -d $backuproot/weekly.$weeklymax ] && mv $backuproot/weekly.$weeklymax $backuproot/monthly.1
    fi /usr/bin/awk 'substr($0,length($0),

  17. Re:Not the interface by TheNetAvenger · · Score: 3, Informative

    Time Machine's ability to simply browse backwards through time in the folder, whilst still having the folder functionality usable is far beyond BackupPC.

    I agree it is not just Backup software.

    However, this is ALSO why 'previous versions' in Vista is more than a snapshot/backup interface as well. In Vista you can view folders as they exist at any previous time and even drag and drop the folder or files you want from the folder at a specific time in history.

    Time Machine = 3D Interface of Files/Folders
    Vista = Timeline List of Files/Folders

    Time Machine = Uncompressed Backups to External Drive
    Vista = Compressed Backups ANYWHERE + File Version Snapshots on main Hard Drive + Works on Servers and across networks (ie Can use Previous Versions on Folders/Files you have access to on Servers or other computers, and it displays that folder's snapshots and backups.)

    Time Machine = Great Marketing
    Vista = MS's Sucky Marketing

    So Time Machine gets the cool buzz, when Vista is the cooler of the two technologies...