UNIX newbie here

I have an access to the school solaris OS. I have my own directory and i want to deny an access to my directory to anyone except me of course and the admin. I want to do that because i can access other people's directory and i can see their files and they can see my files. Thanks in advance
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

brettmjohnsonConnect With a Mentor Commented:

Depending upon your primary group affiliation, other group members might still be able to read the directory.
To deny other group  members access, you would remove that right as well:

chmod g-r mydir

The admin would have superuser privileges, allowing unrestricted access to the directory.

man chmod

specifically  chmod o-r mydir

Carl3003Author Commented:
chmod o-r mydir- this means that only the admin can read mydir?
yuzhConnect With a Mentor Commented:
chmod 700 mydir

this will only allow you to access to your dir (the super user root is the god of the system
he can still do whatever he want)
man chmod
to learn more details.
Carl3003Author Commented:
cool, i am getting there...
All Courses

From novice to tech pro — start learning today.