Boost logo

Boost Users :

Subject: [Boost-users] ipc message_queue getting permission denied
From: Matt Fair (matt.fair_at_[hidden])
Date: 2011-09-29 12:07:22


I ran across this problem when I moved my code to another system. Not
sure if this is the right list to post this, but I've been having
trouble debugging this as all of my attempts have lead me to dead

I have the following code with boost 1.47:

  m_messageQueue = boost::shared_ptr<boost::interprocess::message_queue>(
           new boost::interprocess::message_queue (
             ,name.c_str()             //name
             ,numElements              //max message number
             ,sizeof(Message)          //max message size
catch(boost::interprocess::interprocess_exception &e)
  cerr << e.what();

where name="test_queue", numElements=100, and sizeof(Message)=256.

The output is: Permission denied

If I run as user root, it will pass. I can't figure out where it is
trying to write to where it would have a permission error. Looking at
the boost code, shouldn't it just be in /tmp/boost_interprocess which
any user would have access to create and write to? Also, I
noticed, but this should
be fixed now.

Any help or insight would be appreciated.


Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at