Implement command execution in given ns.