EmbLogic's Blog

ipc using message queue and semaphores

rcs: warning: No options were given; this usage is obsolescent.
rcs: RCS/server.c,v: No such file or directory
[root@(none) ipc_project]# rcs -i server.c
RCS file: server.c,v
enter description, terminated with single ‘.’ or end of file:
NOTE: This is NOT the log message!
>> included all the header files that will be used in the code
>> defined struct data and struct sembuf
>> .
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v ./server.c
revision 1.1 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > got the kernel key using msgget()
>> checked the accessibility of the file
>> using access(0
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.2 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > created a fifo between client,server and server,process
>> opened the file in write only mode in the requesting client
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.3 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v ./server.c
revision 1.3 (locked)
done
co: RCS/co,v: No such file or directory
co: -l option is ignored after filenames
co: -r1.3 option is ignored after filenames
./server.c,v –> ./server.c
revision 1.3 (locked)
writable ./server.c exists; remove it? [ny](n): y
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v ./server.c
revision 1.3 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > now,using semop(),decremented the u.value,making the other processes wait while request client is writing
>> in the server side,reading the data and again incrementing the u.value
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.4 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > closed the fifo
>> gave the gave the m.type
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.5 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > opened the fifo in write onlu mode
>> decremented the u.value
>> wrote data from server to process
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.6 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > read the data in the process side
>> incremented the u.value
>> processed the data
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.7 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > closed the fifo
>> decremented the u.val
>> wrote data to server
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.8 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > read the data in server
>> incremented the u.val
>> closed the fifo
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.9 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > stored the result in r.result
>> opened the client server fifo
>> send the data using msgsnd()
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.10 (locked)
done
[root@(none) ipc_project]# ci ./server.c
./server.c,v > receieved the data in client side using msgrcv()
>> displayed the data
>> closed the fifo
>> .
done
[root@(none) ipc_project]# co -l ./server.c
./server.c,v –> ./server.c
revision 1.11 (locked)
done
[root@(none) ipc_project]# rlog ./server.c

RCS file: ./server.c,v
Working file: ./server.c
head: 1.11
branch:
locks: strict
root: 1.11
access list:
symbolic names:
keyword substitution: kv
total revisions: 11; selected revisions: 11
description:
included all the header files that will be used in the code
defined struct data and struct sembuf
—————————-
revision 1.11 locked by: root;
date: 2014/11/14 09:06:43; author: root; state: Exp; lines: +1 -1
receieved the data in client side using msgrcv()
displayed the data
closed the fifo
—————————-
revision 1.10
date: 2014/11/14 09:05:04; author: root; state: Exp; lines: +1 -1
stored the result in r.result
opened the client server fifo
send the data using msgsnd()
—————————-
revision 1.9
date: 2014/11/14 09:03:39; author: root; state: Exp; lines: +1 -1
read the data in server
incremented the u.val
closed the fifo
—————————-
revision 1.8
date: 2014/11/14 09:02:39; author: root; state: Exp; lines: +1 -1
closed the fifo
decremented the u.val
wrote data to server
—————————-
revision 1.7
date: 2014/11/14 09:00:14; author: root; state: Exp; lines: +1 -1
read the data in the process side
incremented the u.value
processed the data
—————————-
revision 1.6
date: 2014/11/14 08:54:46; author: root; state: Exp; lines: +1 -1
opened the fifo in write onlu mode
decremented the u.value
wrote data from server to process
—————————-
revision 1.5
date: 2014/11/14 08:50:12; author: root; state: Exp; lines: +1 -1
closed the fifo
gave the gave the m.type
—————————-
revision 1.4
date: 2014/11/14 08:45:36; author: root; state: Exp; lines: +1 -1
now,using semop(),decremented the u.value,making the other processes wait while request client is writing
in the server side,reading the data and again incrementing the u.value
—————————-
revision 1.3
date: 2014/11/14 08:40:12; author: root; state: Exp; lines: +1 -1
created a fifo between client,server and server,process
opened the file in write only mode in the requesting client
—————————-
revision 1.2
date: 2014/11/14 08:32:00; author: root; state: Exp; lines: +1 -1
got the kernel key using msgget()
checked the accessibility of the file
using access(0
—————————-
revision 1.1
date: 2014/11/14 08:29:23; author: root; state: Exp;
Initial revision

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>