Problems running sim or bootstrap mode of the Server

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

Problems running sim or bootstrap mode of the Server

nhartlie
Hy Folks,

i recently downloaded the current version of the powertac server and imported it into STS (i had to download the modules one by one because the script wasn't working any more). After I imported everything and did the building stuff, i wanted to start a simulation in bootstrap mode and then one in sim mode (i haven't changed any of the settings). Both times I'm getting the following errors in the powertac server logs:

0 WARN  interfaces.ServerProperties: Cannot find config/server.properties
1 ERROR interfaces.ServerProperties: Cannot find server config file config/test.properties
2 INFO  server.CompetitionSetupService: preGame() - start


Because the boot-data.xml file was created in bootstrap mode, I thought that I don't really have to care about the errors and started a "real" simulation. The server seems to start, but I'm not able to connect via jms, as I could before.

Is this correlated to the errors in the logs or has the process of logging in changed? I assume the jms location is the same as before (so the version of beginning of december)..

Any suggestions?

thanks, nikolaus
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

nhartlie
ok, i figured out that i had to change the parameters in the bootstrap file to

bootstrap --config ../server-master/server-distribution/config/test.properties

at least the error line of the log file does not appear any more, but i still can't connect to the server...

also when using the demo agent the server is never starting.... (so the status in the upper right corner never changes)

ideas?

best regards

Nikolaus
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

nhartlie
Could anyone possibly try to connect to the server using the grails Demo agent.

Thanks, nikolaus

PS: Happy new year to all of you ;)
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

grampajohn
Administrator
nhartlie wrote
Could anyone possibly try to connect to the server using the grails Demo agent.
I cannot get it to work either. I'll get an answer ASAP and let you all know.

John
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

grampajohn
Administrator
In reply to this post by nhartlie
nhartlie wrote
Could anyone possibly try to connect to the server using the grails Demo agent.
I have pushed a change to the development branch (0.2.0-SNAPSHOT) that fixes this problem. Is this also a problem in the 0.1.0 release? If so, I'll add this fix to some customer-model updates and get those pushed out in the next couple of days.

Cheers -

John
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

nhartlie
Thanks for the update...

grampajohn wrote
Is this also a problem in the 0.1.0 release?
As far as I can assess that, the 0.1.0 release is working correctly..

cheers nikolaus
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

nhartlie
Hi everyone,

because of some changes in the common package, I downloaded the newest version of powertac-server of the master branch, installed it and imported it into STS. Of course I did the same for the common package.

When I tried to run the server in bootstrap mode, I'm now getting some problems with factored-customer plugin.

The error message displayed at the console is as follows:

1806 [main] INFO org.apache.activemq.broker.BrokerService - Using Persistence Adapter: MemoryPersistenceAdapter
1810 [main] INFO org.apache.activemq.broker.BrokerService - ActiveMQ 5.5.1 JMS Message Broker (localhost) is starting
1810 [main] INFO org.apache.activemq.broker.BrokerService - For help or more information please see: http://activemq.apache.org/
1831 [JMX connector] INFO org.apache.activemq.broker.jmx.ManagementContext - JMX consoles can connect to service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi
1998 [main] INFO org.apache.activemq.transport.TransportServerThreadSupport - Listening for connections at: tcp://127.0.0.1:61616
1998 [main] INFO org.apache.activemq.broker.TransportConnector - Connector tcp://localhost:61616 Started
2001 [main] INFO org.apache.activemq.broker.BrokerService - ActiveMQ JMS Message Broker (localhost, ID:Niko-PC-50002-1326277216924-0:1) started
Exception in thread "Thread-9" java.lang.NullPointerException
        at org.powertac.factoredcustomer.CapacityManager.adjustCapacityForWeather(CapacityManager.java:163)
        at org.powertac.factoredcustomer.CapacityManager.useCapacity(CapacityManager.java:132)
        at org.powertac.factoredcustomer.CapacityBundle.useCapacity(CapacityBundle.java:93)
        at org.powertac.factoredcustomer.UtilityOptimizer.consumePower(UtilityOptimizer.java:480)
        at org.powertac.factoredcustomer.UtilityOptimizer.handleNewTimeslot(UtilityOptimizer.java:440)
        at org.powertac.factoredcustomer.FactoredCustomer.handleNewTimeslot(FactoredCustomer.java:97)
        at org.powertac.factoredcustomer.FactoredCustomerService.activate(FactoredCustomerService.java:134)
        at org.powertac.server.CompetitionControlService.step(CompetitionControlService.java:541)
        at org.powertac.server.CompetitionControlService.access$8(CompetitionControlService.java:532)
        at org.powertac.server.CompetitionControlService$SimRunner.run(CompetitionControlService.java:771)
