LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 07-07-2014, 01:08 PM   #1
xmrkite
Member
 
Registered: Oct 2006
Location: California, USA
Distribution: Mint 16, Lubuntu 14.04, Mythbuntu 14.04, Kubuntu 13.10, Xubuntu 10.04
Posts: 554

Rep: Reputation: 30
Folder permission from ls -l returns d---------


I am trying to do an rsync backup of my server. There are several users who store their files on the server.

My user is a sudoer (can use sudo). So I run rsync with sudo so that I can backup everything from all the users.

However, I have noticed that rsync gives some errors on directories that have a permission of d---------

Why do those folders have that permission? Also, why can't my sudo rsync command get those files and folders? If I open my file manager with sudo, it is able to browse into those folders and see all the files.

-Thanks
 
Old 07-07-2014, 01:55 PM   #2
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Quote:
Originally Posted by xmrkite View Post
Why do those folders have that permission?
Post the exact rsync command please.
Is the destination a mount, or a network resource (cifs, sshfs, etc)?
 
Old 07-07-2014, 01:59 PM   #3
baldur_1
Member
 
Registered: Sep 2010
Posts: 275

Rep: Reputation: 28
that is an odd permission on a folder. the permission d---- means it is a directory with no permission. in that case i believe the only one with access is root. i believe sudo can also but i am not sure that a program run with sudo would be able to. if you are getting an error then i would say that is definitely a permission issue, that it is not able to access that folder.

to remedy this, you need to set permissions so that you have access to that folder. here is a breakdown of what you need to do...

ChMOD

reading that will help you understand what you are doing. for instance, as root of via sudo you would want to run something like sudo chmod -R 755 /yourfoldername so that will give root full access and everyone else (users and whoever) would get read/execute access to the directory.
 
Old 07-07-2014, 02:04 PM   #4
xmrkite
Member
 
Registered: Oct 2006
Location: California, USA
Distribution: Mint 16, Lubuntu 14.04, Mythbuntu 14.04, Kubuntu 13.10, Xubuntu 10.04
Posts: 554

Original Poster
Rep: Reputation: 30
Ok, my script is:

rsync -azvr --no-p --no-g --chmod=ugo=rwX --delete --max-size=2048m --exclude='.Trash-0' --exclude='backintime' --exclude='guest' --exclude='lost+found' --exclude='Public' /media/md2r5/ -e ssh me@myipaddress:/home/myuserfolder/Backup

I recently added the "--no-p --no-g --chmod=ugo=rwX" to see if that'd fix it but it did not.

I use cwrsync to rsync over ssh from windows to the ubuntu server, and then this script above to backup one ubuntu server to my offsite one.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
File & Folder Permission and Ownership permission error in Cloud storage. rhcekumaran Linux - Newbie 3 06-14-2013 04:41 AM
[SOLVED] folder Permission 9199 Linux - Newbie 6 08-09-2012 10:09 AM
TFTP server returns "Error Code 0: Permission Denied" gi99 Linux - Networking 2 04-19-2011 06:17 AM
nfs server - sharing folder - folder permission dlugasx Linux - Server 1 02-15-2011 12:30 AM
Folder permission javamdk Slackware 9 07-07-2004 11:26 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:24 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration