Re: sticky bit on files?

From: Horst von Brand (vonbrand@inf.utfsm.cl)
Date: Wed Jul 26 2000 - 15:51:49 EST


Sandy Harris <sandy@storm.ca> said:
> Marc Lehmann wrote:
> > Linux does not have swap space (it does paging, which technically is not
> > the same as swapping processes out), so the concept of the sticky bit
> > makes no sense.

> Sure it makes sense.

> A program loads, runs and terminates. The OS of course recovers the
> process' data space. If the bit is unset, it recovers the code space
> as well.

It does so anyway.

> If the bit is set, it should be keeping the program code in memory
> (possibly paging it out, but that is irrelevant) unless/until it
> has some other urgent need for that memory.

The executable is paged directly from the file, not from paging space. The
bits of the file that are in memory will stay around if the memory isn't
needed for something else. So, in essence, _all_ executables have 't's
advantages (sort of).

-- 
Dr. Horst H. von Brand                       mailto:vonbrand@inf.utfsm.cl
Departamento de Informatica                     Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria              +56 32 654239
Casilla 110-V, Valparaiso, Chile                Fax:  +56 32 797513
-- 
Dr. Horst H. von Brand                       mailto:vonbrand@inf.utfsm.cl
Departamento de Informatica                     Fono: +56 32 654431
Universidad Tecnica Federico Santa Maria              +56 32 654239
Casilla 110-V, Valparaiso, Chile                Fax:  +56 32 797513

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Jul 31 2000 - 21:00:22 EST