Skip to content

(DOCS-10468): Revised Windows Install for MongoDB #3346

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

Merged
merged 3 commits into from
Jun 20, 2018

Conversation

atsansone
Copy link
Contributor

@steveren : This is a total refactor.


.. code-block:: powershell

PS C:\> systeminfo | findstr /B /C:"OS Name" /C:"OS Version" /C:"System Type"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to remove the "PS C:>" part at the beginning for this command to be copy-pastable.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.

.. warning::

Do not expose :binary:`~bin.mongod.exe` to a public network without
configuring authentication. MongoDB is designed to be run in
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd link "authentication" to the manual page.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.


wmic os get caption
wmic os get osarchitecture
1. Press the :icon:`windows` key.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nifty use of the Windows icon, but not all keyboards have that key (mine doesn't, for example, but I'm not really a Windows user). If you're confident that everyone reading this has a Windows key, leave it as is, but for total inclusivity I'd use an alternate method for bringing up cmd.exe.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added point about Start menu.


#. The Download Center should display the
:guilabel:`Current Stable Release` and have the :icon:`windows`
:guilabel:`Windows` tab selected. If that tab is not selected,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're describing the Community Server download center page here. The Enterprise Server download center UI looks different.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. Created new steps page to cover.


.. code-block:: shell

[initandlisten] waiting for connections
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you start mongod.exe with the --logpath option, all the [initandlisten] messages go to the logfile. There are two copyable commands here, and one uses --logpath and the other doesn't, which might lead to confusion.

Also, no need for the log message code block to be copyable.

log:

.. code-block:: bat

[SC] CreateService SUCCESS
---
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, no need for this code block to be copyable. It seems like a nit, but I think it's helpful to distinguish copyable code blocks from log messages and such.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.

---
stepnum: 6
stepnum: 5
source:
file: steps-run-mongodb-on-linux.yaml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file isn't part of the review, but as long as you've got it open you could add a period to the end of the title line, "Verify that MongoDB has started successfully"

Also that file has the code block with the [initandlisten] message, which should get (my pet peeve) the :copyable: false line.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.

to create the service:

.. code-block:: bat

sc.exe create MongoDB ^
binPath= "\"C:\Program Files\MongoDB\Server\{+version+}\bin\mongod.exe\" ^
--service --config=\"C:\Program Files\MongoDB\Server\{+version+}\mongod.cfg\"" ^
DisplayName= "MongoDB" start= "auto"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This command didn't work for me in cmd.exe. I got this:

C:\WINDOWS\system32>sc.exe create MongoDB ^
More? binPath= ""C:\Program Files\MongoDB\Server\4.0\bin\mongod.exe" ^
[SC] CreateService SUCCESS

C:\WINDOWS\system32> --service --config="C:\Program Files\MongoDB\Server\4.0\mongod.cfg"" ^
'--service' is not recognized as an internal or external command,
operable program or batch file.

I also tried in Powershell (as administrator) and got a different error. Maybe retest?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah. This is a tough one to cut and paste. Two lines is usually the limit. Fixed.


.. include:: /includes/steps/run-mongodb-on-windows.rst
.. include:: /includes/steps/install-mongodb-enterprise-on-windows-unattended.rst

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The command msiexec.exe /q /i mongodb-win32-x86_64-enterprise-windows-64-4.0.0-rc5-signed.msi worked for me, but I had to adjust the name of the .msi file. We might want to either use a placeholder value or just note that users should run msiexec.exe on their downloaded .msi file.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's using the variable for the most recent release. That works against us when testing.

@@ -10,90 +10,107 @@ Install MongoDB Enterprise on Windows
:depth: 1
:class: singlecol

.. |mdb-edition| replace:: MongoDB Enterprise Edition
.. |mdb-download-link| replace:: `MongoDB Download Center <https://www.mongodb.com/download-center#enterprise>`__

.. versionadded:: 2.6
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this still need to be here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nah. Deleted.

an issue with memory mapped files on Windows.

The Windows installer (``.msi``) file includes all other
software dependencies and automatically upgrades any previous version
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It only upgrades patch level in the same release

Automatic Upgrade: 3.4.1 -> 3.4.2
Not Upgrade, treated as two separate installs: 3.4.1 -> 3.6.0


During the installation process you will be given the option to
install :ref:`MongoDB Compass <compass-index>` after installing
MongoDB Server. Clear the checkbox for this option. At this time,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We back ported the fix to be in 3.6. It was fixed for 4.0

copyable: true
language: bat
code: |
msiexec.exe /q /i mongodb-win32-x86_64-2008plus-ssl-{{version}}-signed.msi ^
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use enterprise file instead of ssl in example

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

still needs to be fixed


During the installation process you will be given the option to
install :ref:`MongoDB Compass <compass-index>` after installing
MongoDB Server. Clear the checkbox for this option. At this
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see other note

@markbenvenuto
Copy link
Contributor

Also, does this documentation account for the fact that the MSI now installs the service in 4.0?

Copy link
Contributor Author

@atsansone atsansone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@steveren : Made the changes. Back to you.


.. code-block:: powershell

PS C:\> systeminfo | findstr /B /C:"OS Name" /C:"OS Version" /C:"System Type"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.

.. warning::

Do not expose :binary:`~bin.mongod.exe` to a public network without
configuring authentication. MongoDB is designed to be run in
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.

to create the service:

.. code-block:: bat

sc.exe create MongoDB ^
binPath= "\"C:\Program Files\MongoDB\Server\{+version+}\bin\mongod.exe\" ^
--service --config=\"C:\Program Files\MongoDB\Server\{+version+}\mongod.cfg\"" ^
DisplayName= "MongoDB" start= "auto"
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah. This is a tough one to cut and paste. Two lines is usually the limit. Fixed.

log:

.. code-block:: bat

[SC] CreateService SUCCESS
---
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.

---
stepnum: 6
stepnum: 5
source:
file: steps-run-mongodb-on-linux.yaml
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Fixed.


#. The Download Center should display the
:guilabel:`Current Stable Release` and have the :icon:`windows`
:guilabel:`Windows` tab selected. If that tab is not selected,
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. Created new steps page to cover.

@@ -10,90 +10,107 @@ Install MongoDB Enterprise on Windows
:depth: 1
:class: singlecol

.. |mdb-edition| replace:: MongoDB Enterprise Edition
.. |mdb-download-link| replace:: `MongoDB Download Center <https://www.mongodb.com/download-center#enterprise>`__

.. versionadded:: 2.6
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nah. Deleted.


wmic os get caption
wmic os get osarchitecture
1. Press the :icon:`windows` key.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added point about Start menu.


.. include:: /includes/steps/run-mongodb-on-windows.rst
.. include:: /includes/steps/install-mongodb-enterprise-on-windows-unattended.rst

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's using the variable for the most recent release. That works against us when testing.

Copy link
Contributor

@steveren steveren left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Copy link
Contributor

@markbenvenuto markbenvenuto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still needs one minor fix

copyable: true
language: bat
code: |
msiexec.exe /q /i mongodb-win32-x86_64-2008plus-ssl-{{version}}-signed.msi ^
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

still needs to be fixed

@atsansone
Copy link
Contributor Author

@kay-kim : RFM for v3.6 and master. Once it is merged into master, I will make the v4.0 changes.

@kay-kim kay-kim merged commit 73896d6 into mongodb:master Jun 20, 2018
mongo-cr-bot pushed a commit that referenced this pull request Jun 14, 2023
* DOCS-16154 Fixes typo in Server Parameters

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

Successfully merging this pull request may close these issues.

4 participants