Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

problem when I start the app.... #56

Open
xxx31fr opened this issue Mar 27, 2018 · 6 comments
Open

problem when I start the app.... #56

xxx31fr opened this issue Mar 27, 2018 · 6 comments

Comments

@xxx31fr
Copy link

xxx31fr commented Mar 27, 2018

Hello,

I'd install MongoDB on the same server than MeanTorrent.
I'd like to have 2 differents servers:
1 for MongoDB
1 for Application MeanTorrent

How to modify Application code to connect to a remote DB
and, Second Question, I'd like to secure the DB, How to modifiy the application code to use user/password to connect to the MongoDB database?

Thanks.

@xxx31fr
Copy link
Author

xxx31fr commented Mar 29, 2018

When I start the app,
I get theses errors.
Can you help me to fix it, please:

(node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "makers", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1) (node:18938) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "collections", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "topics", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 3) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "forums", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 4) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "adminmessages", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 5) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "invitations", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 6) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "messages", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 7) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "requests", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 8) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "torrents", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 9) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { insert: "system.indexes", ordered: true, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:497:72 at authenticateStragglers (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:443:16) at Connection.messageHandler (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:477:5) at Socket.<anonymous> (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/connection.js:333:22) at Socket.emit (events.js:180:13) at Socket.emit (domain.js:421:20) at addChunk (_stream_readable.js:269:12) at readableAddChunk (_stream_readable.js:256:11) at Socket.Readable.push (_stream_readable.js:213:10) at TCP.onread (net.js:578:20) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 10) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "subtitles", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 11) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { insert: "system.indexes", ordered: true, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:497:72 at authenticateStragglers (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:443:16) at Connection.messageHandler (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:477:5) at Socket.<anonymous> (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/connection.js:333:22) at Socket.emit (events.js:180:13) at Socket.emit (domain.js:421:20) at addChunk (_stream_readable.js:269:12) at readableAddChunk (_stream_readable.js:256:11) at Socket.Readable.push (_stream_readable.js:213:10) at TCP.onread (net.js:578:20) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 12) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "completes", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 13) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "traces", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 14) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "finisheds", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 15) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "users", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 16) (node:18938) UnhandledPromiseRejectionWarning: MongoError: not authorized on mean-v2-dev to execute command { listIndexes: "peers", cursor: {}, $db: "mean-v2-dev" } at Function.MongoError.create (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/error.js:31:11) at queryCallback (/home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/cursor.js:212:36) at /home/nody/meanTorrent/node_modules/mongoose/node_modules/mongodb-core/lib/connection/pool.js:469:18 at process._tickCallback (internal/process/next_tick.js:112:11) (node:18938) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 17)

When I see the app.log, it says:

2018-03-29T15:09:33.142Z - info: GET / - - ms - -

2018-03-29T15:09:39.837Z - info: GET / - - ms - -

2018-03-29T15:11:39.858Z - info: GET / - - ms - -

2018-03-29T15:12:06.264Z - info: GET / - - ms - -

2018-03-29T15:14:06.279Z - info: GET / - - ms - -

2018-03-29T15:17:06.365Z - info: GET / - - ms - -

Thanks for your help.

@xxx31fr xxx31fr changed the title remote DB+credentials DB problem when I start the app.... Mar 29, 2018
@taobataoma
Copy link
Owner

@xxx31fr Witch version of mongodb are you installed? looks problem is on mongodb.

@xxx31fr
Copy link
Author

xxx31fr commented Apr 9, 2018

this is the last version mongodb

@xxx31fr
Copy link
Author

xxx31fr commented Apr 9, 2018

can it be possible to change Mongodb with MySQL?
If yes, can you, please, details me how to use MySQL instead MongoDB?

Thank you so much for your help.

@taobataoma
Copy link
Owner

@xxx31fr meanTorrent don`t support Mysql, that need a lot of work should to do, and include many codes need to change. so meanTorrent only support mongoDB.

@WXpiero
Copy link

WXpiero commented May 6, 2018

same error code here,I'm using AWS's mean eviroment snapshot,really frustrated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants