Cov txheej txheem:

Kuv yuav hloov kuv tus password MongoDB li cas?
Kuv yuav hloov kuv tus password MongoDB li cas?

Video: Kuv yuav hloov kuv tus password MongoDB li cas?

Video: Kuv yuav hloov kuv tus password MongoDB li cas?
Video: Qhia saib seb yus tu hlub комментарий thiab nias like rau leej twg 2021 2024, Kaum ib hlis
Anonim

Txheej txheem

  1. Nkag mus rau tus ESA host uas khiav tus Kev pabcuam ESA: SSH rau tus ESA host. Nkag mus raws li hauv paus.
  2. Nkag mus rau MongoDB as admin. Cov ua ntej tus password yog netwitness. mongo admin -u admin -p
  3. Rau hloov cov admin account tus password , hom. db.changeUserPassword('admin', ')

Hais txog qhov no, kuv yuav hloov kuv lub npe MongoDB username thiab password li cas?

pib mongo plhaub: mongo --port 27017 -u "myUserAdmin" -p "abc123" --authenticationDatabase "admin" hloov mus rau authentication database: siv admin db. auth("myUserAdmin", "abc123"

Ib tug kuj yuav nug, dab tsi yog lub neej ntawd username thiab password ntawm MongoDB? Los ntawm lub neej ntawd mongodb tsis muaj kev tswj hwm kev nkag mus, yog li tsis muaj tus neeg siv lossis tus password. Txhawm rau kom tswj kev nkag mus, siv ob qho tib si lus txib kab xaiv --auth los yog kev ruaj ntseg.

Ib yam li ntawd ib tug yuav nug, koj yuav hloov tus password li cas?

Yuav Hloov Koj Lub Computer Login Password Li Cas

  1. Kauj ruam 1: Qhib Start Menu. Mus rau lub desktop ntawm koj lub computer thiab nyem rau ntawm Start menu khawm.
  2. Kauj ruam 2: Xaiv Tswj Vaj Huam Sib Luag. Qhib Control Vaj Huam Sib Luag.
  3. Kauj ruam 3: Cov neeg siv nyiaj. Xaiv "Cov Neeg Siv Khoom thiab Tsev Neeg Kev Nyab Xeeb".
  4. Kauj ruam 4: Hloov Windows Password.
  5. Kauj ruam 5: Hloov Password.
  6. Kauj ruam 6: Sau tus password.

Kuv yuav authenticate hauv MongoDB li cas?

Txhawm rau kom paub tseeb siv lub plhaub mongo, xws li:

  1. Siv cov mongo command-line authentication xaiv (--username, --password, thiab --authenticationDatabase) thaum txuas mus rau mongod lossis mongos piv txwv, los yog.
  2. Txuas ua ntej mus rau mongod lossis mongos piv txwv, thiab tom qab ntawd khiav cov ntawv pov thawj lees paub lossis db.

Pom zoo: