Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Other *NIX Forums > Solaris / OpenSolaris
User Name
Solaris / OpenSolaris This forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.


  Search this Thread
Old 07-21-2006, 06:36 AM   #1
LQ Newbie
Registered: Feb 2006
Posts: 5

Rep: Reputation: 0
help req in chown command

hi friends
I want t change the ownership of all files owned by a user harry on a folder /access to another user abhijeet. But the folder contains files owned by many other users also which I dont want to disturb..
Can any one help me with the chown command..

Now I am changing the ownership of files one by one using the command "chown abhijeet /access/stage12*

VishnuPrasad Chaurasia
Old 07-21-2006, 07:05 AM   #2
spirit receiver
Registered: May 2006
Location: Frankfurt, Germany
Distribution: SUSE 10.2
Posts: 424

Rep: Reputation: 33
The find command should do the trick. Note that it will also examine subdirectories of /access, use find's -maxdepth switch to prevent this.
find /access -type f -user harry -exec chown abhijeet '{}' \;


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
!!!! Urgent, using chown command ? AQG Linux - Security 8 08-12-2005 03:21 PM
permissions messed up chown command used tsayles21 Debian 3 03-30-2004 08:38 PM
I Have a problem with the CHOWN command AnnePeter Linux - Software 5 03-12-2004 07:37 AM
So... I used Chown command and screwed my pc... Nosram Linux - Newbie 3 01-20-2004 06:09 AM
chown command help ksgill Linux - Newbie 9 04-28-2003 10:52 PM > Forums > Other *NIX Forums > Solaris / OpenSolaris

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

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