:


Unix

, 96,

UNIX - Multics

, ,

IPC

:

shmget

shmat

shmdt

shmctl ,

,

shmid = shmget(key, size, flag);

virtaddr = shmat(id, addr, flags);

shmdt(addr);

shmctl(id, cmd, shsstatbuf);

UNIX:

:

id = semget(key, count, flag);

oldval = semop(id, oplist, count);

oplist:

(1)

(2)

semop

IPC_NOWAIT UNIX

semctl(id, number, cmd, arg);

:

msgqid = msgget(key, flag);

-

:

,

msgsnd(msgqid, msg, count, flag);

:

() ,

count = msgrcv(id, msg, maxcount, type, flag);

type

type

type

, type

msgctl(id, cmd, mstatbuf);

pipe(fdptr);

( )

open

: read write

: close

(sockets)

,

:

:

"-"

, ,

:

:

"-"

:

sd = socket(domain, type, protocol);

()

close(sd)

:

bind(sd, socknm, socknlen);

-:

connect(sd, socknm, socknlen);

, - :

listen(sd, qlength);

- accept:

nsd = accept(sd, address, addrlen);

:

count = send(sd, msg, length, flags);

count = recv(sd, buf, length, flags);

send:

recv:

send recv read write

:

count = sendto(sd, msg, length, flags, socknm, socknlen);

count = recvfrom(sd, buf, length, flags, socknm, socknlen);

:

shutdown(sd, mode);

shutdown close:

(streams)

UNIX System V

TLI

ISO/OSI


Last-modified: Thu, 28 May 1998 14:33:09 GMT
: