RE: Rsync command and verbose log
- From: "Maxime Alarie" <malarie@xxxxxxxxxxxxx>
- Date: Thu, 29 Apr 2010 16:50:11 -0400
If I can suggest a more friendly date..
#!/bin/bash
DATE=$(date +%Y-%m-%d) will output: 2010-04-29
Regards
-----Original Message-----
From: ubuntu-users-bounces@xxxxxxxxxxxxxxxx
[mailto:ubuntu-users-bounces@xxxxxxxxxxxxxxxx] On Behalf Of Richard
Mancusi
Sent: Thursday, April 29, 2010 1:41 PM
To: Ubuntu user technical support,not for general discussions
Subject: Re: Rsync command and verbose log
On Thu, Apr 29, 2010 at 12:20, Vijay Shanker Dubey
<vijay.shad@xxxxxxxxx> wrote:
Hi,system. I
I am creating a script to sync my important documents between two
want my script to generate a log file for the last action. can yousuggest
me a way to achieve this.lot
Question: If I execute the rsync command with -v flag, it will print a
of messages on the console. Is there any way. So, I can redirect theselogs
to a file?
Regards,
Vijay Shanker Dubey
write a script something like this:
(yes I know some of the flags are redundant)
replace the <> with your data
last 2 echos simply place 2 blank lines between one log
entry and the next
#!/bin/bash
DATE=`date`
echo $DATE BackUp Started: <your source> to <your destination> >> <log
file name>
rsync -e ssh -raPH -v >> <log file name> --delete <data to copy> <ip>:
rsync -e ssh -raPH -v >> <log file name> --delete <more data to copy>
<ip>:
rsync -e ssh -raPH -v >> <log file name> --delete <more data to copy>
<ip>:
rsync -e ssh -raPH -v >> <log file name> --delete <more data to copy>
<ip>:
echo $DATE BackUp Finished: <your source> to <your destination> >>
<log file name>
echo >> <log file name>
echo >> <log file name>
--
ubuntu-users mailing list
ubuntu-users@xxxxxxxxxxxxxxxx
Modify settings or unsubscribe at:
https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
--
ubuntu-users mailing list
ubuntu-users@xxxxxxxxxxxxxxxx
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
- References:
- Rsync command and verbose log
- From: Vijay Shanker Dubey
- Re: Rsync command and verbose log
- From: Richard Mancusi
- Rsync command and verbose log
- Prev by Date: Re: problem with nautilus
- Next by Date: Re: Flash video on YouTube?
- Previous by thread: Re: Rsync command and verbose log
- Next by thread: Re: Rsync command and verbose log
- Index(es):
Relevant Pages
|