2

我已经下载了带有 tomcat 的 liferay 包。
我将它解压到我的 macApplications/Administrating/liferay....
我已经运行./startup.sh
并且在 exnd 我得到:INFO: Server startup in 47781 ms
但是当我localhost:8080在浏览器中打开时,我得到"No data received"就像没有安装站点一样。
这是整个日志:

Using CATALINA_BASE:   /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40
Using CATALINA_HOME:   /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40
Using CATALINA_TMPDIR: /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/temp
Using JRE_HOME:        /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home
Using CLASSPATH:       /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/bin/bootstrap.jar:/Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/bin/tomcat-juli.jar
STSiMacVVU:bin vladimirvucetic$ tail -f ../logs/catalina.out 
Oct 21, 2013 2:30:04 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
Oct 21, 2013 2:30:04 PM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 665 ms
Oct 21, 2013 2:30:04 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
Oct 21, 2013 2:30:04 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.40
Oct 21, 2013 2:30:04 PM org.apache.catalina.startup.HostConfig deployDescriptor
INFO: Deploying configuration descriptor /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/conf/Catalina/localhost/ROOT.xml
Loading jar:file:/Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/webapps/ROOT/WEB-INF/lib/portal-impl.jar!/system.properties
Loading jar:file:/Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/webapps/ROOT/WEB-INF/lib/portal-impl.jar!/portal.properties
Oct 21, 2013 2:30:16 PM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring root WebApplicationContext
14:30:21,037 INFO  [localhost-startStop-1][DialectDetector:71] Determine dialect for HSQL Database Engine 2
14:30:21,040 WARN  [localhost-startStop-1][DialectDetector:86] Liferay is configured to use Hypersonic as its database. Do NOT use Hypersonic in production. Hypersonic is an embedded database useful for development and demo'ing purposes. The database settings can be changed in portal-ext.properties.
14:30:21,084 INFO  [localhost-startStop-1][DialectDetector:136] Found dialect org.hibernate.dialect.HSQLDialect
14:30:36,629 WARN  [localhost-startStop-1][PDFProcessorImpl:235] Liferay is not configured to use ImageMagick. For better quality document and image previews, install ImageMagick and enable it in portal-ext.properties or in the Server Administration control panel at: http://<server>/group/control_panel/manage/-/server/external-services
Starting Liferay Portal Community Edition 6.1.2 CE (Paton / Build 6102 / August 2, 2013)
14:30:41,605 INFO  [localhost-startStop-1][BaseDB:478] Database supports case sensitive queries
14:30:42,056 INFO  [localhost-startStop-1][ServerDetector:169] Server supports hot deploy
14:30:42,064 INFO  [localhost-startStop-1][PluginPackageUtil:1046] Reading plugin package for the root context
14:30:44,914 INFO  [localhost-startStop-1][AutoDeployDir:144] Auto deploy scanner started for /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/deploy
Oct 21, 2013 2:30:48 PM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring FrameworkServlet 'Remoting Servlet'
Oct 21, 2013 2:30:49 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/webapps/marketplace-portlet
Oct 21, 2013 2:30:50 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/webapps/portal-compat-hook
Oct 21, 2013 2:30:51 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/webapps/resources-importer-web
Oct 21, 2013 2:30:51 PM org.apache.catalina.startup.HostConfig deployDirectory
INFO: Deploying web application directory /Applications/Administrating/liferay-portal-6.1.2-ce-ga3/tomcat-7.0.40/webapps/welcome-theme
Oct 21, 2013 2:30:52 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
Oct 21, 2013 2:30:52 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 47781 ms

我在这里想念什么?

4

7 回答 7

1

看起来 Liferay 正常启动(但添加更多信息 - catalina.out 或其他,正如玩家在评论中要求的那样)

