LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 05-11-2011, 08:06 AM   #1
arashi256
Member
 
Registered: Jan 2008
Location: Brighton, UK
Distribution: Ubuntu 12.04 / CentOS 6.5
Posts: 384

Rep: Reputation: 61
rsync - how to suppress "skipping non-regular file" messages


Using rsync, which switch will allow rsync to suppress the "skipping non-regular file" messages in the output while still being reasonably verbose for everything else?
 
Old 05-11-2011, 09:02 AM   #2
Snark1994
Senior Member
 
Registered: Sep 2010
Location: Wales, UK
Distribution: Arch
Posts: 1,630
Blog Entries: 3

Rep: Reputation: 345Reputation: 345Reputation: 345Reputation: 345
The relevant section of the man page is:
Code:
       Three basic behaviors are possible when  rsync  encounters  a  symbolic
       link in the source directory.

       By  default,  symbolic  links  are  not  transferred at all.  A message
       "skipping non-regular" file is emitted for any symlinks that exist.

       If --links is specified, then symlinks are recreated with the same tar-
       get on the destination.  Note that --archive implies --links.

       If  --copy-links is specified, then symlinks are "collapsed" by copying
       their referent, rather than the symlink.

       Rsync can also distinguish "safe"  and  "unsafe"  symbolic  links.   An
       example  where  this  might be used is a web site mirror that wishes to
       ensure that the rsync module that is copied does not  include  symbolic
       links  to  /etc/passwd  in  the  public  section  of  the  site.  Using
       --copy-unsafe-links will cause any links to be copied as the file  they
       point  to  on  the  destination.   Using --safe-links will cause unsafe
       links to be omitted altogether.  (Note that you  must  specify  --links
       for --safe-links to have any effect.)

       Symbolic  links  are  considered  unsafe  if they are absolute symlinks
       (start with /), empty, or if they contain  enough  ".."  components  to
       ascend from the directory being copied.

       Here's  a summary of how the symlink options are interpreted.  The list
       is in order of precedence, so if your combination of options isn't men-
       tioned, use the first line that is a complete subset of your options:

       --copy-links
              Turn all symlinks into normal files (leaving no symlinks for any
              other options to affect).

       --links --copy-unsafe-links
              Turn all unsafe symlinks into files and duplicate all safe  sym-
              links.

       --copy-unsafe-links
              Turn  all unsafe symlinks into files, noisily skip all safe sym-
              links.

       --links --safe-links
              Duplicate safe symlinks and skip unsafe ones.

       --links
              Duplicate all symlinks.
My guess is probably that you want the "--links --copy-unsafe-links" switch, but it depends on exactly which behaviour you want

Last edited by Snark1994; 05-11-2011 at 09:03 AM.
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
rsync "sending incremental file list"??? ssisbi Linux - General 9 01-30-2011 06:28 AM
[SOLVED] rsync: log-file: howto get rid of ".d...p..... send" Hans Troost Linux - Software 3 09-04-2010 09:03 AM
rsync "skipping non-regular files" with --archive option andrewtblake Linux - Server 2 04-29-2010 04:15 PM
rsync: how to copy file, "Operation not permitted" nugroho2 Linux - Laptop and Netbook 3 04-21-2010 07:57 AM
Boot messages not the same as "dmesg" or "/var/log/messages"? massai Linux - General 5 03-10-2004 12:18 AM


All times are GMT -5. The time now is 12:33 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration