[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: mv: permissions warning with samba mount



On Thu, Jan 22, 2004 at 06:34:51PM +0100, Andreas Janssen wrote:
| Derrick 'dman' Hudson (<dman@dman13.dyndns.org>) wrote:
| > I have a shell script on one debian system here to back up certain
| > portions of the filesystem.  It simply tars up the directories and
| > moves the tar file to a samba share which is backed up by some already
| > in-place windows software.
| > 
| > The problem is that mv is too noisy :
| >     mv: failed to preserve ownership for
| >     `/mnt/red1/Builds/cvsbackup/CVS-Backup-2004-01-21.tar.gz':
| >     Operation not permitted
| > 
| > This is a problem because I then become conditioned to ignore emails
| > from cron assuming they only contain this non-problem.  However,
| > sometimes there is a real problem and I need to know about it.
| > Therefore, I want this particular error message to not be reported,
| > however I want other errors (for example No space left on device) to
| > go to stderr.  When this script is run, stdout is sent to a log file
| > and stderr (if any) is sent to me via mail.
| > 
| > Any suggestions?
| 
| Wouldn't the easiest way be to set the ownership of the file to that of
| the Samba mount before moving it?

That sounds like a plausible solution.

-D

-- 
The Consultant's Curse:
    When the customer has beaten upon you long enough, give him
what he asks for, instead of what he needs.  This is very strong
medicine, and is normally only required once.
 
www: http://dman13.dyndns.org/~dman/            jabber: dman@dman13.dyndns.org

Attachment: signature.asc
Description: Digital signature


Reply to: