Linux/UNIX: chmod error

Posted on in Categories , last updated September 1, 2006

Q: Sometime when I use chmod command under Suse Linux, I am getting following error message:
changing permissions of ‘FILENAME’: Operation not permitted

A: If you are using UNIX you will get error as follows:
chmod: Not owner.

Remember, only the owner of a file or directory can set its permissions. Use ls -l to find the owner. Otherwise, login in as a root user and then setup permissions using chmod.

See also:

Posted by: Vivek Gite

The author is the creator of nixCraft and a seasoned sysadmin, DevOps engineer, and a trainer for the Linux operating system/Unix shell scripting. Get the latest tutorials on SysAdmin, Linux/Unix and open source topics via RSS/XML feed or weekly email newsletter.

Share this on (or read 2 comments/add one below):

2 comment

  1. How can I change the permission of a complete directory.
    chmod -R perm dir-name

    how can i remove the whole directory
    /bin/rm -rf dirname

    Have a question? Post it on our forum!