Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×
Security The Internet

Remote Backup of Windows Boxes w/o Samba? 100

reezle asks: "I'm looking for a good (free as in beer) method to have my Debian server back up some remote Windows machines. There is no Samba in the mix; this is supposed to be a strictly secure internet thing. I've been toying with OpenSSH on the windows computers as a good tunnel, thought of simple tools like ntbackup initiated from a script on the Linux box, but not all of the pieces have come together yet. I need to have the Linux box make the connection, back up data (full and incremental backups) and have that backup data get back to the Linux machine in an encrypted format (across the wild internet). Has anyone done something like this?"
This discussion has been archived. No new comments can be posted.

Remote Backup of Windows Boxes w/o Samba?

Comments Filter:
  • Idea, (Score:4, Interesting)

    by MoOsEb0y ( 2177 ) on Wednesday August 04, 2004 @08:27PM (#9884868)
    Install an SSH Server on the windows machine, use SHFS [sf.net] to mount the remote filesystem to a directory, then use rsync to copy it.
  • Three letters: SCP. (Score:5, Interesting)

    by GregChant ( 305127 ) on Wednesday August 04, 2004 @08:27PM (#9884869)
    Your best bet, in a cheap and dirty solution, is to use SCP. Set up a cron job to securely copy the files you need. No muss, no fuss, no samba, and all encrypted.
  • cron+scp (Score:2, Interesting)

    by Cranx ( 456394 ) on Wednesday August 04, 2004 @08:27PM (#9884870)
    Have cron create a .tgz backup regularly, and download it through scp on your Windows machine.
  • Why not samba? (Score:1, Interesting)

    by Anonymous Coward on Wednesday August 04, 2004 @08:31PM (#9884897)
    Can't you set up a vpn between the two pc's with OpenVPN, and use samba over the VPN?
  • Backup (Score:4, Interesting)

    by m0rph3us0 ( 549631 ) on Wednesday August 04, 2004 @08:37PM (#9884940)
    Use the windows backup program to have windows make the backups then have Windows copy them to the debian box via scp.

    Or.... put Samba on the Debian box, use port forwarding and the loopback adapter to create a tunnel to the samba box and have the windows backup program write to the samba share which is only listens on 127.0.1.1

    setup on windows box:
    Loopback IP: 172.168.254.1
    Real IP: XX.XX.XX.XX
    SSH port forward from Local 172.168.254.1:139 to remote 127.0.0.1:139

    Create an account for each machine on the debian box.

    Windows backs up to \\172.168.254.1\MACHINENAME
  • by namtro ( 22488 ) on Wednesday August 04, 2004 @08:41PM (#9884960)

    I've had fairly good experiences with the Unison [upenn.edu] product. It works similarly to rsync [anu.edu.au] but with a few enhanced features. And I quote...

    • Unison runs on both Windows (95, 98, NT, and 2k) and Unix (Solaris, Linux, etc.) systems. Moreover, Unison works across platforms, allowing you to synchronize a Windows laptop with a Unix server, for example.
    • Unlike a distributed filesystem, Unison is a user-level program: there is no need to hack (or own!) the kernel, or to have superuser privileges on either host.
    • Unlike simple mirroring or backup utilities, Unison can deal with updates to both replicas of a distributed directory structure. Updates that do not conflict are propagated automatically. Conflicting updates are detected and displayed.
    • Unison works between any pair of machines connected to the internet, communicating over either a direct socket link or tunneling over an rsh or 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 has a clear and precise specification.
    • Unison is resilient to failure. It is careful to leave the replicas and its own private structures in a sensible state at all times, even in case of abnormal termination or communication failures.
    • Unison is free; full source code is available under the GNU Public License.

    Anyway, you might give it a look...

  • Re:Cygwin + rsync (Score:2, Interesting)

    by Filoseta ( 519421 ) on Wednesday August 04, 2004 @09:07PM (#9885117)
    To expand on this slightly, I have had good success with duplicity [nongnu.org].

    It supports gpg signing and encrypting of archives and provides direct support for scp/ssh as a transport while handling full and incremental backups very nicely (well, after I wrote a few wrapper scripts just to make my life easier).

    I have not used it on windows with cygwin, but I know people who are.
  • Re:Idea, (Score:4, Interesting)

    by nocomment ( 239368 ) on Wednesday August 04, 2004 @10:25PM (#9885533) Homepage Journal
    I do this [oreilly.com] on my linux boxes and it works really well. A quick google talks about people doing this between *nix and windows.
  • Look at rdiff-backup (Score:3, Interesting)

    by cornice ( 9801 ) on Thursday August 05, 2004 @12:22AM (#9886055)
    Take a look at rdiff-backup [stanford.edu]. I've been very impressed with it. From the website:

    rdiff-backup backs up one directory to another, possibly over a network. The target directory ends up a copy of the source directory, but extra reverse diffs are stored in a special subdirectory of that target directory, so you can still recover files lost some time ago. The idea is to combine the best features of a mirror and an incremental backup. rdiff-backup also preserves subdirectories, hard links, dev files, permissions, uid/gid ownership, and modification times. Also, rdiff-backup can operate in a bandwidth efficient manner over a pipe, like rsync. Thus you can use rdiff-backup and ssh to securely back a hard drive up to a remote location, and only the differences will be transmitted. Finally, rdiff-backup is easy to use and settings have sensical defaults.


    I found it to be very fast and reliable. And yes, it aparently does work under Windows [stanford.edu].
  • Re:Bacula (Score:2, Interesting)

    by GLHMarmot ( 124846 ) on Thursday August 05, 2004 @02:20AM (#9886436)
    I use bacula extensively between various flavours of linux and windows. It just works. You can set your retention period and it will automatically purge old information. It will write to various backup media (tape, disk etc) and create volume sizes of your choice.

    I use OpenVpn for encrypted connectivity between the machines as I am backing up a number of them across the net. It also has linux and windows clients.

    One caveat is that I don't use it to backup the entire system. I back up the users' data and configuration information as the rest can be easily restored from the original media.

  • dual boot to linux (Score:2, Interesting)

    by kyuso ( 775087 ) on Thursday August 05, 2004 @04:04AM (#9886824)
    I dual-boot to linux in all the Windows PC (Every PC has linux boot) then use ssh/rsync to backup the whole Windows directory. Of course all windows partition must be FAT32 (even for WinXP) or something read/writable by linux. Then ssh reboot to Windows.

    Nothing fancy to do on Windows. It takes 10 to 30 minutes to restore Windows to the way it was exactly when it was backed up, including XP. Without linux, it would have taken a whole day with all the patches, drivers, exact configuration, applications install, more patches, etc. etc.
  • by Proteus ( 1926 ) on Thursday August 05, 2004 @10:15AM (#9888498) Homepage Journal
    I've got a quick-and-dirty solution that I use for off-site backups of a relative's Windows network. This may not be exactly what you need, but hopefully it gets you started in the right direction.

    First, I create backup files. To do this, I use the Backup utility built into Windows (for better or worse). Of course, this assumes you have enough freespace on your Windows volumes to accomodate the backups...

    On the server side, I set up an FTP daemon and an OpenSSH daemon. The FTP daemon is configured to only accept connections from localhost, so one must log in via SSH to transfer via FTP.

    Then, I use a simple Win script to
    1. open a key-authenticated SSH session with PuTTY (configured to tunnel FTP connections)
    2. establish an FTP connection with localhost on the Win machine (initiates tunnelled connection)
    3. transfer the files with FTP over the secure link

    This has worked fantastically well for me, and the only thing I didn't already have was PuTTY. It's also as secure as any other SSH activity (pretty darn secure), and if you make the SSH session log in as a restricted "backup" user, it becomes very difficult to use this system to escalate privileges on the server.

On the eighth day, God created FORTRAN.

Working...