Skip to content

Commit 6cf3c0b

Browse files
committed
Improve docs for macOS installation
1 parent 0595063 commit 6cf3c0b

File tree

1 file changed

+84
-26
lines changed

1 file changed

+84
-26
lines changed

modules/ROOT/pages/installation/osx.adoc

Lines changed: 84 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,38 +3,30 @@
33
= macOS installation
44

55
Before you install Neo4j on macOS, check xref:installation/requirements.adoc[System Requirements] to see if your setup is suitable.
6-
6+
If it is not already installed, get link:https://openjdk.org/[OpenJDK 21] or link:https://www.azul.com/downloads/[ZuluJDK 21].
77

88
[[osx-console]]
9-
== Unix console application
9+
== Install Neo4j as a console application
1010

11-
. If it is not already installed, get link:https://openjdk.org/[OpenJDK 21] or link:https://www.azul.com/downloads/[ZuluJDK 21].
12-
. Download the latest release from link:{neo4j-download-center-uri}[Neo4j Deployment Center].
13-
+
14-
Select the appropriate tar.gz distribution for your platform.
15-
. Make sure to download Neo4j from link:{neo4j-download-center-uri}[Neo4j Deployment Center] and always check that the SHA hash of the downloaded file is correct:
16-
.. To find the correct SHA hash, go to Neo4j Deployment Center and click on `SHA-256` which will be located below your downloaded file.
17-
.. Using the appropriate commands for your platform, display the `SHA-256` hash for the file that you downloaded.
18-
.. Ensure that the two are identical.
19-
. Extract the contents of the archive, using `tar -xf` <filename>.
20-
For example, `tar -xf neo4j-community-{neo4j-version-exact}-unix.tar.gz`.
11+
You can run Neo4j as a console application on macOS.
12+
13+
. Download the Linux/Mac Executable {neo4j-version-exact} (tar) release from link:{neo4j-download-center-uri}[Neo4j Deployment Center].
14+
. Verify the integrity of the downloaded file by checking the SHA-256 hash.
15+
It must match the hash provided on the download page below the download link.
16+
. Extract the contents of the archive, using `tar -xf` <filename> or by double-clicking the archive in Finder.
2117
. Place the extracted files in a permanent home on your server and set the environment variable `NEO4J_HOME` to point to the extracted directory, for example, `export NEO4J_HOME=/path/to/_<NEO4J_HOME>` to make it easier to refer to it later.
22-
. xref:configuration/file-locations.adoc#file-locations-file-locations[Change the default locations] of the _data_, _conf_, _certificates_, _licenses_, and _plugins_ (if you plan to use custom plugins) directories by setting the environment variable `NEO4J_CONF` and the respective xref:configuration/configuration-settings.adoc#_server_directories_settings[`server.directories.*`] settings to point to the desired locations.
18+
. (Optional) xref:configuration/file-locations.adoc#file-locations-file-locations[Change the default locations] of the _data_, _conf_, _certificates_, _licenses_, and _plugins_ (if you plan to use custom plugins) directories by setting the environment variable `NEO4J_CONF` and the respective xref:configuration/configuration-settings.adoc#_server_directories_settings[`server.directories.*`] settings to point to the desired locations.
2319
+
2420
[NOTE]
2521
====
2622
Storing your Neo4j files outside `NEO4J_HOME` will simplify the upgrade process later because you will be able to replace the DBMS binaries without affecting the configuration and state.
2723
Otherwise, these Neo4j files will remain in the old installation folder and may be accidentally overwritten during an upgrade or deleted during a subsequent uninstall.
2824
====
29-
. Accept either the commercial or the evaluation license agreement before running the Neo4j Enterprise Edition.
30-
If you are using Community Edition, you can skip this step.
31-
* Use one of the following options to accept the commercial license agreement.
32-
See the link:https://legal.neo4j.com/[Neo4j licensing] page for details on the available agreements.
33-
+
25+
. label:enterprise[Enterprise Edition] Accept either the commercial or the evaluation license agreement by one of the following methods:
26+
* Commercial license agreement (See the link:https://legal.neo4j.com/[Neo4j licensing] page for details on the available agreements.):
3427
** Set the environment variable `NEO4J_ACCEPT_LICENSE_AGREEMENT=yes`.
3528
** Run `$NEO4J_HOME/bin/neo4j-admin server license --accept-commercial`
36-
* Use one of the following options to accept the link:https://neo4j.com/terms/enterprise_us/[Neo4j Evaluation Agreement for Neo4j Software]:
37-
+
29+
* link:https://neo4j.com/terms/enterprise_us/[Neo4j Evaluation Agreement for Neo4j Software]:
3830
** Set the environment variable `NEO4J_ACCEPT_LICENSE_AGREEMENT=eval`.
3931
** Run `$NEO4J_HOME/bin/neo4j-admin server license --accept-evaluation`.
4032
. Before starting up the database for the first time, it is recommended to use the `set-initial-password` command of `neo4j-admin` to define the password for the native user `neo4j`.
@@ -45,18 +37,84 @@ For more information, see xref:configuration/set-initial-password.adoc[].
4537
. Start Neo4j:
4638
* To run Neo4j as a console application, use: `$NEO4J_HOME/bin/neo4j console`.
4739
* To run Neo4j in a background process, use: `$NEO4J_HOME/bin/neo4j start`.
48-
. Open _\http://localhost:7474/_ in your web browser.
40+
41+
== Install Neo4j as a macOS service
42+
43+
The easiest way to install Neo4j as a service on macOS is to use the Homebrew package manager (see https://brew.sh/[Homebrew installation instructions]).
44+
45+
. Install Neo4j using Homebrew:
46+
+
47+
[source, shell]
48+
----
49+
brew install neo4j
50+
----
51+
+
52+
This command installs Neo4j Community Edition and sets it up as a service that can be managed using Homebrew.
53+
. (Optional) If you want to change the default directories or other settings, you can do so in the `neo4j.conf` file located at `/opt/homebrew/Cellar/neo4j/{neo4j-version-exact}/libexec/conf/neo4j.conf`.
54+
If already started, changes to the configuration file will not take effect until you restart the Neo4j service using `brew services restart neo4j`.
55+
. Start Neo4j as a macOS service:
56+
+
57+
[source, shell]
58+
----
59+
brew services start neo4j
60+
----
61+
+
62+
This command starts the Neo4j service and sets it to launch automatically at system startup.
63+
. To check the status of the Neo4j service, use:
64+
+
65+
[source, shell]
66+
----
67+
brew services list
68+
----
69+
70+
Alternatively, if you prefer to install Neo4j manually, you can use the standard macOS system tools to create a service based on the `neo4j` command.
71+
72+
73+
== Access Neo4j
74+
75+
After starting Neo4j, you can access it using the Neo4j Aura console, Neo4j Browser, or Cypher Shell.
76+
77+
=== Using the Neo4j Aura console
78+
79+
By default, Neo4j Community Edition does not include graph tools such as visualization, data exploration, and monitoring.
80+
However, you can use the Neo4j Aura console to access these features in a cloud environment.
81+
82+
. Log in to the Aura Console at https://console.neo4j.io/.
83+
. Connect to your Neo4j server by entering the connection details, such as the server address and port.
84+
//To add an example.
4985
. Connect using the username `neo4j` with your password or the default password `neo4j`.
50-
You will then be prompted to change the password.
51-
. Stop the server by typing `Ctrl-C` in the console.
86+
If the default password is used, you will be prompted to change it upon first login.
87+
. Once connected, you can use the Aura Console to run Cypher queries, visualize graphs, and monitor your local Neo4j in the cloud environment.
5288

53-
When Neo4j runs in console mode, logs are printed to the terminal.
89+
=== Using Neo4j Browser (default)
90+
The Neo4j Browser is a web-based user interface for interacting with Neo4j.
91+
To access the Neo4j Browser, open a web browser and navigate to:
5492

93+
. _\http://localhost:7474/_ or the URL specified in your configuration.
94+
. Connect using the username `neo4j` with your password or the default password `neo4j`.
95+
If the default password is used, you will be prompted to change it upon first login.
5596

56-
== macOS service
97+
=== Using Cypher Shell
98+
Cypher Shell is a command-line tool for executing Cypher queries against a Neo4j database.
99+
To use Cypher Shell, run the following command in your terminal:
100+
[source, shell]
101+
----
102+
$NEO4J_HOME/bin/cypher-shell -u neo4j -p <your_password>
103+
----
104+
Replace `<your_password>` with the password you set for the `neo4j` user.
105+
If you did not set a password, use `neo4j` as the password.
106+
If you are running Neo4j in console mode, you can also run Cypher Shell in the same terminal session:
107+
[source, shell]
108+
----
109+
$NEO4J_HOME/bin/cypher-shell
110+
----
111+
This will connect to the Neo4j instance running in the same terminal.
57112

58-
Use the standard macOS system tools to create a service based on the `neo4j` command.
113+
== Logging
114+
Neo4j logs are written to the _logs_ directory under _NEO4J_HOME_.
115+
For detailed information about the log files, see xref:monitoring/logging.adoc[Logging].
59116

117+
When Neo4j runs in console mode, logs are printed to the terminal.
60118

61119
== macOS file descriptor limits
62120

0 commit comments

Comments
 (0)