Re: rsync questions

2009-03-26 Thread Paul Slootman
On Thu 26 Mar 2009, gahn wrote:
 
 I am trying to back up /export/home/* (all of users) on another machine but 
 exclude a certain types of files. here is one of my tested exclude files:
 
 /home/unwanted_dir
 
 this one works. rsync successfully backed up other directories except the 
 unwanted_dir
 
 But how could I get rsync search the patterns of files in those user 
 directories and exclude them?

Well, it tells you exactly in the manpage how to do it;
you've probably tried some things, it help help us to help you if you
say exactly what commands you have tried and what you want to happen.

Did you:
 Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html
do the above?


Paul
-- 
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: rsync questions

2009-03-26 Thread Harry Mangalam
You use '--exclude-from=/the/exclude/file'
and that file should look like he extract below

The following backs up all the users in my /home with the exceptions 
listed in it.  The ones that have 'hjm' reference my home dir.  the 
ones that have other users (hm/*) will completely skip those dirs.  
the ones that have no user spec (*.o) will omit all obj files from 
any subdir.

# use this command
# sudo rsync --exclude-from=/home/hjm/rsync.exclude  -av /home \
#h...@moon:/b/hjm/bongobak
hjm/.VirtualBox/*
hjm/.cx*
hjm/.cpan
hjm/code/*
hjm/nco_test/*
hjm/.kde/cache-bodi/http/*
hjm/.google/*
hjm/.googleearth/Cache/*
hjm/.thumbnails/*
hjm/nacs/osborne/gff*
hjm/nacs/2sigma/audio/*
hjm/.opera/cache4/*
hjm/.evolution/*
hjm/l_cc*
hjm/IDV*
hjm/code/SAS/*
hjm/SAS/*
hjm/.dods_cache/*
hjm/nco_bm/*
hjm/valgrind
hjm/.local/share/Trash/*
hjm/.ccache
hm/*
*.tmp
*.gff
*.chp
*.rpm
*.nc
*.o
*.rm
*.mov
*.deb
*out
*.iso

On Thursday 26 March 2009, gahn wrote:
 Hi all:

 I got basic rsync working (not server mode). Basically it went to
 another server via ssh, backed up subdireactories and stored on the
 local server. But I am trying to use the feature of exclude and
 could not get it working rigjt.

 I am trying to back up /export/home/* (all of users) on another
 machine but exclude a certain types of files. here is one of my
 tested exclude files:

 /home/unwanted_dir

 this one works. rsync successfully backed up other directories
 except the unwanted_dir

 But how could I get rsync search the patterns of files in those
 user directories and exclude them?

 Thanks



-- 
Harry Mangalam - Research Computing, NACS, Rm 225, MSTB, UC Irvine
[ZOT 2225] / 92697  949 824-0084(o), 949 285-4487(c)
---
Good judgment comes from experience; 
Experience comes from bad judgment. [F. Brooks.]
-- 
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: rsync questions

2009-03-26 Thread gahn

Thanks!


--- On Thu, 3/26/09, Harry Mangalam harry.manga...@uci.edu wrote:

 From: Harry Mangalam harry.manga...@uci.edu
 Subject: Re: rsync questions
 To: rsync@lists.samba.org
 Cc: ipfr...@yahoo.com
 Date: Thursday, March 26, 2009, 1:05 PM
 You use '--exclude-from=/the/exclude/file'
 and that file should look like he extract below
 
 The following backs up all the users in my /home with the
 exceptions 
 listed in it.  The ones that have 'hjm' reference
 my home dir.  the 
 ones that have other users (hm/*) will completely skip
 those dirs.  
 the ones that have no user spec (*.o) will omit all obj
 files from 
 any subdir.
 
 # use this command
 # sudo rsync --exclude-from=/home/hjm/rsync.exclude  -av
 /home \
 #h...@moon:/b/hjm/bongobak
 hjm/.VirtualBox/*
 hjm/.cx*
 hjm/.cpan
 hjm/code/*
 hjm/nco_test/*
 hjm/.kde/cache-bodi/http/*
 hjm/.google/*
 hjm/.googleearth/Cache/*
 hjm/.thumbnails/*
 hjm/nacs/osborne/gff*
 hjm/nacs/2sigma/audio/*
 hjm/.opera/cache4/*
 hjm/.evolution/*
 hjm/l_cc*
 hjm/IDV*
 hjm/code/SAS/*
 hjm/SAS/*
 hjm/.dods_cache/*
 hjm/nco_bm/*
 hjm/valgrind
 hjm/.local/share/Trash/*
 hjm/.ccache
 hm/*
 *.tmp
 *.gff
 *.chp
 *.rpm
 *.nc
 *.o
 *.rm
 *.mov
 *.deb
 *out
 *.iso
 
 On Thursday 26 March 2009, gahn wrote:
  Hi all:
 
  I got basic rsync working (not server mode). Basically
 it went to
  another server via ssh, backed up subdireactories and
 stored on the
  local server. But I am trying to use the feature of
 exclude and
  could not get it working rigjt.
 
  I am trying to back up /export/home/* (all of users)
 on another
  machine but exclude a certain types of files. here is
 one of my
  tested exclude files:
 
  /home/unwanted_dir
 
  this one works. rsync successfully backed up other
 directories
  except the unwanted_dir
 
  But how could I get rsync search the patterns of files
 in those
  user directories and exclude them?
 
  Thanks
 
 
 
 -- 
 Harry Mangalam - Research Computing, NACS, Rm 225, MSTB, UC
 Irvine
 [ZOT 2225] / 92697  949 824-0084(o), 949 285-4487(c)
 ---
 Good judgment comes from experience; 
 Experience comes from bad judgment. [F. Brooks.]


  
-- 
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html


Re: rsync questions

2001-06-05 Thread Dave Dykstra

On Tue, Jun 05, 2001 at 09:25:12AM +0100, Gonçalo Gomes wrote:
 Dear rsync users,
 i'd like to ask some questions about rsync,
 
 1) i'm going to use rsync to upload backups to backup machine, that
 machine will hold only backups.
 - does it keeps the ownership of the files if the users/groups, they
 don't exist in the remote machine (backup machines)
 or it keeps them in a database and restores them when replacing the
 backups ?

If you run as root and the users/groups don't exist on the backup machine
it will typically keep the original user id and group ids.  I'm not 
sure what happens if you're using an rsync --daemon as the destination,
though, perhaps it will just keep whatever uid is specified (defaults
to nobody).

 2) how to choose where a path (within the actual module name) to where
 upload the files without having to add a new module ?

Paths are chosen either through the module name if you're using rsync
--daemon mode or whatever path you specify otherwise.  I usually discourage
people from using --daemon mode for writing, as it was really mostly
intended for reading.  Ssh is the best access method.



 3) the --delete options means that, if we have a dir with index.htm and
 main.htm in the backup server, and then we remove main.htm from the
 client, when we're uploading the newbackup it will remove main.htm from the
 backup server?

Right.

- Dave Dykstra