Query : Is there any way in Python to say:
Don't use
/dev/shmfor shared memory storage and use some other temporary location such as/tmpinstead. ORInstead of
multiprocessing.SemLockusethreading.Lockfor synchronization (if it's feasible and not illogical).
Background:
I am running a simple multiprocessing.Pool example on an ESX (hypervisor) which is running into OSError : Function not implemented error.
Other mentions to this problem (here and here) on StackOverflow have pointed out that it happens when /dev/shm is not mounted. Due to which, _multiprocessing.SemLockfails to create synchronization lock(s).
It is actually the case for me as ls -lrt /dev/shm fails for me. However I cannot try the solutions recommended on the above links as
mountas mount command is not implemented on the platform (ESX/VMKernel) I am running on.VM is not persistent and
/etc/fstabgets washed away on shutdown itself.
So I am looking for ways to either use threading.Lock() for synchronization or ask Python to not to use /dev/shm/ for synchronization.