Set permissions recursively on Windows 7
I've just recently installed Windows 7, and I'm trying to set up a network share to be accessible by everyone on my (home) network. I'm used to XP, so it's taking me a little while to get used to the new way of sharing folders and setting permissions in 7.
So far, I have been able to:
- share a directory on the network
- change permissions on the directory so that users can actually see the contents
Now my problem is that every file in the directory is viewable, but not readable to network users. From my other machine I can see that the file exists, but when I try to copy it, I get a permissions error.
Is there a way to open the permissions on all the files in a directory to be readable by everyone?
So far I have only found a way to do it one file at a time, and that's just awful. In unix terms, I want all the directories to be 755, and all the files to be 644. How can I do this recursively?
Solution 1:
Here's how I was able to do it:
- right-click on the directory, go to Properties
- Security tab, Advanced..
- Permissions tab, Change Permissions...
- Add...
- Advanced...
- click Find Now, then find and click on "Everyone", click OK
- click OK
- "Everyone" should now show up in the list, with "Read & execute" permissions
- check the box for "Replace all child object permissions with inheritable permissions from this object"
- click OK. That should recursively give read access to "Everyone".
Solution 2:
From the GUI multi-select the files/folders you want to change. Right click and select Properties. Make your changes and if/when you are asked if you wish to apply the change to all folders and sub-folders click appropriately.
From the command line use the attrib command with the /r switch. Wildcards are accepted by attrib. Enter attrib /? for more information.