Debian :: Backup Server With Rsync And Ssh

Jan 18, 2016

I switched last summer from Windows (used it since Windows 95) to Debian. I'm using Debian Jessie for a couple of months now and I'm getting used a little.

There are problems here and there, but I can solved them with some reading on the web. Not really a big problem...till now

I run Debian 8.2 om my PC (PC1). Bought an older PC (PC2) that I want to use as a backup server.

I'm using PC2 only for making backups, after the backup I switch it off again.

So I installed Debian 8.2 (net-install without DE and with SSH) on PC2 and tried to configure it to let it work as my backup location. Made a public SSH key and exported it to the root account (no problem) and to the user account (sensdeb), but there was an error "Access Denied"

Gave the user (sensdeb) sudo-rights via visudo file

# User privilege specification
root ALL=(ALL:ALL) ALL
sensdeb ALL=(ALL:ALL) ALL

I installed rsync.

The problem is that Rsync only works when I use the root account.

Code: Select allrsync -r -n -t -v --progress --delete -u -l -H -s /media/Data/Mp3/Anastacia root@192.168.1.102:/test/Mp3

When I try to sync with he normal user account sensdeb

Code: Select allrsync -r -n -t -v --progress --delete -u -l -H -s /media/Data/Mp3/Anastacia sensdeb@192.168.1.102:/test/Mp3

I get error's. Access Denied

I don know how to give the user sensdeb the rights so that I can use that account for my backup tasks. Now it's possible to sync with the root account, but that should not be the way to do it, I read many times.

View 7 Replies


ADVERTISEMENT

Server :: Sync File Server Data Into Backup Server Machine By Command- Rsync -avu?

Jun 21, 2011

iam trying to sync file server data into backup server machine by command- rsync -avu path/of/data ipaddress-of-backup-server:/path/where/to/save after running it ask for root password and manually it is successful.but i want to make it automatic.for that i also tried cronjob and also generated authentication key but iam not successful in login automatically..anybody know how to authenticate root to login for storing data in backup server.

View 14 Replies View Related

Ubuntu :: Rsync Backup Server

Jul 20, 2010

This should be a quick one. I'm trying to backup a single directory and it's subdirectories on my Lucid Server to a freenas box across my network. This is what I'm using to do that rsync -r -a -v -z * --delete freenas: DSIBackups..It almost works perfectly except for one problem. When a file is deleted at the source, this command doesn't seem to delete it on the receiving end. I assumed that the --delete would do that but aparently not.

View 1 Replies View Related

Debian :: Rsync Backup: Which Paths Should Exclude?

Nov 28, 2010

I'd like to backup my whole system to a 2nd disk using rsync (other tools not possible).Which paths should I exclude from the packup?I was thinking about /proc, /dev, the lost+found directories...What other paths am I forgetting?

View 2 Replies View Related

Ubuntu :: Use Rsync & Ssh To Move A Backup Folder Some Computers To A Server?

Mar 13, 2010

I am trying to use rsync & ssh to move a backup folder some computers to a server. I found a command that is supposed to do this, but I am having issues getting it to work.

Code:
rsync -avz -e 'ssh -p 'port' 'username'@'hostname' ' /source/path host:/destination/path

View 2 Replies View Related

Server :: Rsync Error - Command To Backup Image File

Oct 6, 2010

when i use rsync command to backup my image file , it shows the following error message.

bash: line 1: /usr/bin/rsync: Argument list too long
rsync: connection unexpectedly closed (0 bytes received so far) [receiver]
rsync error: remote command could not be run (code 126) at io.c(463) [receiver=2.6.8]

