Cool Solutions

Change File/Directory owner


August 22, 2005 4:54 am





Download chngownr

What it does:

  • Change File Directory owner for all Dir/files from current ant below.
  • Can change from UNKNOWN OWNER.
  • Can work with RUSSIAN File/Directory names.

Information about limitations:

  1. This script uses VFS (virtual file system). As a result – this script will work only with NetWare, where supported VFS.
    (NW6. NW6.5)
  2. This script tested only with NSS-volume
  3. This script does not use UCS/UCX
    (maybe this is good. I use VFS for get directory quota.)

How to Step by Step:

1. unpack to sys:\perl\scripts\

If your need change File/Dir owner as:

from vol1:\wrk\deps and below
from owner: .user1.org1.ogo to .owner .user3.ogo

run this script as:
(ATTANTION: in this example your tree has name: TESTREE)

perl sys:\perl\scripts\ vol1:wrk\deps .cn=user1.ou=org1.o=ogo.t=testtree. .cn=user3.o=ogo.t=testtree.

if you need LOG ALL FILES/DIR for changed OWNER, run as:

perl sys:\perl\scripts\ vol1:wrk\deps .cn=user1.ou=org1.o=ogo.t=testtree. .cn=user3.o=ogo.t=testtree. > sys:\result.txt

if you need change OWNER from UNKNOWN (old owner was deleted), run as:
perl sys:\perl\scripts\ volume:dir\dir1 “unknown user” .cn=user3.o=ogo.t=testtree.

0 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 5 (0 votes, average: 0.00 out of 5)
You need to be a registered member to rate this post.
Loading ... Loading ...

Categories: Uncategorized

Disclaimer: This content is not supported by Novell. It was contributed by a community member and is published "as is." It seems to have worked for at least one person, and might work for you. But please be sure to test it thoroughly before using it in a production environment.