Explain Berkeley Socket
The eduladder is a community of students, teachers and programmers just interested to make you to pass any exams. So we solve previous year question papers for you.
See Our team
Wondering how we keep quality?
Got unsolved questions?

Ask Questions

Use Me  ?

New searches
Cloud-Computing-14SCS12-VTU-unit-1-->View question

Explain Berkeley Socket Algorithm.

Related to computer networks.


By:Purnima

Taged users:
|mmodi1995

Likes:
|milan-ransingh|leo

Dislikes:
Be first to dislike this question
Talk about thisDelete|Like|Dislike|


Answers

Berkeley Socket:

  1. Berkeley sockets is an application programming interface (API) for Internet sockets and UNIX domain sockets.
  2. It is used for inter-process communication (IPC).
  3. It is commonly implemented as a library of linkable modules.
  4. It originated with the 4.2BSD UNIX released in 1983.

Primitive used in Berkeley Socket:

enter image description here

Socket Programming:

I) Server side:

1. Server startup executes SOCKET, BIND & LISTEN primitives.

2. LISTEN primitive allocate queue for multiple simultaneous clients.

3. Then it use ACCEPT to suspend server until request.

4. When client request arrives: ACCEPT returns.

5. Start new socket (thread or process) with same properties as original, this handles the request, server goes on waiting on original socket.

6. If new request arrives while spawning thread for this one, it is queued.

7. If queue full it is refused.

II) Client side:

1. It uses SOCKET primitives to create.

2. Then use CONNECT to initiate connection process.

3. When this returns the socket is open.

4. Both sides can now SEND, RECEIVE.

5. Connection not released until both sides do CLOSE.

6. Typically client does it, server acknowledges.


harshshah822

Likes:
Be first to like this answer

Dislikes:
Be first to dislike this answer
Talk about this|Once you have earned teacher badge you can edit this questionDelete|Like|Dislike|
------------------------------------

Can you help us to add better answer here? Please see this



Not the answer you're looking for? Browse other questions from this Question paper or ask your own question.

Eduladder magazine is out there subscribe!