Рет қаралды 41,807
In this lecture on Program for Inter Process Communication using Message Queues, you will learn how processes can communicate using message queues in Linux using C programming. Message queues are almost similar to named pipes with the exception that they do not require the opening and closing of pipes. But, they face one similar problem like named pipes; blocking on full pipes. Message queues send blocks of data from one process to another.
There are 4 important functions that we will use in the programs to achieve IPC using message queues
int msgget(key_t key, int msgflg);
int msgsnd(int msqid, const void *msg_ptr, size_t msg_sz, int msgflg);
int msgrcv(int msqid, void *msg_ptr, size_t msg_sz, long int msgtype, int msgflg);
int msgctl(int msqid, int command, struct msqid_ds *buf);
Subscribe - / dextutor
This lecture is part of the Operating System Lab playlist: • Operating System Lab
For Program code and more details visit: dextutor.com/p...
Reference Videos for Inter Process Communication:
1. IPC using pipe(): • Program for Inter-Proc...
2. IPC using named pipes: • Program for Inter-Proc...
3. IPC using Shared memory: • Program for Inter-Proc...
4. IPC using message queues: • Program for Inter Proc...
5. IPC using popen: • Program for Inter-Proc...
Tools Required:
1. Linux environment
2. Basic knowledge of C Language
3. gcc compiler installed
Reference Links:
Operating System Theory PPTs Link: dextutor.com/c...
Operating System Programs: dextutor.com/c...
Other Playlists:
OS: • Operating System
Linux Essential: • Linux Tutorial For Beg...
RHCSA: • RHCSA Exam Questions |...
Was this tutorial about Program for IPC using message queues helpful? If so, please share. Let me know your thoughts in the comments.
#linux #oslab #os #dextutor #ipc