Solved

help with rsync on AIX

Posted on 2013-05-10
2
529 Views
Last Modified: 2013-05-10
I would like to copy directory from the source server with the following using rsync:

recursively
ignore symbolic links
skip the file/directory if it is the same on the target server

Can someone please help?
0
Comment
Question by:AIX25
2 Comments
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 500 total points
ID: 39154636
- recursively: the "-r" option. Implied with "-a"

- ignore symlinks: the "--no-links" option. Not implied with "-a"!

- skip if the same: That's the default behaviour anyway. You can additionally instruct rsync to ignore files that are newer on the target server by means of the "-u" option.

So your command should look similar to this:

rsync -a --no-links -u -e "/usr/bin/ssh" /source/dir/ user@target-server:/target/dir

Please note that the trailing slash in the source dir spec tells rsync not to create an additional directory level on the target.

I used "-e /usr/bin/ssh" to  force using the ssh protocol. Please adjust the ssh path if it's different, or replace "ssh" with "rsh" if you don't have ssh installed. The latter requires modifying the .rhosts file on the target to include the source host, however.
0
 

Author Comment

by:AIX25
ID: 39156108
Thank you! I was able to run this over ssh.
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A metadevice consists of one or more devices (slices). It can be expanded by adding slices. Then, it can be grown to fill a larger space while the file system is in use. However, not all UNIX file systems (UFS) can be expanded this way. The conca…
Introduction Regular patching is part of a system administrator's tasks. However, many patches require that the system be in single-user mode before they can be installed. A cluster patch in particular can take quite a while to apply if the machine…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

815 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now