/ Forside / Teknologi / Operativsystemer / Linux / Nyhedsindlæg
Login
Glemt dit kodeord?
Brugernavn

Kodeord


Reklame
Top 10 brugere
Linux
#NavnPoint
o.v.n. 11177
peque 7911
dk 4814
e.c 2359
Uranus 1334
emesen 1334
stone47 1307
linuxrules 1214
Octon 1100
10  BjarneD 875
ls
Fra : Jan Larsen


Dato : 19-09-03 20:42

Hej

Hvis jeg med ls for dette....

-rwxrwxrwt 1 root root 1 2003-09-19 18:51 test.txt

Hvad betyder 't' så ?

-rwxrwxrwt 1 root root 1 2003-09-19 18:51 test.txt
^

/Jan

 
 
Michael Lyngbøl (19-09-2003)
Kommentar
Fra : Michael Lyngbøl


Dato : 19-09-03 21:02

On Fri, 19 Sep 2003 21:41:58 +0200, Jan Larsen wrote:
> Hej
>
> Hvis jeg med ls for dette....
>
> -rwxrwxrwt 1 root root 1 2003-09-19 18:51 test.txt
>
> Hvad betyder 't' så ?
>
> -rwxrwxrwt 1 root root 1 2003-09-19 18:51 test.txt

Sticky bit.

På moderne UNIX har sticky bit ikke noget at sige hvis sat på fil (som i
dit eksempel):

STICKY FILES
On older Unix systems, the sticky bit caused executable files to be hoarded
in swap space. This feature is not useful on modern VM systems, and the
Linux kernel ignores the sticky bit on files. Other kernels may use the
sticky bit on files for system-defined purposes. On some systems, only the
superuser can set the sticky bit on files.

I praksis er det rart på directories som fx. /tmp:

STICKY DIRECTORIES
A directory whose `sticky bit' is set becomes an append-only directory,
or, more accurately, a directory in which the deletion of files is
restricted. A file in a sticky directory may only be removed or renamed
by a user if the user has write permission for the directory and the user
is the owner of the file, the owner of the directory, or the super-user.
This feature is usefully applied to directories such as /tmp which must
be publicly writable but should deny users the license to arbitrarily
delete or rename each others' files.

--
Michael Lyngbøl -- Opinions are mine[TM];
ZX-9R

Jan Larsen (19-09-2003)
Kommentar
Fra : Jan Larsen


Dato : 19-09-03 21:14

Michael Lyngbøl wrote:

> On Fri, 19 Sep 2003 21:41:58 +0200, Jan Larsen wrote:
>> Hej
>>
>> Hvis jeg med ls for dette....
>>
>> -rwxrwxrwt 1 root root 1 2003-09-19 18:51 test.txt
>>
>> Hvad betyder 't' så ?
>>
>> -rwxrwxrwt 1 root root 1 2003-09-19 18:51 test.txt
>
> Sticky bit.
>
> På moderne UNIX har sticky bit ikke noget at sige hvis sat på fil (som i
> dit eksempel):
>
> STICKY FILES
> On older Unix systems, the sticky bit caused executable files to
> be hoarded
> in swap space. This feature is not useful on modern VM
> systems, and the
> Linux kernel ignores the sticky bit on files. Other kernels may
> use the
> sticky bit on files for system-defined purposes. On some
> systems, only the superuser can set the sticky bit on files.
>
> I praksis er det rart på directories som fx. /tmp:
>
> STICKY DIRECTORIES
> A directory whose `sticky bit' is set becomes an append-only
> directory, or, more accurately, a directory in which the deletion of
> files is
> restricted. A file in a sticky directory may only be removed or
> renamed by a user if the user has write permission for the directory
> and the user is the owner of the file, the owner of the directory, or
> the super-user. This feature is usefully applied to directories such
> as /tmp which must be publicly writable but should deny users the
> license to arbitrarily delete or rename each others' files.
>
Takker.

/Jan

Søg
Reklame
Statistik
Spørgsmål : 177560
Tips : 31968
Nyheder : 719565
Indlæg : 6408952
Brugere : 218888

Månedens bedste
Årets bedste
Sidste års bedste