How to know whether the message queue is empty or not.



How to know whether the message queue is empty or not...

Answer / pavan

type the command: ipcs -m

you'll get no of messages in Message Q,

else
you can also use msqid_ds structure

i'e : define a structure variable of type
-> struct msqid_ds YOUR_VAR;
and access YOUR_VAR -> msg_qnum
it'll give no of messgaes on Q.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Unix IPC Interview Questions

What are various IDs associated with a process?

4 Answers  


Tell me set-user-id is related to (in unix)?

0 Answers  


what is the process id for kernel process?

8 Answers   IBM, ITI, Military Engineer Services, Remo, TATA,


About i-node numbers

1 Answers  


Max relax-able permission value with out giving write permission to others?

0 Answers  






What is i-node numbers?

0 Answers  


What is Inode.

2 Answers   HCL,


Explain what is the process id for kernel process?

0 Answers  


How to write the program on full-duplex communication using 2 FIFOs

0 Answers  


What is the very first process created by kernel?

0 Answers  


what is the condition required for dead lock in unix sustem ?

2 Answers  


what about the initial process sequence while the system boots up?

1 Answers  


Categories