Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to sync files from development machine running Windows (using cygwin) to staging server running Linux.

I tried rsync -avz --no-p --no-g so synced directories/files would receive default permissions, but in my case both directories and files receive 755 permission. It's fine for direcotries, but for files I would like to get 644.

I tried playing with --chmod but couldn't find the right combination.

share|improve this question
add comment

1 Answer 1

I was having the same problem and your question pointed me towards the --chmod option. The recommended settings seem to work for me. I'm using cygwin on a Windows 7 system syncing to a FreeBSD system.

% rsync -rltvu --chmod=ugo=rwX Applications unixhost:/windows/backup

Using that, the destination host received the files with directory mode 755 and file mode 644.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.