Link to home
Start Free TrialLog in
Avatar of Jasaida
Jasaida

asked on

rsync on ubuntu

rsync error on ubuntu 16.04 server.
i try to sync folder between two ubuntu server and say
sshpass -p password@ rsync  ssh -avhre user@ip_server:/home/my/direct/ /home/my/
rsync error: some files/attrs were not transferred (see previous errors) (code 23) at main.c(1655) [generator=3.1.1]

Help!!!
Avatar of robocat
robocat

Try adding the quiet option to the rsync command, this will only show error messages instead of all files being transferred.

-q, --quiet  

This way you should easily see which files failed and why.
sshpass -p 'sshpassword' rsync --progress -avz -e ssh test@remhost:~/something/ ~/bak/


please try this
Avatar of Jasaida

ASKER

' ' round for password is not help i get the same error
and -q say:
Unexpected remote arg:
but the argument is user@ip:/folder/  ?
or what?
Avatar of Jasaida

ASKER

I  don't know, what happend, bit it's working now. i recreate ssh key's.
Which option i should use for full sync?
i mean when i remove a file from source is still in target.  
i create a file "a" in source it's comming in target then i remove a a file ia still in target after sync.
--delete will delete files on the target
SOLUTION
Avatar of David Favor
David Favor
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Jasaida

ASKER

robocat:
delete option is not working.
can i use with other option or need to use separately .
i say :
sshpass -p "password" sync -ahvre --delete sh  user@server:/folder/../  /folder../
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Jasaida

ASKER

Thanks it's working i just put --delete first
... rsync --delete -avhre ssh ....