From: Vwaju on
I have a computer running Slackware 13.0 and one running Windows XP.
The computers are networked with ethernet connections to a Linksys
router running OpenWRT. The Windows box has a large external USB HD
where Windows files are backed up.

I would like to back up files from the Slackware box on the same HD,
but uncertain about the best approach. Can Samba be used for this?
If not, what's the best approach.

Thanks & Best Regards,

Vwaju
New York City
From: Grant on
On Fri, 12 Mar 2010 11:06:29 -0800 (PST), Vwaju <slack(a)rcn.com> wrote:

>I have a computer running Slackware 13.0 and one running Windows XP.
>The computers are networked with ethernet connections to a Linksys
>router running OpenWRT. The Windows box has a large external USB HD
>where Windows files are backed up.
>
>I would like to back up files from the Slackware box on the same HD,
>but uncertain about the best approach. Can Samba be used for this?

You're batter off backing up linux files to a linux filesystem to
maintain permissions, no? Might not matter if the files are data and
public.

>If not, what's the best approach.

Use CIFS, not Samba. Perhaps make a tarball of linux files and back the
tarball up, this would preserve permissions.

A better method would be to run the USB store from Linux, where it is
much easier to control, no?

The only problem I have in sharing a writable Linux directory to windows
is that windows can delete files over the network without warning -- I
get too used to the windows handholding that copies deleted local files
to the 'Recycle Bin' when in the 'doze Drag'n'Drool interface;)

I use username/password for sharing slackware directories, from /etc/fstab:
....
//sillywin/music /mnt/music cifs noauto,user,credentials=/usr/local/etc/xsmb
//sillywin/install /mnt/install cifs noauto,user,credentials=/usr/local/etc/xsmb

~# cat /usr/local/etc/xsmb
username=grant
password=my_password


The '/home/common' directory on the server box is NFS exported to localnet
linux boxes, and also to windoze via /etc/smb.conf:
....
[common]
comment = system common directory
path = /home/common
valid users = grant
read only = No

Grant.
From: Douglas Mayne on
On Fri, 12 Mar 2010 11:06:29 -0800, Vwaju wrote:

> I have a computer running Slackware 13.0 and one running Windows XP. The
> computers are networked with ethernet connections to a Linksys router
> running OpenWRT. The Windows box has a large external USB HD where
> Windows files are backed up.
>
> I would like to back up files from the Slackware box on the same HD, but
> uncertain about the best approach. Can Samba be used for this? If not,
> what's the best approach.
>
> Thanks & Best Regards,
>
> Vwaju
> New York City
>
This is a case of "whatever works for you," but I much prefer making all
backups from Linux. In any case, it is best to be very familiar with the
tools you use. To backup Windows, I boot a live cd (or equiv), and make
the backup with ntfsclone (with gzip).

Here is one example command line:
# SRC=/dev/sda1
# DEST=/mnt/usb_x/backups/computer_name/date/sda1.sf.img.gz
# ntfsclone -s -o - $SRC | gzip >$DEST

I described this in slightly more detail here:
http://groups.google.com/group/comp.os.linux.misc/msg/527d2aa14e9daeb7

A similar backup technique can be employed for GNU/Linux (i.e. using a
live cd, or equiv).

# SRC=/mnt/sda1
# DEST=/mnt/usb_x/backups/computer_name/date/sda1.tgz
# (cd $SRC && tar -cpf - .) | gzip >$DEST

Another option is to send the data being backed up over the network using
the network transport of your choice- nc, ssh tunnel, samba, etc.

One reason that I prefer using external usb's with GNU/Linux is to add
and encryption layer at the same time. Windows users can use Truecrypt or
similar, but I prefer using device mapper with GNU/Linux. Using
encryption allows backups to be sent offsite for storage without worrying
what would happen if they were lost in transit, etc.

--
Douglas Mayne