"ENOSYS" is the system's polite way of telling you that your system
does not provide the requirements for this feature.  In this case, you
need inotify.

http://nodejs.org/api/fs.html#fs_caveats

On Mon, Mar 12, 2012 at 21:11, ttback <[email protected]> wrote:
> I am not sure if I am  using the fs.watch api incorrectly, because it works
> on Windows XP, MacOS X, but not on CentOS 5.5
>
> Errors:
>
> fs.js:663
> throw errnoException(errno, 'watch');
> ^
> Error: watch ENOSYS
> at errnoException (fs.js:636:11)
> at FSWatcher.start (fs.js:663:11)
> at Object.watch (fs.js:691:11)
> at SocketNamespace. (/home/server.js:27:6)
> at SocketNamespace.$emit (events.js:67:17)
> at connect (/home/node_modules/socket.io/lib/namespace.js:292:10)
> at /home/node_modules/socket.io/lib/namespace.js:308:13
> at SocketNamespace.authorize
> (/home/node_modules/socket.io/lib/namespace.js:252:5)
> at SocketNamespace.handlePacket
> (/home/node_modules/socket.io/lib/namespace.js:302:14)
> at Manager.handleClient (/home/node_modules/socket.io/lib/manager.js:654:30)
>
>
> Code:
>
> fs.watch( 'example.xml', function ( curr, prev ) {
>     // on file change we can read the new xml
>     fs.readFile( 'example.xml', function ( err, data ) {
>       if ( err ) throw err;
>       //do something with data
>     });
>   });
>
> --
> Job Board: http://jobs.nodejs.org/
> Posting guidelines:
> https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
> You received this message because you are subscribed to the Google
> Groups "nodejs" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/nodejs?hl=en?hl=en

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to