Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer
User Name
Linux - Embedded & Single-board computer This forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.


  Search this Thread
Old 11-15-2009, 08:58 AM   #1
LQ Newbie
Registered: Nov 2009
Posts: 2

Rep: Reputation: 0
Creating more than one shared memory by a process

Hi all,

I am not sure whether more than one shared memory can be created by a process

I tried creating three shared memory by a process.
I am using shmget system call to create the shared memory.
The flag parameter what I am using is IPC_CREATE | 0666 for all the three.
I had also tried with IPC_CREATE | 0644

I am getting three different ids for shmget and three different pointers for shmat().But some junk value is coming in the shared memory created.

I doubt that the shared memory created is overlapping.Whether the flag parameter has to be changed.

Please clear my doubt


Last edited by anoopmenons; 11-15-2009 at 08:59 AM. Reason: tag was not added
Old 11-15-2009, 12:11 PM   #2
LQ 5k Club
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,397
Blog Entries: 2

Rep: Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908Reputation: 908
Your problem is probably buried in the details. How about posting the code that demonstrates the problem?
--- rod.


creating, memory, shared

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Linux shared memory segment access problem and x86 Virtual Memory layout. regmee Linux - Kernel 1 08-23-2008 12:11 AM
Difference between resident memory,shared memory and virtual memory in system monitor mathimca05 Linux - Newbie 1 11-11-2007 04:05 AM
Accessing shared memory opened in a windows process in a connected linux pc gonzalesmico Programming 3 06-07-2007 02:31 PM
Creating Ora10g database on FC2 gives unable to create shared memory segment.... deanbrown3d Linux - Software 1 10-23-2004 11:40 AM
Creating FIFO messaege buffer using shared memory indika7777 Programming 1 03-27-2004 05:14 AM > Forums > Linux Forums > Linux - Hardware > Linux - Embedded & Single-board computer

All times are GMT -5. The time now is 02:36 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration