From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fee84,ef07fdae495b5c3f X-Google-Attributes: gidfee84,public From: Timo Felbinger Subject: Re: chmod on link? Date: 1998/12/09 Message-ID: #1/1 X-Deja-AN: 420387242 References: <366E3AEE.4D39123B@vsb.cz> To: ivan.dolezal@vsb.cz Content-Type: TEXT/PLAIN; charset=US-ASCII Organization: University of Potsdam Mime-Version: 1.0 Reply-To: Timo.Felbinger@quantum.physik.uni-potsdam.de Newsgroups: comp.unix.osf.osf1 On Wed, 9 Dec 1998 ivan.dolezal@vsb.cz wrote: > I got a really dumb question: if I create a soft link, its permission is > lrwxrwxrwx . > > How can I change it? You can't. Links don't have any permissions, only files and other things like devices and pipes which are represented by inodes, have. An inode is a data structure containing vital data describing the file, including permissions, owner, ... When you use a link, the permissions of the file pointed to will apply. While ls will display the permissions of the file associated with a hard link, it will always show lrwxrwxrwx for soft links. Simple experiment: If a file has more than one hard link, ls will display identical permissions (as well as ownership, access time, ...) for all of them. -- Timo Felbinger (Timo.Felbinger@quantum.physik.uni-potsdam.de) Quantum Physics Group Institute of Physics University of Potsdam, Germany