AEM 服务器在本地 运行,但本地主机拒绝连接

AEM server is running locally but localhost refuses to connect

我正在尝试 运行 在 mac 本地 运行 服务器上使用命令

的 AEM 站点

java -Xmx2048m -jar AEM_6.4_Quickstart.jar

我收到了回复:

Loading quickstart properties: default
Loading quickstart properties: instance
Low-memory action set to fork
Using 64bit VM settings, min.heap=1024MB, min permgen=256MB, default fork arguments=[-Xmx1024m, -XX:MaxPermSize=256m]
The JVM reports a heap size of 2048 MB, meets our expectation of 1024 MB +/- 20
Setting properties from filename '/Users/jimmymona/Development/OnBeat/TFS/AEM_6.4_Quickstart.jar'
Verbose option not active, closing stdin and redirecting stdout and stderr
Redirecting stdout to /Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/logs/stdout.log
Redirecting stderr to /Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/logs/stderr.log
Press CTRL-C to shutdown the Quickstart server...

/Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/logs/stdout.log 显示:

Loading quickstart properties: default
Loading quickstart properties: instance
Quickstart startup at Wed Jun 02 11:33:24 EDT 2021
UpgradeUtil.handleInstallAndUpgrade has mode RESTART
02.06.2021 11:33:24.188 *INFO * [main] Setting sling.home=/Users/jimmymona/Development/OnBeat/TFS/crx-quickstart (command line)
02.06.2021 11:33:24.189 *INFO * [main] Starting Apache Sling in /Users/jimmymona/Development/OnBeat/TFS/crx-quickstart
02.06.2021 11:33:24.191 *INFO * [main] Sling  Extension Lib Home : /Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/launchpad/ext
02.06.2021 11:33:24.195 *INFO * [main] Checking launcher JAR in folder /Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/launchpad
02.06.2021 11:33:24.205 *INFO * [main] Existing launcher is up to date, using it: 5.6.10.2_6_26 (org.apache.sling.launchpad.base.jar)
02.06.2021 11:33:24.206 *INFO * [main] Loading launcher class org.apache.sling.launchpad.base.app.MainDelegate from org.apache.sling.launchpad.base.jar
02.06.2021 11:33:24.206 *INFO * [main] External Libs Home (ext) is null or does not exists.
02.06.2021 11:33:24.213 *INFO * [main] Setting sling.properties=conf/sling.properties
02.06.2021 11:33:24.213 *INFO * [main] Setting sling.home=/Users/jimmymona/Development/OnBeat/TFS/crx-quickstart
02.06.2021 11:33:24.213 *INFO * [main] Setting sling.launchpad=/Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/launchpad
02.06.2021 11:33:24.213 *INFO * [main] Setting org.osgi.service.http.port=4502
02.06.2021 11:33:24.213 *INFO * [main] Starting launcher ...
02.06.2021 11:33:24.218 *INFO * [main] HTTP server port: 4502
02.06.2021 11:33:24.353 *INFO * [main] Startup completed

/Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/logs/stderr.log 显示:

Using 64bit VM settings, min.heap=1024MB, min permgen=256MB, default fork arguments=[-Xmx1024m, -XX:MaxPermSize=256m]
The JVM reports a heap size of 2048 MB, meets our expectation of 1024 MB +/- 20
Setting properties from filename '/Users/jimmymona/Development/OnBeat/TFS/AEM_6.4_Quickstart.jar'
Verbose option not active, closing stdin and redirecting stdout and stderr
Redirecting stdout to /Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/logs/stdout.log
Redirecting stderr to /Users/jimmymona/Development/OnBeat/TFS/crx-quickstart/logs/stderr.log
ResourceProvider paths=[/gui, /gui/default]

看起来一切 运行 都正常,但是 localhost:4502 显示“无法访问此站点”和“ERR_CONNECTION_REFUSED”。我没有 运行 任何代理,我的防火墙也关闭了,不知道还有什么要检查的。有什么想法吗?

是的,你必须找出哪个进程阻塞了 4502 端口,但你可以在不同的端口上启动 AEM,将你的 jar 重命名为 cq-author-p4504.jar,cq-author-p8080.jar,或任何其他端口。当然,您必须配置 maven 和任何其他工具或实用程序来部署您的代码,假定 4502 为默认端口。

尝试删除 crx-quickstart 文件夹并重新启动 jar。