Return-Path: X-Original-To: apmail-cloudstack-issues-archive@www.apache.org Delivered-To: apmail-cloudstack-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4CDB818E3D for ; Wed, 9 Mar 2016 16:55:41 +0000 (UTC) Received: (qmail 47266 invoked by uid 500); 9 Mar 2016 16:55:41 -0000 Delivered-To: apmail-cloudstack-issues-archive@cloudstack.apache.org Received: (qmail 47229 invoked by uid 500); 9 Mar 2016 16:55:41 -0000 Mailing-List: contact issues-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list issues@cloudstack.apache.org Received: (qmail 47211 invoked by uid 500); 9 Mar 2016 16:55:40 -0000 Delivered-To: apmail-incubator-cloudstack-issues@incubator.apache.org Received: (qmail 47207 invoked by uid 99); 9 Mar 2016 16:55:40 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Mar 2016 16:55:40 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id C5FC92C1F58 for ; Wed, 9 Mar 2016 16:55:40 +0000 (UTC) Date: Wed, 9 Mar 2016 16:55:40 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: cloudstack-issues@incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CLOUDSTACK-9283) cloudstack-usage fails to start throwing Integer exception during PID retrieval MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CLOUDSTACK-9283?page=3Dcom.atla= ssian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId= =3D15187400#comment-15187400 ]=20 ASF GitHub Bot commented on CLOUDSTACK-9283: -------------------------------------------- Github user Slair1 commented on the pull request: https://github.com/apache/cloudstack/pull/1409#issuecomment-194394917 =20 FYI, this fix also worked for me, Cloudstack 4.8 on Centos7 > cloudstack-usage fails to start throwing Integer exception during PID ret= rieval > -------------------------------------------------------------------------= ------ > > Key: CLOUDSTACK-9283 > URL: https://issues.apache.org/jira/browse/CLOUDSTACK-928= 3 > Project: CloudStack > Issue Type: Bug > Security Level: Public(Anyone can view this level - this is the defa= ult.)=20 > Components: Usage > Affects Versions: 4.7.0 > Environment: CentOS 7, systemd, packages from official repo > Reporter: Linas =C5=BDilinskas > Assignee: David Amorim Faria > > I have very little knowledge of java, but I looked at the code where the = exception is thrown. The code is=20 > {code}_pid =3D Integer.parseInt(System.getProperty("pid"));{code}=20 > Based on the information I found, I guess the command line requires -Dpid= =3D$$ to be passed, which isn't. I modified the systemd service to include = the parameter and service now starts. I'm not sure if this is something spe= cific to my environment or not, but seems strange that this could go unnoti= ced. > {code} > 12:49:27,981 DEBUG UsageManagerImpl:187 - Checking to see if usage.vmops.= pid exists. > 12:49:27,982 INFO UsageManagerImpl:195 - Implementation Version is 4.7.0 > 12:49:28,737 DEBUG UsageManagerImpl:218 - Usage stats aggregation time zo= ne: GMT > 12:49:28,738 DEBUG UsageManagerImpl:250 - Execution Time: Wed Feb 10 12:2= 5:00 UTC 2016 > 12:49:28,738 DEBUG UsageManagerImpl:252 - Current Time: Wed Feb 10 12:49:= 28 UTC 2016 > java.lang.NumberFormatException: null > at java.lang.Integer.parseInt(Integer.java:542) > at java.lang.Integer.parseInt(Integer.java:615) > at com.cloud.usage.UsageManagerImpl.configure(UsageManagerImpl.ja= va:267) > at com.cloud.utils.component.ComponentContext.initComponentsLifeC= ycle(ComponentContext.java:116) > at com.cloud.usage.UsageServer.start(UsageServer.java:61) > at com.cloud.usage.UsageServer.main(UsageServer.java:47) > 12:49:28,745 DEBUG DefaultListableBeanFactory:243 - Returning cached inst= ance of singleton bean 'usageManagerImpl' > 12:49:28,745 INFO UsageServer:70 - UsageServer ready... > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)