Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'd like to create a new network namespace on Linux.

http://www.spinics.net/lists/linux-containers/msg10895.html tells me that I can attach a shell to an existing namespace with ID X by running:

$ chnetns X /bin/sh

This works fine if the namespace already exists, but if I try with a non-existent namespace, I get the following:

$ chnetns 100 /bin/sh
setsocketopt: Invalid argument

How can I create the namespace? I'm on Red Hat Linux, V6.1.

share|improve this question
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.