Results 1 to 4 of 4
Hi all;
I want to create a "Shared Memory" in linux, then create multiple "Shared Objects" that can access to a Table for example;
And one of them can write ...
- 06-11-2010 #1Just Joined!
- Join Date
- Sep 2009
- Posts
- 27
How to create a shared memory and some shared objects in linux?
Hi all;
I want to create a "Shared Memory" in linux, then create multiple "Shared Objects" that can access to a Table for example;
And one of them can write something into the Table and the other can access and read it, so that these operations can be handled by programmer!
I'm using Ubuntu 9.04 and I've set it's runlevel at 3 (I have commandline environment now!)
I've searched the Internet so much, but couldn't find a good sample code for this!
I have no experience about it and need your help to introduce me a sample code about it and advise me how to compile and use it with "GCC"?!
Please help me with this, I'm so hurry!!
TIA
- 06-12-2010 #2Linux Guru
- Join Date
- Apr 2009
- Location
- I can be found either 40 miles west of Chicago, or in a galaxy far, far away.
- Posts
- 8,974
Is this a class exercise? Also, you don't need runlevel 3 to do this. You can start a command line terminal in the GUI desktop easily enough.
Sometimes, real fast is almost as good as real time.
Just remember, Semper Gumbi - always be flexible!
- 06-13-2010 #3
Yeah, we're all so hurry.
Your request is about something called Interprocess Communication (IPC). A very nice summary of IPC, with example code, is available at Beej's Guide to IPC.
--- rod.Stuff happens. Then stays happened.
- 06-17-2010 #4Just Joined!
- Join Date
- Jun 2010
- Posts
- 15
you aslo can do it via a virtual char device read/write .


Reply With Quote