log4j:ERROR Attempted to append to closed appender named [null].
6545 [ActiveMQ ShutdownHook] INFO org.apache.activemq.broker.BrokerService - ActiveMQ Message Broker (localhost, ID:Niko-PC-50002-1326277216924-0:1) is shutting down
6545 [Thread-2] INFO org.apache.activemq.broker.BrokerService - ActiveMQ Message Broker (localhost, ID:Niko-PC-50002-1326277216924-0:1) is shutting down
log4j:ERROR Attempted to append to closed appender named [null].
6555 [Thread-2] INFO org.apache.activemq.broker.TransportConnector - Connector tcp://localhost:61616 Stopped
6555 [ActiveMQ ShutdownHook] INFO org.apache.activemq.broker.TransportConnector - Connector tcp://localhost:61616 Stopped
log4j:ERROR Attempted to append to closed appender named [null].
6560 [Thread-2] ERROR org.apache.activemq.broker.jmx.ManagementContext - Could not stop service: org.apache.activemq.broker.jmx.ManagementContext@1fe3e859. Reason: javax.management.InstanceNotFoundException: org.apache.activemq:BrokerName=localhost,Type=Queue,Destination=serverInput
javax.management.InstanceNotFoundException: org.apache.activemq:BrokerName=localhost,Type=Queue,Destination=serverInput
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.getMBean(DefaultMBeanServerInterceptor.java:1095)
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.exclusiveUnregisterMBean(DefaultMBeanServerInterceptor.java:427)
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.unregisterMBean(DefaultMBeanServerInterceptor.java:415)
        at com.sun.jmx.mbeanserver.JmxMBeanServer.unregisterMBean(JmxMBeanServer.java:536)
        at org.apache.activemq.broker.jmx.ManagementContext.stop(ManagementContext.java:120)
        at org.apache.activemq.util.ServiceStopper.stop(ServiceStopper.java:41)
        at org.apache.activemq.broker.BrokerService.stop(BrokerService.java:599)
        at org.apache.activemq.xbean.XBeanBrokerService.destroy(XBeanBrokerService.java:86)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleElement.invoke(InitDestroyAnnotationBeanPostProcessor.java:340)
        at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor$LifecycleMetadata.invokeDestroyMethods(InitDestroyAnnotationBeanPostProcessor.java:305)
        at org.springframework.beans.factory.annotation.InitDestroyAnnotationBeanPostProcessor.postProcessBeforeDestruction(InitDestroyAnnotationBeanPostProcessor.java:148)
        at org.springframework.beans.factory.support.DisposableBeanAdapter.destroy(DisposableBeanAdapter.java:166)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.destroyBean(DefaultSingletonBeanRegistry.java:487)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.destroySingleton(DefaultSingletonBeanRegistry.java:463)
        at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.destroySingletons(DefaultSingletonBeanRegistry.java:431)
        at org.springframework.context.support.AbstractApplicationContext.destroyBeans(AbstractApplicationContext.java:1048)
        at org.springframework.context.support.AbstractApplicationContext.doClose(AbstractApplicationContext.java:1022)
        at org.springframework.context.support.AbstractApplicationContext$3.run(AbstractApplicationContext.java:940)
6564 [ActiveMQ ShutdownHook] INFO org.apache.activemq.broker.BrokerService - ActiveMQ JMS Message Broker (localhost, ID:Niko-PC-50002-1326277216924-0:1) stopped
6564 [Thread-2] INFO org.apache.activemq.broker.BrokerService - ActiveMQ JMS Message Broker (localhost, ID:Niko-PC-50002-1326277216924-0:1) stopped
log4j:ERROR Attempted to append to closed appender named [null].



Has anyone of you experienced the same or has a solution respectively?

Thanks, Nikolaus
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

nhartlie
ok, I figured out, that there is something wrong with the weather data itself. I tried to run a bootstrap sim with having the factored-customer plugin excluded and it worked. But when I now look into the boot-data.xml file, there is no weather data included....

Any suggestions?

cheers Nikolaus
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

nhartlie
after reading the log file I found the following error message:

3814 INFO  server.WeatherService: Timeslot 58 WeatherService reports time to make network request for weather data in blocking = true mode.
4224 ERROR server.WeatherService: Exception Raised during newtork call: java.io.IOException: Server returned HTTP response code: 500 for URL: http://tac06.cs.umn.edu:8080/powertac-weather-server/weatherSet/weatherRequest?id=0&setname=default&weather_days=1&weather_id=1

When I tried to open this url in my browser, I get an error, that there are too many connections...

Error 500: Executing action [weatherRequest] of controller [powertac.weather.server.WeatherSetController] caused exception: com.mysql.jdbc.exceptions.MySQLNonTransientConnectionException: Too many connections
Servlet: grails
URI: /powertac-weather-server/grails/weatherSet/weatherRequest.dispatch
Exception Message: Too many connections
Caused by: Too many connections
Class: WeatherSetController
At Line: [43]
Code Snippet:




Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

nhartlie
I have no idea what has changed, but now it's working again....

Sorry for any inconveniences,

cheers Nikolaus
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

grampajohn
Administrator
nhartlie wrote
I have no idea what has changed, but now it's working again....
I believe there was a network outage this morning on campus. Some system upgrades being done before the start of a new semester next week. Sorry for the confusion - there should perhaps be a better error message when this happens.

Cheers -

John
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

Prashant Reddy
Hi all,

On a related note, I have run into issues with the weather service not
being available or me not having web connectivity when I was trying to
run the server.  Would it make sense to be able to configure the
server, for testing purposes, to load the default data from a local
file deployed with the server?  I understand that the datasets can get
huge, but if it's for a single date/location, it shouldn't be too big?
 If it really is unreasonably large, we could make it an optional
download for server developers?

Thanks,
Prashant
Reply | Threaded
Open this post in threaded view
|

Re: Problems running sim or bootstrap mode of the Server

grampajohn
Administrator
Prashant Reddy wrote
I have run into issues with the weather service not being available...  Could make it an optional download for server developers?
Thanks, Prashant. That's a good idea. I've added as issue #473, and I'll discuss it with our weather guys.

John