Change Group Ownership of Symbolic Links in Unix or Linux

chgrp can be used to change group ownership of files and directories in almost all UNIX-variant platforms, including Linux such as Fedora Core, Ubunto and etc. However, if you try to change the group membership of a symbolic link, the group ownership of its referenced or linked file is changed instead.

This is the default behavior of chgrp command, where dereference option is used by default so that all changes will affect the referent of each symbolic link, rather than the symbolic link itself.

To change the group ownership of symbolic link, simply use the -h or –no-dereference flag to the chgrp command.

Example:

chgrp -h new_group symbolic_link_name

One Response to “Change Group Ownership of Symbolic Links in Unix or Linux”

  1. Lars
    January 17th, 2009 08:34
    1

    Thanks for the tip. I was always frustrated by not being able to change the ownership of symlinks. Definitely good to know.

Leave a Reply

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Subscribe to comments feature has been disabled. To receive notification of latest comments posted, subscribe to My Digital Life Comments RSS feed or register to receive new comments in daily email digest.

New Articles

Incoming Search Terms for the Article

change owner of symbolic link - change owner symbolic link - change ownership of symbolic link - change ownership symbolic link - change ownership of symlink - change symlink owner - change symbolic link owner - linux change owner of symbolic link - linux change link owner - linux change symbolic link owner - change the owner of a symbolic link - symbolic links owner - change owner of symlink - changing owner of symbolic link - linux change owner symbolic link - how to change owner of symbolic link - change synbolic link owner - linux symbolic link change owner - symlink changing group - change owner soft link - change permission on link unix - changing ownership of symbolic link - how to change ownership of symlink - change owner link - change ownership link - how to change owner group fedora - symbolic link change owner - symbolic link owner - changing group on AIX - change link owner - how to set unix permissions on symbolic links - symlink owner - changing owner of a symbolic link in linux - change ownership of the link linux - change owner symlink - create symbolic link with owner group - linux change symlink owner - symbolic link owner change - change ownership of a symlink in linux - change group owner of linux symbolic link - changing ownership of a symbolic libnk - linux change owner of link - linux change group symlink - unix change owner of a soft link - change group in AIX - owner of a symbolic link - setting symlink owner - change ownership on symbolic link - linux how to change permission for links - unix change permission link -