How can I verify which version of rabbitmq is running on a server?
Is there a command to verify that rabbitmq is running?
On debian systems, you can just run:
dpkg-query --showformat='${Version}' --show rabbitmq-server
If you have no access to rabbitmqctl or rabbitmq-server is not running, on linux do :
ls /usr/lib/rabbitmq/lib/
I got :
rabbitmq_server-3.5.6
sudo rabbitmqctl status
and look for line that looks like that:
{rabbit,"RabbitMQ","2.6.1"},
I use following command to trim output down to version,
rabbitmqctl status | grep "{rabbit,\"RabbitMQ\""
Output:
{rabbit,"RabbitMQ","3.7.3"},
Login to management ui and in top right you can find the version. Also use the following command to find the version
# sudo bash
# rabbitmqctl status | grep rabbit
To get RMQ version using C#
using (var connection = connectionFactory.CreateConnection())
{
if (connection.ServerProperties.ContainsKey("version"))
Console.WriteLine("Version={0}",
Encoding.UTF8.GetString((byte[])connection.ServerProperties["version"]));
}
Output:
Version=3.6.3