in reply to Problems with IPC::Shareable - Could not create semaphore set: No space left on device

You do not mention what OS are you in. Things like this can happen when you do not remove the IPC structures before exiting, leaving them behind.

Many OSes have limits on the amount of shared memory, semaphores or message queues they can create. The limit is often unrelated to how large is the system. The combination of these things can be the problem.

You can check this out by using the ipcs command, like in:

[root@guess again]# ipcs ------ Shared Memory Segments -------- key shmid owner perms bytes nattch status ------ Semaphore Arrays -------- key semid owner perms nsems status ------ Message Queues -------- key msqid owner perms used-bytes messages
The above example shows an empty IPC table, which is the state that your program should leave your machine after running. The output of the command can be different, so be sure to check your docs on this one.

If you find dangling IPC structures after your program is done, you can manually delete them using the ipcrm command. Again, check your manual on how to do this.

Good luck.