The command which i used is rsync -avrl -e ssh cms@server:/data/cms/data/images/* /mnt/Backup/Intranet_cms_backup/images

View 7 Replies View Related

Ubuntu :: Using Rsync For Backup?

Mar 2, 2010

I saw in a magazine reference to using rsync to have identical copies of folders. This looks like something I could find useful as I have a large number of items in need of safe backup.

I have the folders on an old system on a home network and would like to copy these over to a USB Hard Drive.

Currently the folders reside on SFTP xxx.xxx.xxx.xxx and I wish to sync them to a USB port on my laptop.

View 9 Replies View Related

Ubuntu :: Backup Using Rsync

Aug 2, 2010

I have a samba share to a windows 7 computer I do not know if I will be able to use backintime or not so I want to know how to have rsync do my backup.I read the man but I'm not sure if I understand the it.on same computer different hard drive to run every hour in a script. Leanne is windows 7 share and backup is the other hard drive in the computer rsync -arvRzEP /media/leanne /media/backup.

View 1 Replies View Related

Server :: Rsync Execution - With Crontab - Have Given Full Path To Rsync Too

Apr 12, 2011

I have a tiny shell script to rsync files between two servers and remove the source files.

This script works fine, when it has been initiated manually or even when the rsync command is executed on the command line.

But the same script doesn't work, when I try to automate it through crontab.

I am using 'abc' user to execute this rsync, instead of root, as root login to servers are restricted in all of our servers, by us.

As I mentioned earlier, manual execution works like charm!

When this rsync.sh is initiated through crontab, it runs the first command(chown abc.abc ...) perfectly without any issues. But the second line is not at all executed, and there is no log entry i can find at /mnt/xyz/folder/rsync.log.

View 6 Replies View Related

Software :: Run Rsync To Download Files From A Server Without Rsync Daemon?

Sep 18, 2009

I just tried to sync files from one server to another. After the sync process, I found the files are bigger than original ones.

I looked up the web and found someone mentions the rsync daemon. So I have to run the daemon on one server before I run the rsync?

The command I used is rsync --partial --progress -r source destination

View 1 Replies View Related

OpenSUSE :: Rsync Backup : Upgrade To 11.4 64 Bit?

Mar 14, 2011

had some 'files disappearing' probs for rsync after upgrade to openSuSE 11.4 - solution seems to be to add :

--exclude=/var/lib

View 1 Replies View Related

General :: How To Do Rsync-like Encrypted Backup

Feb 27, 2011

I want to save a backup of my data on a remote server, but never want the backup server to see the data unencrypted. Editing a single file and backing up should not result in everything being encrypted and sent again. The remote server should preferably not even know the directory structure (and especially not the directory names).

View 2 Replies View Related

Ubuntu :: Permissions With Rsync On Backup

Jun 18, 2010

I'm trying to learn how rsync works to backup my system. I tried:
Code:
rsync -azvv /home /media/Elements
I get a folder called home on my external hard drive but when I use ls -l to see the permissions they are all wrong.
On my /home folder the permissions for /nathan are
drwxr-xr-x 48 nathan nathan
The permissions on the backup /nathan folder are
drwx------ 1 nathan nathan

I also tried using the long version of -a which is -rlptgoD and that didn't work either. What do the 48 and 1 mean when I used ls -l? When I look in the /nathan folder the permissions are all screwed up too. A lot of the files are backed up as executable and the permissions are all screwed up. I also ran it with sudo, and that didn't work either. The permissions were still screwed up and ownership is messed up too.

View 3 Replies View Related

Ubuntu :: Rsync Like Incremental Backup

Oct 20, 2010

when rsync is finished the update, or in the meantime - i need to move the updated files to a different location - like date +%Y%m%d something or what ..the reason is, because of the development, i need the modified files, but all of them, not just the last one - so i have to store them daily, but i dont want to store the whole dir - just that few files which are updated does it make sense?

View 5 Replies View Related

General :: Three Stage Backup With Rsync?

Jul 13, 2010

I've been trying to make a three stage backup with stage 0 being a full monthly back up, stage 1 being a weekly backup, and stage 2 being a daily backup. I've been trying very hard to use rsync for this but sorting files by date is proving to be problematic. Sometimes it seems to work from the command line directly, but the same command causes errors and warnings from a script while entirely failing to sort the correct files.

The common example I see for this involves commands like this:

Code:
rsync -Rav `find /home/ -ctime -7 -print` /path/to/home_backup The problem seems to be that since the user directories in /home contain files that have been altered within the time frame specified the whole directory is matched first which means that the whole directory is recursively archived as opposed to just the changed files.

I've also seen examples using the --files-from tag using the same find parameters and this one seems to ALMOST work but gives me strange warnings and fails to run at all when launched from a script.

Many of the things I've googled about using rsync to backup stuff by the date modified involves a rather snarky "You're missing the point of rsync!" to which I respond by yelling at my computer monitor followed by "JUST TELL ME WHAT I NEED TO KNOW!" I understand that rsync is meant to take care of incremental backups on it's own, that's why I want to use it specifically for a traditional 3 stage backup scheme.

View 5 Replies View Related

Security :: Backup Securely With Rsync?

Jul 11, 2010

To copy from production to standby over the internet I use a cron job doing rsync -avze 'ssh -p 8022' --exclude-from= ....

My question is: should the cron job run on the production or the standby system. Root access to the remote system is given by a pass phrase-less ssh key. Currently I run rsync on the production system. I guess that it is more secure because the standby needs no ssh login to production. Running rsync on the standby would use less resources on production. I am concerned that in this case there would be pass phrase-less access from standby to production.

View 3 Replies View Related

Software :: Restoring An Rsync Backup

Jul 10, 2011

I'm doing an rsync backup to an external drive in order to take a shot at setting up partition encryption. My rsync command is, as root: Code: rsync -av / /external1/backup.Once I've finished my cryptsetup and done a fresh Linux install, what command should I use to properly restore my backup (without messing up the encryption setup)?

View 1 Replies View Related

Server :: Rsync Can Not Rsync Files With Include Filter

Jul 21, 2010

use rsync to cp such files and dirs under /var/www/html/mydir directory but these two files(/dir4/1.html /dir4/2.html) cant rsync to dest mechine.

rsync configure file,below...

View 2 Replies View Related

Fedora :: Making An Rsync Backup More Robust?

Aug 24, 2009

I'm syncing a server over the internet with rsync, but it only works for a few hours before the backup fails with a "No route to host". I can restart the job and it'll will pick up where it left off, but is there an automated way to do this, or protect against a connection failure? I have about 170GB to copy over initially, but I can only get through about 4-5GB before the connection drops--manually restarting the sync everytime it drops will make the initial backup take days...

View 2 Replies View Related

Ubuntu :: Use Rsync To Backup Home Directories To A Nas?

Apr 14, 2010

I'm hoping somebody can find something here that I haven't. I'm trying to use rsync to backup home directories to a nas. First, I NFS mounted the nas and ran an rsync and everything worked out fine. the transfer completed after a few hours and everyting was transferred (lots of stuff!). I then decided that I don't want to leave the nas mounted all the time and I didn't want to automate mounting and unmounting of the nas as I didn't think I could produce a script that would work reliably enough. So I decided to start an rsync daemon on the nas and upgrade via that. I run the following command (results are included. the ^C is me killing it after it hangs).


Code:
ryan@server:/etc/backup$ sudo rsync -ax --stats --progress --delete /data root@192.168.0.98:backups1
root@192.168.0.98's password:
sending incremental file list
data/home/user/Documents/
data/home/user/Documents/The File.wmv

[Code]...

View 3 Replies View Related

Ubuntu :: Backup Files To Ntfs With Rsync?

May 31, 2010

well, i know ther are issues when using rsync to copy files to ntfs partition like file permission blah blah. the thing is, i need to backup my music files periodically onto a ntfs partition from ext4. i really dont care about file permissions or any other stuff. when i use rsync, it should update the mp3 files on my ntfs (external) disc with the new ones.can i give a go with this operation? i have lot more important files on the external disc and i dont want this rsync corrupt or delete those files coz they are highly important files.

View 2 Replies View Related

Ubuntu Servers :: RSYNC With Archive Backup

Sep 15, 2010

I have a Linux host acting as an ISCSI server for a Windows box. I want to keep an off site backup, so I figure rsync will keep the ISCSI server synced with an offsite Linux host. I understand that Rsync does block level incremental transfer to conserve bandwidth ok, awesome.The trick is, that I also want an archival copy kept. Say I want to go back to a revision of a file from 10 days ago, I need to be able to do that.

I was planning on using Backup Exec, since we currently have a licensed copy. Throw the archives from Backup Exec onto the ISCSI server as well, and have it keep a rotating 30 day backup, or something like that. The issue I see here is that this will be creating a deleting files as it does its daily backup rotation. I'm guessing RSYNC will see these as new files, and likely retransmit everything on a daily basis. The question then becomes, is this assumption correct, or will it still know to do a block level incremental transfer even when file names and such are changing?

View 5 Replies View Related

Ubuntu :: RSYNC Error - Backup Failed

Jan 29, 2011

Our backup script was working fine (ssh to the server, back up /home to a second hard drive on my computer). Then right after an ubuntu update, it quit working. I investigated and found that "something" had changed the label on the backup hdd to what looked like gibberish to me. But the script identified the backup hdd by its uuid, which didn't change. Yet, here is the error I get when the backup fails: receiving file list ... done [took about 5 seconds] rsync: mkdir "/media/14D9-3B1F/server-backup" failed: No such file or directory (2) rsync error: error in file IO (code 11) at main.c(594) [receiver=3.0.6]

Note that the backup hdd IS mounted, uuid is correct, and the folder 'server-backup' DOES exist. Does anyone have a clue for me? I'm moderately experienced in Linux and ubuntu. Our server runs centos 5. And as stated, the backup ran fine for several weeks. I think there was a new linux kernel on that update, but at this point a while later I don't know which one. Current kernel is .2.6.31-22-generic.

View 1 Replies View Related

Ubuntu Servers :: Any Way To Encrypt Backup Using Rsync

Feb 4, 2011

I support a small business which has an Ubuntu server running as a file server. The server is running Ubuntu 10.4. There is one hard drive which is mounted as /media/hdd. Each night this is backed up to an external USB hard drive mounted as /media/backup. The backup is carried out using the command:

Code:
rsync -av /media/hdd/ /media/backup/

Is there a way to encrypt this back-up so that if the USB hard drive is plugged into another machine it cannot be read?

View 5 Replies View Related

Ubuntu :: Rsync Backup Ends In Busy Box?

Jul 30, 2011

i am trying to keep a backup of my root on a second partition using rsync.

sda1 system
sda2 system-BAK
sdb1 /home

[code]....

View 3 Replies View Related

General :: Rsync Command - For File Backup ?

Mar 23, 2011

I'm going to be using this command to back up my files:

Should I change anything or is it ok?

View 4 Replies View Related

CentOS 5 :: Ruse Rsync To Backup A Directory?

May 22, 2010

I want to use rsync to backup a directory on my local hard drive to a USB hard drive.

I created the initial backup with:

rsync -av /share/chris/docs/* /usb/docs

View 7 Replies View Related

Debian Configuration :: Rsync From Linux Server To Planet NAS

Jan 5, 2016

After hours of struggles I'm still not able to configure a simple backup from a Debian Jessie server to a Planet branded NAS.

Configuration is as follows:
NAS
user name: user
pass: user12
share name: user. Inside that directory, there is bkp directory where stuff should go. bkp was created using Dolphin.
The NAS offers smb service and is accessible through Dolphin file manager and from Windows stations.

Server also has a user named "user" and a password "1"..

Fstab looks like this:
//192.168.2.3/user /mnt/NAS cifs username=user,password=user12,iocharset=utf8 0 0

The command is: Code: Select allrsync -ahv /home/user/Desktop/ /mnt/NAS/bkp/

Errors are: Code: Select allrsync: chgrp "/mnt/NAS/bkp/." failed: Operation not permitted (1)
and
Code: Select allrsync: mkstemp "/mnt/NAS/bkp/.teszt.YEmVM3" failed: Operation not permitted (1) where teszt is a file created by me and YEmVM3 seems to be randomly generated character string.

View 0 Replies View Related

OpenSUSE :: Rsync Backup *cache* Directories And Files?

Mar 4, 2010

I'm creating a backup scheme with rsync.

It is pretty clear not to include these:
/var/lib/named/proc
/var/lib/ntp/proc

[code]...

View 3 Replies View Related

Ubuntu Servers :: Rsync - Backup Only Changed Blocks?

Aug 10, 2010

I'm going to make a nightly backup copy from one server to another, using rsync. If I have a sufficiently large file, say 4+ GB or so, I'm not interested in copying the whole file if only a small change has been made. Can rsync detect small changes on block level and backup only those if needed?

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved