Windows XP有几种共享文件夹的方法,处理(Windows XP)NTFS权限和共享(Share)权限总是有点混乱。现在在Windows 7中,它更加混乱!是的,那是因为他们现在有家庭组(Homegroups),您可以与家庭组共享文件,这与与世界其他地方的共享是分开的。
无论如何,如果您设法共享了一个文件夹,然后决定有一天将其删除,您可能已经注意到您之前共享的文件夹上有一个奇怪的锁定图标。它看起来像这样:
我发现这真的很烦人,因为以前在Windows XP中从来没有这个问题,我什至不知道锁图标是什么意思。我要做的就是删除共享,而不是锁定文件夹。经过一番阅读,我了解到当您在Windows 7中共享文件夹时,该文件夹不再继承父文件夹的权限,因此会出现锁定图标。我发现这非常令人困惑,而且我自己绝对不会弄清楚!
在我讨论如何重置文件夹的权限以使锁定图标消失之前,让我先看看它是如何出现的。如果您不在乎,您可以直接跳到从文件夹(Folder)标题中删除锁定图标。(Remove Lock Icon)如果您右键单击该文件夹,您将看到一个共享(Share With)选项:
如果您选择家庭组(Homegroup)( Read ) 或家庭组(Homegroup)( Read/Write ),那么您的文件夹将自动在家庭组内共享。现在,当您尝试摆脱共享时,就会出现问题。没有选择只删除共享!相反,您必须选择None(Nobody),从图标中可以看出,它会在文件夹中添加一个大锁图标。
现在,您可以共享的另一种方法是右键单击文件夹并转到Properties。如果您进入共享(Sharing)选项卡,您将看到两个选项:网络文件和文件夹共享( Network File and Folder Sharing)以及高级共享(Advanced Sharing)。
单击顶部的“共享(Share)”按钮与在上面的屏幕截图中选择“共享(Share with )”时选择“特定人员(Specific People )”几乎相同。
您可以输入名称,也可以从“所有人”或“家庭组(Homegroup)”中进行选择。同样(Again),要删除共享,别无选择。您只需从下面的列表框中删除人员或组。同样(Again),在您这样做的那一刻,锁定图标就会出现。
最后一个选项,从“共享(Sharing)”选项卡中选择“高级共享(Advanced Sharing )”是唯一不会让您获得锁定图标的方法。单击(Click)高级共享(Advanced Sharing),然后单击共享此文件夹(Share this folder )复选框。
现在,如果您退出并返回同一对话框并取消选中该框,则锁定图标不会出现在文件夹上方!耶!因此,如果您不想完全担心锁定图标,您应该使用Advanced Sharing共享一个文件夹。无论如何(Anyway),如果你已经有锁图标,你如何摆脱它?
从文件夹中删除锁定图标
现在要将权限恢复到共享文件夹之前的状态,您需要右键单击文件夹并选择Properties。然后,您需要单击“安全(Security)”选项卡。是的安全(Security)选项卡,而不是共享(Sharing)选项卡。
然后,您需要单击Advanced按钮并单击Change Permissions。
接下来,您需要选中包含此对象父级的可继承权限的框。( Include inheritable permissions )
然后,您需要单击确定(OK)三次以返回资源管理器(Explorer)主界面。您会注意到文件夹上的锁定图标现在消失了。但是,您还没有完成。现在您需要再次返回同一个对话框——右键单击,选择Properties,单击Security选项卡,单击Advanced,然后单击Change Permissions。现在你需要做的是删除任何在继承自(Inherited From)列下显示的<not inherited>
选择该行,然后单击“删除(Remove)”按钮。只去掉没有继承(not inherited)列出的行。这里的所有都是它的。现在,您的文件夹将拥有共享之前的正常权限,并且锁定图标将消失!有点(Kind)麻烦的过程,但那是Windows!享受!
Remove Lock Icon on Folder in Windows 7
Windows XP had a fеw ways to shаre a folder and it wаs alwayѕ a little confusing dealing with NTFS permissions and Share permissions. Now in Windows 7, it’s even more confusing! Yes, that’s because they now have Homеgroups and you can share files with a homegroup, which is separate from sharing with thе rest of the world.
Anyway, if you managed to get a folder shared and then decided to remove it one day, you may have noticed a strange lock icon on the folder that you previously had shared. It looks something like this:
I found this really irritating because there was never this issue before in Windows XP and I didn’t even know what the lock icon meant. All I want to do is remove the share, not lock the folder. After doing some reading, I learned that when you share a folder in Windows 7, the folder no longer inherits permissions from the parent folder and therefore the lock icon appears. I find this very confusing and something I definitely would not have figure out on my own!
Before I go into how to reset the permissions on the folder so that the lock icon disappears, let me go through how it appears in the first place. If you don’t care, you can just skip down to the Remove Lock Icon from Folder heading. If you right click on the folder, you’ll see an option to Share With:
If you choose Homegroup (Read) or Homegroup (Read/Write), then your folder will automatically be shared within just the homegroup. Now the problem occurs when you try to get rid of the share. There is no option to just remove the share! Instead, you have to choose Nobody, which as you can see from the icon, adds a big fat lock icon to the folder.
Now the other way you can share is by right clicking on the folder and going to Properties. If you go the Sharing tab, you’ll see two options: Network File and Folder Sharing and Advanced Sharing.
Clicking on the Share button at the top is pretty much the same as choosing Specific People when choosing Share with in the screenshot above this one.
You can type in a name or you can choose from Everyone or Homegroup. Again, to remove the share, there is no option. You simply have to remove people or groups from the list box below. Again, the instant you do that, the lock icon appears.
The last option, to choose Advanced Sharing from the Sharing tab is the only method that will not get you the lock icon. Click on Advanced Sharing and then click on the Share this folder checkbox.
Now if you exit out and come back to the same dialog and uncheck the box, the lock icon does not appear over the folder! Yay! So if you want to not have to worry about the lock icon at all, you should share a folder using Advanced Sharing. Anyway, if you already have the lock icon, how do you get rid of it?
Remove Lock Icon from Folder
Now to get the permissions back to the way they were before you shared the folder, you need to right-click on the folder and choose Properties. Then you need to click on the Security tab. Yes the Security tab, not the Sharing tab.
Then, you need to click on the Advanced button and click on Change Permissions.
Next, you need to check the box that says Include inheritable permissions from this object’s parent.
Then, you need to click OK three times to get back to the main Explorer interface. You’ll notice that the lock icon on the folder is now gone. However, you are not done yet. Now you need to go back to the same dialog again – right-click, choose Properties, click on Security tab, click on Advanced, and click on Change Permissions. Now what you need to do is remove anything that says <not inherited> under the Inherited From column.
Select the row and then click on the Remove button. Only get rid of the rows that have not inherited listed. That’s all there is to it. Now your folder will have the normal permissions it had before you shared it and the lock icon will be gone! Kind of a cumbersome process, but that’s Windows! Enjoy!