Operating System - HP-UX
1847355 Members
3631 Online
110264 Solutions
New Discussion

what is "s" in front of a file perms ?

 
SOLVED
Go to solution
Sammy_2
Super Advisor

what is "s" in front of a file perms ?

I found this under /tmp. The file has s in front of all the perms. Also have some other files in /var/tmp with s in front of it ? What's that ?
By the way, this is solaris 9 but I am guessing this is a unix thing and not vendor specific.

srwxrwxrwx 1 root root 0 Mar 18 14:00 portal
good judgement comes from experience and experience comes from bad judgement.
4 REPLIES 4
Jeff Schussele
Honored Contributor
Solution

Re: what is "s" in front of a file perms ?

Hi Sam,

IF it's the very 1st character, then it denotes the file is a socket.

Rgds,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Geoff Wild
Honored Contributor

Re: what is "s" in front of a file perms ?

The s designates a socket bound to a name.

If it was a p - then it would be a pipe.

Rgds...Geoff

Proverbs 3:5,6 Trust in the Lord with all your heart and lean not on your own understanding; in all your ways acknowledge him, and he will make all your paths straight.
Marvin Strong
Honored Contributor

Re: what is "s" in front of a file perms ?


Straight from the ls man page:

The first character indicates the entry type:

b Block special file
c Character special file
d Directory
l Symbolic link
n Network special file
p Fifo (also called a "named pipe") special file
s Socket
- Ordinary file

Sammy_2
Super Advisor

Re: what is "s" in front of a file perms ?

thanks. Was little confused as I had never seen that. But now, I am clear.
good judgement comes from experience and experience comes from bad judgement.