Kanika Chandna
Kanika Chandna

Reputation: 7

Service Unavailable error while sending mqtt message on solace

I created a new message VPN on solace VMR and configured its SSL port as 8884 . Configured default ACL profile on it to allow publish and subscribe both . But when I am trying to publish any message on a topic such as "hellotopic" , I am getting an exception like :

Exception occoured Client is currently disconnecting (32102)
Connection lost on instance "123456" with cause "Connection lost" Reason code 32109" Cause "java.io.EOFException"
Connection lost (32109) - java.io.EOFException
    at org.eclipse.paho.client.mqttv3.internal.CommsReceiver.run(CommsReceiver.java:138)
    at java.lang.Thread.run(Thread.java:745)
Caused by: java.io.EOFException
    at java.io.DataInputStream.readByte(DataInputStream.java:267)
    at org.eclipse.paho.client.mqttv3.internal.wire.MqttInputStream.readMqttWireMessage(MqttInputStream.java:56)
    at org.eclipse.paho.client.mqttv3.internal.CommsReceiver.run(CommsReceiver.java:100)
    ... 1 more

While in solace VMR event logs , It gets connect and disconnects instantly: -

2016-09-13T13:12:16+0000 <local3.info> solace event: CLIENT: CLIENT_CLIENT_CONNECT_MQTT: publisher_VPN #mqtt/1251123gf/216 Client (108) #mqtt/1251123gf/216 username default ClientId (1251123gf) connected to XXX.XX.XX.XX:8884 from XXX.XX.XX.XX:59736 SslVersion(TLSv1.2) SslCipher(ECDHE-RSA-AES128-SHA256 TLSv1.2 Kx=ECDH Au=RSA Enc=AES(128) Mac=SHA256) authScheme(Basic) Clean(0) Will(0)

2016-09-13T13:12:16+0000 <local3.info> solace event: CLIENT: CLIENT_CLIENT_DISCONNECT_MQTT: publisher_VPN #mqtt/1251123gf/216 Client (108) #mqtt/1251123gf/216 username default ClientId (1251123gf) **reason(Service Unavailable)** final statistics - dp(1, 1, 0, 0, 1, 1, 25, 4, 0, 0, 25, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0) conn(0, 0, XXX.XX.XX.XX:59654, ESTAB, 0, 0, 0) mqtt(1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,0, 0, 0, 0), SslVersion(TLSv1.2), SslCipher(ECDHE-RSA-AES128-SHA256 TLSv1.2 Kx=ECDH Au=RSA Enc=AES(128) Mac=SHA256), WillSent(0). 

Tried to find solution of this , Got some information regarding I am not authorized to publish on following topic.

P.S. - I am able to publish messages on default VPN SSL port.

Upvotes: 0

Views: 800

Answers (2)

Magali
Magali

Reputation: 16

You said that you can publish messages at QoS 0 and not 1: did you configure a Spool size at your message VPN? You may want to have a look at the Product Documentation at (step 17) and add a size to the Maximum Spool Usage property:

Maximum Spool Usage

The maximum amount of message spool disk space (in MB) the Message VPN may use. Note: No policing is done to ensure that the sum of all of the message spool quota allocated to Message VPNs does not exceed the router-wide message spool quota.

By default, the value of this property is set to 0, you may try and set it to 5 or 10 (in MB).

Upvotes: 0

Alexandra Masse
Alexandra Masse

Reputation: 1297

The MQTT SSL service must be enabled for the Message VPN on the Solace VMR in order to have MQTT clients connect to the Message VPN's port.

To enable the MQTT SSL service with the CLI, you can use the following commands:

solace(configure)# message-vpn <vpn-name>
solace(configure/message-vpn)# service mqtt
solace(configure/message-vpn/service/mqtt)# no ssl shutdown

To enable the MQTT SSL service with SolAdmin, navigate to the 'Message VPNs, ACLs & Bridges' tab. Under the 'Message VPNs' view, right-click on the Message VPN and select 'Change Service Status'. There will be a pop-up window where you can enable each service individually.

Upvotes: 0

Related Questions