Sponsored Content
Top Forums Shell Programming and Scripting Help needed with Content synchronization script using rsync Post 302889513 by maverick72 on Friday 21st of February 2014 04:33:46 AM
Old 02-21-2014
Well you do not have much options then.

Best thing would be to do your rsync and change the files on the remote server:

- Rsync on remote server
- Find/edit/replace your files

You still don't touch your source files and you do not need double disk space on the other end since you will be editing the files directly.

Since you should probably have ssh keys on source and remove servers you could triger your script to ssh <command> to edit your files.

What are the conditions/changes/results your are targeting at the end?
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Help needed for rsync

How can i combine the below two rsync commands into one: rsync -auvL --delete /etc /usr/local/MediaServer /mnt/bak/livecore/filesystem.0 > /tmp/backup_log/rsync.log 2>&1 and rsync -auv --delete --exclude='live/public_html/video' --exclude='live/public_html.old' /var/www... (0 Replies)
Discussion started by: proactiveaditya
0 Replies

2. Shell Programming and Scripting

Help with rsync script

Good day all, I need your help in editing a rsync script that I am trying to write and using ksh shell. I want to add multiple patterns --include and --exclude options with variable inputs called SID. I have created two files and named them N1 and N2 and created subfiles in each one In... (4 Replies)
Discussion started by: Noura-83
4 Replies

3. Shell Programming and Scripting

help with sed needed to extract content from html tags

Hi I've searched for it for few hours now and i can't seem to find anything working like i want. I've got webpage, saved in file par with form like this: <html><body><form name='sendme' action='http://example.com/' method='POST'> <textarea name='1st'>abc123def678</textarea> <textarea... (9 Replies)
Discussion started by: seb001
9 Replies

4. Shell Programming and Scripting

Synchronization, rsync option

Dear all, I am synchronizing some files on 2 hosts. host2 is a backup server of host1, but can have some more up to date files. I use on host2: rsync -auv usrer@host1:/Source_Dir Dest_DirOption -u (update) will copy and replace the newest files from host2 to host1. Before this is done I... (1 Reply)
Discussion started by: freddie50
1 Replies

5. Solaris

I need to synchronization by rsync

Hi everyone! I wonder about the rsync. The purpose I just want: synchronization from server 1 to server 2 by rsync, example: Node 1: /app/logs/* Node 2: /app/logs/* in Node 1 when I used rsync -aru /app/logs/ node2:/app/logs/, then everything will be copied and update to node 2. But,... (1 Reply)
Discussion started by: trantuananh24hg
1 Replies

6. Shell Programming and Scripting

Help Needed on RSYNC

My Script as below ####### #!/usr/bin/ksh DIR=$1 MN=`echo $1 | awk -F'/' '{print $NF}'` LF=./rsynclog RSYNC=/usr/local/bin/rsync mv $LF.$MN $LF.$MN.prev compress $LF.$MN.prev $RSYNC -arz --rsync-path=$RSYNC --log-file=$LF.$MN SERVER1:$DIR/ $DIR While running it I am getting... (1 Reply)
Discussion started by: Atp3530
1 Replies

7. Shell Programming and Scripting

Help needed in sending file content with colors and borders

HI i am running a shell script in cron and storing the output of that script in a file say test.then i am copying the content of test to test1 and i will send the output of test to some email ids using mutt. Next time when the script executes i am comparing the contents of test and test1 and... (3 Replies)
Discussion started by: venkitesh
3 Replies

8. Shell Programming and Scripting

Rsync Error: rsync: link_stat failed: No such file or directory (2)

I wish to copy all the files & folder under /web/Transfer_Files/data/ on mymac1 (Linux) to remote server mybank.intra.com (Solaris 10) /tmp/ location I am using Ansible tool synchronize module which triggers the unix rsync command as below:rsync --delay-updates -F --compress --archive --rsh=ssh... (2 Replies)
Discussion started by: mohtashims
2 Replies

9. Shell Programming and Scripting

Help Needed for creating the folder by checking today's date and, take backup using rsync command

How to create a shell script to create a folder by using the today's date to take backup using rsync command on every evening around 7 pm. Kindly help. Thanks. To be more precise, I want to create a script which matches the today's date with server's date format, if matches then creates the... (2 Replies)
Discussion started by: bakula10
2 Replies
SSH-COPY-ID(1)						      General Commands Manual						    SSH-COPY-ID(1)

NAME
ssh-copy-id - install your public key in a remote machine's authorized_keys SYNOPSIS
ssh-copy-id [-i [identity_file]] [user@]machine DESCRIPTION
ssh-copy-id is a script that uses ssh to log into a remote machine (presumably using a login password, so password authentication should be enabled, unless you've done some clever use of multiple identities) It also changes the permissions of the remote user's home, ~/.ssh, and ~/.ssh/authorized_keys to remove group writability (which would oth- erwise prevent you from logging in, if the remote sshd has StrictModes set in its configuration). If the -i option is given then the identity file (defaults to ~/.ssh/id_rsa.pub) is used, regardless of whether there are any keys in your ssh-agent. Otherwise, if this: ssh-add -L provides any output, it uses that in preference to the identity file. If the -i option is used, or the ssh-add produced no output, then it uses the contents of the identity file. Once it has one or more fin- gerprints (by whatever means) it uses ssh to append them to ~/.ssh/authorized_keys on the remote machine (creating the file, and directory, if necessary) SEE ALSO
ssh(1), ssh-agent(1), sshd(8) OpenSSH 14 November 1999 SSH-COPY-ID(1)
All times are GMT -4. The time now is 08:23 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy