Boost C++ Libraries: Ticket #12315: boost::interprocess_exception - library_error exception when creating shared_memory_object https://svn.boost.org/trac10/ticket/12315 <p> <a class="ext-link" href="http://stackoverflow.com/questions/38045857/boostinterprocess-exception-library-error-exception-when-creating-shared-mem"><span class="icon">​</span>Problem description and workaround</a> </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/12315 Trac 1.4.3 anonymous Thu, 07 Jul 2016 09:44:42 GMT version changed https://svn.boost.org/trac10/ticket/12315#comment:1 https://svn.boost.org/trac10/ticket/12315#comment:1 <ul> <li><strong>version</strong> <span class="trac-field-old">Boost 1.57.0</span> → <span class="trac-field-new">Boost 1.58.0</span> </li> </ul> Ticket anonymous Fri, 17 Feb 2017 11:39:48 GMT <link>https://svn.boost.org/trac10/ticket/12315#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12315#comment:2</guid> <description> <p> Can this please get some attention? This bug means that if the system is up long enough for the event with id 6005 to be rolled out of event logs, this will always fail. It is unreliable implementation of getting last bootup time. Code comes from </p> <p> boost\interprocess\detail\win32_api.hpp </p> <p> <em>Obtains the bootup time from the System Event Log, </em>event ID == 6005 (event log started). <em>Adapted from <a class="ext-link" href="http://msdn.microsoft.com/en-us/library/windows/desktop/bb427356.aspx"><span class="icon">​</span>http://msdn.microsoft.com/en-us/library/windows/desktop/bb427356.aspx</a> <strong>inline bool get_last_bootup_time(std::string &amp;stamp)</strong> </em></p> </description> <category>Ticket</category> </item> <item> <dc:creator>Ion Gaztañaga</dc:creator> <pubDate>Fri, 17 Feb 2017 12:40:14 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12315#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12315#comment:3</guid> <description> <p> Can you check ticket <a class="new ticket" href="https://svn.boost.org/trac10/ticket/11480" title="#11480: Bugs: Interprocess get_last_bootup_time use of Event Log on Windows is ... (new)">#11480</a> (<a class="ext-link" href="https://svn.boost.org/trac/boost/ticket/11480"><span class="icon">​</span>https://svn.boost.org/trac/boost/ticket/11480</a>) and see if the experimental feature solution can work in your case? </p> </description> <category>Ticket</category> </item> <item> <author>janwilmans@…</author> <pubDate>Fri, 17 Feb 2017 14:57:59 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12315#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12315#comment:4</guid> <description> <p> it's not really a viable workaround in many cases, because you would have to do this befor eevery time you create a shared_memory_object... </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Ion Gaztañaga</dc:creator> <pubDate>Fri, 17 Feb 2017 15:49:54 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12315#comment:5 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12315#comment:5</guid> <description> <p> I don't understand your point. The event log is not reliable, so we need an alternative. </p> <p> You can update the code to the develop or master branch and define BOOST_INTERPROCESS_BOOTSTAMP_IS_SESSION_MANAGER_BASED in your project, and see if that alternative (without using the event log) is more reliable. This breaks binary compatibility but at least for new applications might work. </p> </description> <category>Ticket</category> </item> <item> <author>janwilmans@…</author> <pubDate>Sat, 18 Feb 2017 23:18:03 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12315#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12315#comment:6</guid> <description> <p> igaztanaga: I was not responding to your solution, I was referring to the workaround mentioned on stackoverflow, no being a viable workaround, because the event-log can be cleared at any time, and also for system with a long uptime and/or many event-log messages, the message can be lost because it is pushed out of the cyclical buffer. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Mon, 20 Feb 2017 10:10:42 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12315#comment:7 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12315#comment:7</guid> <description> <p> Re comment 3: Sorry, but we can't move to development branch (company using boost 1.60 in production environment). Is this new feature scheduled for 1.63? </p> <p> Also, the client code using this boost functionality is likely 3rd party, so we wouldn't be able to easily test it. </p> </description> <category>Ticket</category> </item> <item> <author>Jan Wilmans <janwilmans@…></author> <pubDate>Mon, 20 Feb 2017 12:14:09 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12315#comment:8 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12315#comment:8</guid> <description> <p> We also cannot move to test-branches, our organization requires that we use official releases. </p> <p> I'm not aware of the internal requirements for a shared_memory_object, but specifically for boost::interprocess::named_mutex, why is not mapped to the <a class="missing wiki">CreateMutex</a> API on win32? </p> <p> (<a class="ext-link" href="https://msdn.microsoft.com/en-us/library/windows/desktop/ms682411(v=vs.85).aspx"><span class="icon">​</span>https://msdn.microsoft.com/en-us/library/windows/desktop/ms682411(v=vs.85).aspx</a>) </p> <p> Our current workaround is to use this API directly. </p> </description> <category>Ticket</category> </item> </channel> </rss>