Инициализация boost::flyweights::intermodule_holder завершается с ошибкой interprocess_Exception и отказом в разрешенииC++

Программы на C++. Форум разработчиков
Anonymous
Инициализация boost::flyweights::intermodule_holder завершается с ошибкой interprocess_Exception и отказом в разрешении

Сообщение Anonymous »

Я понятия не имею, почему это не удалось.
Объект_shared_memory_object должен быть уникальным, поскольку доступ к нему возможен только из одного и того же процесса.
Текущий каталог доступен для записи и доступен для записи. то же самое и с $TMPDIR, и с /tmp/
Вот и трассировка стека:

Код: Выделить всё

Catchpoint 1 (exception thrown), __cxxabiv1::__cxa_throw (obj=0x99ca40,
tinfo=0x946668 ,
dest=0x5a0f8a )
at ../../../../gcc-5.3.0/libstdc++-v3/libsupc++/eh_throw.cc:62
(gdb) where
#0  __cxxabiv1::__cxa_throw (obj=0x99ca40, tinfo=0x946668 ,
dest=0x5a0f8a )
at ../../../../gcc-5.3.0/libstdc++-v3/libsupc++/eh_throw.cc:62
#1  0x00000000005a5261 in boost::interprocess::shared_memory_object::priv_open_or_create (this=0x7fffffffa200,
type=boost::interprocess::ipcdetail::DoOpen, filename=0x99c930 "bip.gmem.map.44132_0.000000", mode=boost::interprocess::read_write,
perm=...) at /mnt/share/boost/boost-1.80//include/boost/interprocess/shared_memory_object.hpp:425
#2  0x00000000005a1e7d in boost::interprocess::shared_memory_object::shared_memory_object (this=0x7fffffffa200,
name=0x99c930 "bip.gmem.map.44132_0.000000", mode=boost::interprocess::read_write)
at /mnt/share/boost/boost-1.80//include/boost/interprocess/shared_memory_object.hpp:84
#3  0x00000000005aa28b in boost::interprocess::ipcdetail::managed_open_or_create_impl::priv_open_or_create (this=0x7fffffffa3d8,
type=boost::interprocess::ipcdetail::DoOpen, id=@0x7fffffffa340: 0x99c930 "bip.gmem.map.44132_0.000000", size=0,
mode=boost::interprocess::read_write, addr=0x0, perm=..., construct_func=...)
at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/managed_open_or_create_impl.hpp:488
#4  0x00000000005a7630 in boost::interprocess::ipcdetail::managed_open_or_create_impl::managed_open_or_create_impl (this=0x7fffffffa3d8,
id=@0x7fffffffa340: 0x99c930 "bip.gmem.map.44132_0.000000", mode=boost::interprocess::read_write, addr=0x0, construct_func=...)
at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/managed_open_or_create_impl.hpp:179
#5  0x00000000005a552a in boost::interprocess::ipcdetail::basic_managed_global_memory::basic_managed_global_memory (this=0x7fffffffa3d0, name=0x99c930 "bip.gmem.map.44132_0.000000", addr=0x0)
at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/managed_global_memory.hpp:108
#6  0x00000000005a26bf in boost::interprocess::ipcdetail::intermodule_singleton_helpers::thread_safe_global_map_dependant::apply_gmem_erase_logic (
filepath=0x99c8e0 "/tmp/boost_interprocess/gmem/lck44132_0.000000", filename=0x994923 "lck44132_0.000000")
at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/portable_intermodule_singleton.hpp:171
#7  0x00000000005a57a8 in boost::interprocess::ipcdetail::for_each_file_in_dir (
dir=0x994840 "/tmp/boost_interprocess/gmem",
f=0x5a25e7 )
at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/os_file_functions.hpp:804
#8  0x00000000005a283d in boost::interprocess::ipcdetail::intermodule_singleton_helpers::thread_safe_global_map_dependant::remove_old_gmem ()
at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/portable_intermodule_singleton.hpp:198
#9  0x00000000005b9eab in boost::interprocess::ipcdetail::intermodule_singleton_common::initialize_global_map_handle ()
at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/intermodule_singleton_common.hpp:237
#10 0x00000000005b588f in boost::interprocess::ipcdetail::intermodule_singleton_common::initialize_singleton_logic (ptr=@0x97ba80: 0x0,
this_module_singleton_initialized=@0x97ba88: 1,
constructor=0x5b59e7 , phoenix=false) at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/intermodule_singleton_common.hpp:127
#11 0x00000000005b21e2 in boost::interprocess::ipcdetail::intermodule_singleton_impl::atentry_work () at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/intermodule_singleton_common.hpp:345
#12 0x00000000005aee02 in boost::interprocess::ipcdetail::intermodule_singleton_impl::get () at /mnt/share/boost/boost-1.80//include/boost/interprocess/detail/intermodule_singleton_common.hpp:335
#13 0x00000000005aaf81 in boost::flyweights::detail::flyweight_core::init ()
at /mnt/share/boost/boost-1.80//include/boost/flyweight/detail/flyweight_core.hpp:112
#14 0x000000000059de56 in __static_initialization_and_destruction_0 (__initialize_p=1, __priority=65535)
at /mnt/share/boost/boost-1.80//include/boost/flyweight/detail/flyweight_core.hpp:278
#15 0x000000000059f46b in _GLOBAL__sub_I_messagehandler.cc(void) () at src/framework/src/messagehandler.cc:2516
#16 0x00000000007fe79d in __libc_csu_init ()
#17 0x00002aaaabbbf4e5 in __libc_start_main () from /lib64/libc.so.6
#18 0x00000000005901ae in _start ()
Файл /tmp/boost_interprocess/gmem/lck44132_0.000000 (показанный в трассировке стека) принадлежал другому пользователю. Возможно, идентификаторы процессов были перезапущены. Но число, записанное в имени файла, не соответствует идентификатору процесса 38193.

Подробнее здесь: https://stackoverflow.com/questions/784 ... terprocess

Вернуться в «C++»