Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 207591
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T17:44:58+00:00 2026-05-11T17:44:58+00:00

I have a server where I store data from Mac A and Mac B.

  • 0

I have a server where I store data from Mac A and Mac B.

I use rsync to keep the files updated between my Macs.

I run the following code unsuccessfully

#!/bin/zsh

#    to copy files from my server to my folder
rsync -Pav $Masi:~/private/ ~/Dropbox/Courses/math/

#    to  copy files from my folder to my server
rsync -Pav ~/Dropbox/Courses/math $Masi:~/private/

I get the following error message

ssh: connect to host  port 22: Connection refused
rsync: connection unexpectedly closed (0 bytes received so far) [receiver]
rsync error: unexplained error (code 255) at io.c(600) [receiver=3.0.5]
ssh: connect to host  port 22: Connection refused
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: unexplained error (code 255) at io.c(600) [sender=3.0.5]

I have ssh keys in place so the connection should work, since I can use scp without problems.

How can you use rsync between my server and one of my Macs?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T17:44:58+00:00Added an answer on May 11, 2026 at 5:44 pm

    I used to do a lot of this. Just ran a test, a few suggestions.

    1. Spell out your entire user@host pattern
    2. Run the ssh connection sans the rsync first, you may need to first approve your fingerprint
    3. You do not seem to pass a flag to protect extended attributes, this can yield broken files on OS X. If you do not need resource forks, you are OK, but most of the time you do need them.

    My test case:

    $ rsync -Pav ~/Desktop/ me@remote.example.com:~/rsyc-test
    

    In that case, all the files within ~/Desktop were copied to the remote host, in my home dir. Since the directory ‘rsyc-test’ did not exist, it was made for me. I had a .app on my Desktop, it made it over, surprisingly, it works. Even some .webloc files made it and appear to work, though I do not trust it.

    I would strongly suggest adding in the -E flag

      -E, --extended-attributes
             Apple specific option  to  copy  extended  attributes,  resource
             forks,  and  ACLs.   Requires at least Mac OS X 10.4 or suitably
             patched rsync.
    

    I ran a new test, moved a Interarchy bookmark to my desktop, I know for a fact these break if they are copied sans resource forks. Running without the -E versus with the -E, there is a difference of 152 bytes in xfered data. The first file on the remote machine did not work, the second transfered file did work.

    I can not help but notice in your example one of your paths is ~/Dropbox so this may all not matter, since DropBox, the app, does not at all support resource forks currently, though I hear there are plans to in the future.

    You also are not sending in the –delete flag, if your end goal is a mirror of your data, you are not getting that, if your end goal is backups that continually grows, keeping everything that was ever on the source, the lack of –delete is good.

    Other notes:
    You can exclude those silly .DS_Store files
    –exclude ‘.DS_Store’

    You can also set rsync up in a way to be a true mirror, so you would not need to run your other command, see the man page for details.

    My final working command to shove the Desktop of my laptop to a remote machine:

    $ rsync -PEav --delete --exclude '.DS_Store' ~/Desktop/ me@remote.example.com:~/rsycn-test
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 303k
  • Answers 303k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer http://support.microsoft.com/kb/161137 If you can open project A, you want to… May 13, 2026 at 8:42 pm
  • Editorial Team
    Editorial Team added an answer Well, basically: separation of concerns on the usage level, not… May 13, 2026 at 8:42 pm
  • Editorial Team
    Editorial Team added an answer The capitalizedString method exists in NSString class, see the docs… May 13, 2026 at 8:42 pm

Related Questions

Simple question regarding data persistance between application sessions. My application allows the user to
I'm getting confused re the range of options for development & deploying some simple
I use SQL Server 2005 as a data store for a lot of data
I have recently found myself becoming more negative about EF and cannot help wondering

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.