activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From samp <...@brightcove.com>
Subject Problem with pure master/slave
Date Sat, 13 Jun 2009 18:41:14 GMT

I'm trying to setup a pure master slave configuration. Startup looks fine,
but if the master stops, the slave also stops. I would have expected it to
stay up.  Below are the configs and relevant part of the slave log file. Any
guidance is greatly appreciated.

thanks
sam

Master config:
    <broker xmlns="http://activemq.apache.org/schema/core"
brokerName="master">

        <!-- Use the following to configure how ActiveMQ is exposed in JMX
-->
        <managementContext>
            <managementContext createConnector="true"/>
        </managementContext>

        <!-- The store and forward broker networks ActiveMQ will listen to
-->
        <networkConnectors>
            <networkConnector name="mynetwork"
uri="static://(tcp://localhost:61616)"/>
        </networkConnectors>

        <persistenceAdapter>
            <amqPersistenceAdapter syncOnWrite="false"
directory="activemq-master" maxFileLength="20 mb"/>
        </persistenceAdapter>

        <!--  The maximum about of space the broker will use before slowing
down producers -->
        <systemUsage>
            <systemUsage>
                <memoryUsage>
                    <memoryUsage limit="20 mb"/>
                </memoryUsage>
                <storeUsage>
                    <storeUsage limit="1 gb" name="foo"/>
                </storeUsage>
                <tempUsage>
                    <tempUsage limit="100 mb"/>
                </tempUsage>
            </systemUsage>
        </systemUsage>

        <transportConnectors>
            <transportConnector name="openwire"
uri="tcp://localhost:61616"/>
        </transportConnectors>

    </broker>


Slave config
    <broker xmlns="http://activemq.apache.org/schema/core" 
            brokerName="slave"
            masterConnectorURI="tcp://localhost:61616" 
            shutdownOnMasterFailure="false">

        <!-- Use the following to configure how ActiveMQ is exposed in JMX
-->
        <managementContext>
            <managementContext createConnector="true"/>
        </managementContext>

        <persistenceAdapter>
            <amqPersistenceAdapter syncOnWrite="false"
directory="activemq-slave" maxFileLength="20 mb"/>
        </persistenceAdapter>

        <!--  The maximum about of space the broker will use before slowing
down producers -->
        <systemUsage>
            <systemUsage>
                <memoryUsage>
                    <memoryUsage limit="20 mb"/>
                </memoryUsage>
                <storeUsage>
                    <storeUsage limit="1 gb" name="foo"/>
                </storeUsage>
                <tempUsage>
                    <tempUsage limit="100 mb"/>
                </tempUsage>
            </systemUsage>
        </systemUsage>

    </broker>

Slave log (at point of master failure)
[2009-06-13 14:38:38 -0400] [INFO ] org.apache.activemq.broker.BrokerService
- ActiveMQ JMS Message Broker (slave,
ID:samperman-ws-3708-1244918318032-1:0) started
[2009-06-13 14:38:48 -0400] [ERROR]
org.apache.activemq.broker.ft.MasterConnector - Network connection between
vm://slave#0 and tcp://localhost/127.0.0.1:61616 shutdown: null
java.io.EOFException
	at java.io.DataInputStream.readInt(DataInputStream.java:375)
	at
org.apache.activemq.openwire.OpenWireFormat.unmarshal(OpenWireFormat.java:269)
	at
org.apache.activemq.transport.tcp.TcpTransport.readCommand(TcpTransport.java:210)
	at
org.apache.activemq.transport.tcp.TcpTransport.doRun(TcpTransport.java:202)
	at
org.apache.activemq.transport.tcp.TcpTransport.run(TcpTransport.java:185)
	at java.lang.Thread.run(Thread.java:619)
[2009-06-13 14:38:48 -0400] [WARN ] org.apache.activemq.broker.BrokerService
- Master Failed - starting all connectors
[2009-06-13 14:38:48 -0400] [INFO ]
org.apache.activemq.broker.TransportConnector - Connector vm://slave Stopped
[2009-06-13 14:38:48 -0400] [INFO ] org.apache.activemq.broker.BrokerService
- ActiveMQ Message Broker (slave, ID:samperman-ws-3708-1244918318032-1:0) is
shutting down
[2009-06-13 14:38:48 -0400] [INFO ] org.apache.activemq.broker.BrokerService
- ActiveMQ JMS Message Broker (slave,
ID:samperman-ws-3708-1244918318032-1:0) stopped

-- 
View this message in context: http://www.nabble.com/Problem-with-pure-master-slave-tp24015184p24015184.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message