还:

  • 检查防火墙设置(8080 可能被阻止)
  • 您的 lsof 输出列出了 IPV6(我已经很久没有解释 lsof 输出和命令行了 - 这可能是正常的,也可能不是。您不会说您是否尝试 IPV4 连接)
  • 尝试从该服务器连接浏览器。如果它是纯 shell 服务器,请使用 w3m 或 lynxhttp://localhost:8080/

    #用户没有人;worker_processes 1;

    events {
        worker_connections  1024;
    }
    
    
    http {
        passenger_root /var/lib/gems/1.9.1/gems/passenger-4.0.5;
        passenger_ruby /usr/bin/ruby1.9.1;
        passenger_max_pool_size 10;
        include       mime.types;
        default_type  application/octet-stream;
        sendfile        on;
        keepalive_timeout  65;
    
        gzip  on;
    
        server {
          listen       80;
          server_name  localhost;
          access_log /var/www/access.log;
          error_log  /var/www/error.log;
    
         location / {
            root   /var/www/demo/public;
            passenger_enabled on;
            rails_env production;
         }
    
         error_page   500 502 503 504  /50x.html;
         location = /50x.html {
            root   html;
        }
    }
    
于 2013-10-31T06:22:12.117 回答
1

一个好的起点是检查 tomcat 是否在端口 8080 上接收请求;在您的命令行类型中:

telnet localhost 8080

如果出现黑屏/空屏,则说明 Tomcat 确实在侦听该端口,否则会出现连接失败,那么您需要仔细检查您的 Tomcat 配置。

于 2013-10-30T20:51:45.680 回答
0

如果您从 Eclipse 运行服务器,请转到服务器 -> 端口并将 HTTP/1.1 设置为 8080 在此处输入图像描述

如果您正在运行独立的 Tomcat,请编辑 tomcat/conf/server.xml 并设置

<Connector URIEncoding="UTF-8" connectionTimeout="20000" port="8080" protocol="HTTP/1.1" redirectPort="8443"/>

确保服务器允许端口 8080,并且它没有被其他应用程序使用当服务器启动时,您应该能够在日志中读取以下内容:

org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
于 2013-10-24T12:29:34.160 回答
0

我的期望是在日志中找到这个:

24.10.2013 13:43:14 org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
24.10.2013 13:43:14 org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]

这将指示启动 8080 的协议处理程序。

我的建议是找到问题的根本原因是:

  • 在启动 Liferaylocalhost:8080 之前访问。这可能会给您相同的结果,表明在端口 8080 上运行了一些其他软件。
  • 如果这没有帮助:再次下载 Liferay tomcat 包,将原样解压缩到一个新位置,同样运行那个原样 - 如果这个有效,比较两个目录,尤其是 tomcat 的/conf/目录。
  • 如果这不起作用,请检查您的环境是否定义了任何变量 CATALINA_HOME、CATALINA_BASE、LIFERAY_HOME。
  • 您只需运行一个命令(如./bin/catalina.sh run. tail这将在前台运行 tomcat,从头开始显示日志,而不会因为命令来得太晚而错过任何内容
于 2013-10-24T14:29:22.377 回答
0

您尚未配置连接器端口 8080,因此您不会得到响应。从日志中可以看出,您配置的唯一连接器是端口 8009 上的 AJP。

Oct 21, 2013 2:30:04 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
于 2013-10-21T14:14:07.827 回答
0

可能有其他进程使用端口 8080。使用以下命令检查它:

sudo netstat -lnp | grep ':8080'

杀死正在运行的进程

sudo kill -9 {PID}

例如

sudo kill -9 1234

重新启动 Tomcat(如果作为服务安装)

service tomcat7 restart
于 2013-10-28T21:22:18.847 回答
0

几个月前我错误地为 CATALINA_HOME 设置了一个环境变量,指向不同的 tomcat 设置,这导致端口 8080 被旧设置调用,因此在 Liferay 使用它之前被保留。确保您的 CATALINA_HOME 变量配置为指向与 Liferay 捆绑的 tomcat。

于 2021-10-05T17:42:18.323 回答