Using the Mongose module in node. js

Source: Internet
Author: User
Tags install node npm install node

Object corresponds to document

Create the project directory and enter it with Root

# mkdir/home/test/part9/

Direct # NPM Install Mongoose, error is as follows

.. /node_modules/nan/nan.h:316:47:error: ' Replace_invalid_utf8 ' is not a member of ' v8::string '
static const unsigned KREPLACEINVALIDUTF8 = V8::string::replace_invalid_utf8;
^
Make: * * * [RELEASE/OBJ.TARGET/KERBEROS/LIB/KERBEROS.O] Error 1
make:leaving directory '/home/test/part9/node_modules/mongoose/node_modules/mongodb/node_modules/kerberos/build '
Gyp err! Build Error
Gyp err! Stack Error: ' Make ' failed with exit Code:2
Gyp err! Stack at Childprocess.onexit (/usr/lib/node_modules/node-gyp/lib/build.js:267:23)
Gyp err! Stack at Childprocess.emit (events.js:98:17)
Gyp err! Stack at Process.childprocess._handle.onexit (child_process.js:820:12)
Gyp err! System Linux 3.10.0-229.14.1.el7.x86_64
Gyp err! Command "Node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "Rebuild"
Gyp err! Cwd/home/test/part9/node_modules/mongoose/node_modules/mongodb/node_modules/kerberos
Gyp err! Node-v v0.10.36
Gyp err! Node-gyp-v v0.10.6

Then install NODE-GYP,

# NPM Install Node-gyp-g

# NPM Install Mongoose

Error eliminated, warning

/usr/bin/node-gyp-/usr/lib/node_modules/node-gyp/bin/node-gyp.js
NPM WARN Unmet dependency/usr/lib/node_modules/block-stream requires [email protected] ' ~2.0.0 ' but would load
NPM WARN Unmet dependency undefined,
NPM WARN Unmet dependency which is version undefined
NPM WARN Unmet dependency/usr/lib/node_modules/fstream requires [email protected] ' ~2.0.0 ' but would load
NPM WARN Unmet dependency undefined,
NPM WARN Unmet dependency which is version undefined
NPM WARN Unmet dependency/usr/lib/node_modules/fstream-ignore requires [email protected] ' 2 ' but would load
NPM WARN Unmet dependency undefined,
NPM WARN Unmet dependency which is version undefined
NPM WARN Unmet DEPENDENCY/USR/LIB/NODE_MODULES/FSTREAM-NPM requires [email protected] ' 2 ' but would load
NPM WARN Unmet dependency undefined,
NPM WARN Unmet dependency which is version undefined
NPM WARN Unmet dependency/usr/lib/node_modules/glob requires [email protected] ' 2 ' but would load
NPM WARN Unmet dependency undefined,
NPM WARN Unmet dependency which is version undefined
NPM WARN Unmet dependency/usr/lib/node_modules/npmconf requires [email protected] ' ~2.0.0 ' but would load
NPM WARN Unmet dependency undefined,
NPM WARN Unmet dependency which is version undefined
NPM WARN Unmet dependency/usr/lib/node_modules/tar requires [email protected] ' 2 ' but would load
NPM WARN Unmet dependency undefined,
NPM WARN Unmet dependency which is version undefined

Using the Mongose module in node. js

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.