Boost C++ Libraries: Ticket #12137: boost::interprocess::intermodule_singleton initialization failed https://svn.boost.org/trac10/ticket/12137 <p> I'm getting exception "boost::interprocess::intermodule_singleton initialization failed" when trying to use Boost Interprocess library, even when I run any example from the library doc. Debugging showed that the library fails to find event 6005 in System's <a class="missing wiki">EventLog</a>, so it cannot obtain system boot-up time, which it uses to create shared dir. </p> <p> I used Windows Event Viewer to check that indeed, there is no such event in my system at this moment. I didn't delete it, so I suppose that Windows itself cleans old events. My system's uptime is more than 40 days. I see that my System Event Log is configured to be maximum 20MB (it's default, I didn't change it) and it's currently 20MB, so it explains everything. </p> <p> Since it's normal situation, I believe the library should use other way (in addition to, or instead of current way) to get bootup time. For example, GetTickCount64 or System Up Time performance counter (<a class="ext-link" href="https://msdn.microsoft.com/en-us/library/windows/desktop/ms725496(v=vs.85).aspx"><span class="icon">​</span>https://msdn.microsoft.com/en-us/library/windows/desktop/ms725496(v=vs.85).aspx</a>). </p> <p> What is worse, I cannot reboot at the moment and need to proof-of-concept IPC on Windows for our project, and this is my only Windows box... </p> <p> The only quick workaround I see is to patch get_last_bootup_time function to use GetTickCount64. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/12137 Trac 1.4.3 Valentin Shtronda <valiko.ua@…> Tue, 19 Apr 2016 07:55:05 GMT version changed https://svn.boost.org/trac10/ticket/12137#comment:1 https://svn.boost.org/trac10/ticket/12137#comment:1 <ul> <li><strong>version</strong> <span class="trac-field-old">Boost 1.61.0</span> → <span class="trac-field-new">Boost 1.60.0</span> </li> </ul> Ticket Valentin Shtronda <valiko.ua@…> Tue, 19 Apr 2016 07:57:10 GMT <link>https://svn.boost.org/trac10/ticket/12137#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12137#comment:2</guid> <description> <p> I also noticed that boost::interprocess::winapi::get_last_bootup_time() returns true (and stamp remains empty) if OpenEventLogA() fails. Is it by intent? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Fri, 22 Apr 2016 16:11:44 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12137#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12137#comment:3</guid> <description> <p> This appears to bea duplicate of <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> </p> </description> <category>Ticket</category> </item> <item> <author>Valentin Shtronda <valiko.ua@…></author> <pubDate>Fri, 22 Apr 2016 19:41:21 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12137#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12137#comment:4</guid> <description> <p> Indeed, same root cause. </p> <p> So the bug is old, from version 1.57 at least... </p> </description> <category>Ticket</category> </item> <item> <author>Valentin Shtronda <valiko.ua@…></author> <pubDate>Fri, 22 Apr 2016 19:42:46 GMT</pubDate> <title>attachment set https://svn.boost.org/trac10/ticket/12137 https://svn.boost.org/trac10/ticket/12137 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">win32_api.hpp.patch</span> </li> </ul> <p> The patch with my fix/workaround to apply on top of version 1.60. </p> Ticket Valentin Shtronda <valiko.ua@…> Fri, 22 Apr 2016 19:44:13 GMT <link>https://svn.boost.org/trac10/ticket/12137#comment:5 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12137#comment:5</guid> <description> <p> Note that this fix will not compile on Windows prior to Vista or Server 2008, which do not have GetTickCount64. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Thu, 01 Jun 2017 17:09:11 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/12137#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/12137#comment:6</guid> <description> <p> I've been having this problem with boost 1.64.0, running my app on a Win 10 Home edition. After applying the patch on win32_api.h and rebuilding boost and then my app, the problem went away. </p> </description> <category>Ticket</category> </item> </channel> </rss>