Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Copy vs. Move and File Permissions Changing

1 view
Skip to first unread message

Mike Fitzpatrick

unread,
Mar 10, 1997, 3:00:00 AM3/10/97
to

Can anyone explain why NT keeps a file's permissions when moved and
changes them when copied. As a Netware guy, I find this odd. This
doesn't happen with Netware.

Is there a way to force the directories permissions on a file,
regardless of how the file is transfered to the directory?

Thanks all,

M

J. David Bryan

unread,
Mar 11, 1997, 3:00:00 AM3/11/97
to

On Mon, 10 Mar 1997 17:52:35 -0800 in article <3324BA...@slip.net>,
MF...@slip.net wrote...

>
>Can anyone explain why NT keeps a file's permissions when moved and
>changes them when copied.

I believe it's because there are *file* permissions and *directory*
permissions. When you move, the file permissions travel with the file. When
you copy, a new file is first created in the directory, inheriting by
default the permissions from the directory.

See also Microsoft KnowledgeBase article Q102024, titled "File Permissions
Inherited from Directory When Copied" at:

http://www.microsoft.com/kb/articles/q102/0/24.htm


>Is there a way to force the directories permissions on a file,
>regardless of how the file is transfered to the directory?

Don't think so.

--
-- Dave Bryan
dbr...@mail.bcpl.lib.md.us


David C. Miller

unread,
Mar 12, 1997, 3:00:00 AM3/12/97
to

I hate to follow-up my own posts, however I did not see the second question
until I was reading my post. If you want to force the new directories
permissions on the files, copy the files to the new location and then
delete then from the source. If you want to keep the file permissions
intact when coping the files you will need the scopy utility from the
resource kit. It will copy files with permissions intact.
Enjoy!
--
+-------------------------------------------------------------------+
| David C. Miller - KB7ZJY - Renton, WA USA |
| Microsoft Certified Systems Engineer |
| Home - dav...@wolfenet.com - Work - dav...@microsoft.com |
| The opinions expressed in this message are my own. |
| Check out http://www.wolfenet.com/~davidmi |
|In order to prevent spamming I have added a $ to my e-mail address |
| Remove the $ prior to replying to this message. |
+-------------------------------------------------------------------+

David C. Miller <$dav...@microsoft.com> wrote in article
<01bc2e81$bd828e00$aaa4369d@davidmi1>...
> There are a number of circumstances that can occur when coping and moving
> files:
> 1. Move files from one location to another on the same partition. The
> permissions will remain the same for the files. This is because the files
> do not move, the directory entries are just changed to reflect the new
> location in the file hierarchy.
>
> 2. Move files from one location to another on a different logical or
> physical drive. The permissions of the files in the new location are
> inherited from the new folder. This is because the files are not really
> moved, they are copied to the new location and then deleted from the
> source.
>
> 3. Copy the files to another location. Again the new files will inherit
the
> permissions from the new location. The file attributes are not copied,
only
> the file is copied.
>
> This information also applies to the compression attribute of a file as
> well.
>
> I hope this helps!
> --
> +-------------------------------------------------------------------+
> | David C. Miller - KB7ZJY - Renton, WA USA |
> | Microsoft Certified Systems Engineer |
> | Home - dav...@wolfenet.com - Work - dav...@microsoft.com |
> | The opinions expressed in this message are my own. |
> | Check out http://www.wolfenet.com/~davidmi |
> |In order to prevent spamming I have added a $ to my e-mail address |
> | Remove the $ prior to replying to this message. |
> +-------------------------------------------------------------------+
>
> J. David Bryan <dbr...@mail.bcpl.lib.md.us> wrote in article
> <5g2vi8$4tv$3...@news.abs.net>...

David C. Miller

unread,
Mar 12, 1997, 3:00:00 AM3/12/97
to
0 new messages