节点js 0.10.7:群集支持udp dgram?

我试图运行下面的节点js应用程序提到https://github.com/joyent/node/issues/2194

var util = require("util"), dgram = require("dgram"), cluster = require('cluster'); var udp = dgram.createSocket("udp4"); var port = 1190; if (cluster.isMaster) { for (i = 0; i < 2; i++) { cluster.fork(); } } else { util.log("starting udp server on port " + port); udp.on("error", function (error) { util.log("failed to bind to UDP port - " + error) }); udp.bind(port); } 

该应用程序立即退出以下输出:

 23 May 23:22:13 - starting udp server on port 1190 23 May 23:22:13 - starting udp server on port 1190 events.js:72 throw er; // Unhandled 'error' event ^ Error: write ENOTSUP - cannot write to IPC channel. at errnoException (child_process.js:980:11) at ChildProcess.target.send (child_process.js:455:16) at Worker.send (cluster.js:401:21) at sendInternalMessage (cluster.js:394:10) at handleResponse (cluster.js:177:5) at respond (cluster.js:192:5) at Object.messageHandler.queryServer (cluster.js:242:5) at handleMessage (cluster.js:197:32) at ChildProcess.EventEmitter.emit (events.js:117:20) at handleMessage (child_process.js:318:10) 

有谁知道发生了什么事? 当没有集群运行时,一切都很好。 看来,集群不支持udp?

一些规格:

 Window 7 x64 node js 0.10.7 

       

网上收集的解决方案 "节点js 0.10.7:群集支持udp dgram?"