是否可以在 Azure 门户的 Redis 控制台中获取 redis-benchmark?
Is it possible to get redis-benchmark in Azure Portal's Redis Console?
我正在 运行在 Azure 中使用 Redis 缓存。 Azure 门户为 redis 服务器提供了一个控制台,用于 运行 redis 命令(get [key]
有效)。我想使用 redis-benchmarks 但它抛出一个错误:(error) ERR unknown command
。这有点令人困惑,因为 Redis 应该包括 redis-benchmark.
Redis includes the redis-benchmark utility that simulates running commands done by N clients at the same time sending M total queries (it is similar to the Apache's ab utility).
有没有办法让 redis-benchmark 正常工作?
这是文章中的示例命令:redis-benchmark -q -n 100000
Azure 中的控制台仅支持redis-cli。要使用 Redis-benchmark,需要在 Azure Redis Cache 中开启非 SSL 端口。更多详情 https://azure.microsoft.com/en-us/documentation/articles/cache-faq/#cache-commands
您不能 运行 redis-benchmark
在 redis-cli shell 中。它不是 redis 命令的一部分。尝试从常规 shell 提示 运行 redis-benchmark。
不工作:
C:\>redis-cli
127.0.0.1:6379> redis-benchmark -t set,get -r 1000000 -q
(error) ERR unknown command 'redis-benchmark'
工作:
C:\>redis-benchmark -t set,get -r 1000000 -q
SET: 111856.82 requests per second
GET: 108225.10 requests per second
您也可以从您的本地机器 运行 这些命令。检查这个 link
You can use any of the commands listed at Redis commands except for the commands listed at Redis commands not supported in Azure Cache for Redis. You have several options to run Redis commands.
- If you have a Standard or Premium cache, you can run Redis commands using the Redis Console. The Redis console provides a secure way to run Redis commands in the Azure portal.
- You can also use the Redis command-line tools. To use them, perform the following steps:
- Download the Redis command-line tools.
- Connect to the cache using redis-cli.exe. Pass in the cache endpoint using the -h switch and the key using -a as shown in the following example:
redis-cli -h .redis.cache.windows.net -a
我正在 运行在 Azure 中使用 Redis 缓存。 Azure 门户为 redis 服务器提供了一个控制台,用于 运行 redis 命令(get [key]
有效)。我想使用 redis-benchmarks 但它抛出一个错误:(error) ERR unknown command
。这有点令人困惑,因为 Redis 应该包括 redis-benchmark.
Redis includes the redis-benchmark utility that simulates running commands done by N clients at the same time sending M total queries (it is similar to the Apache's ab utility).
有没有办法让 redis-benchmark 正常工作?
这是文章中的示例命令:redis-benchmark -q -n 100000
Azure 中的控制台仅支持redis-cli。要使用 Redis-benchmark,需要在 Azure Redis Cache 中开启非 SSL 端口。更多详情 https://azure.microsoft.com/en-us/documentation/articles/cache-faq/#cache-commands
您不能 运行 redis-benchmark
在 redis-cli shell 中。它不是 redis 命令的一部分。尝试从常规 shell 提示 运行 redis-benchmark。
不工作:
C:\>redis-cli
127.0.0.1:6379> redis-benchmark -t set,get -r 1000000 -q
(error) ERR unknown command 'redis-benchmark'
工作:
C:\>redis-benchmark -t set,get -r 1000000 -q
SET: 111856.82 requests per second
GET: 108225.10 requests per second
您也可以从您的本地机器 运行 这些命令。检查这个 link
You can use any of the commands listed at Redis commands except for the commands listed at Redis commands not supported in Azure Cache for Redis. You have several options to run Redis commands.
- If you have a Standard or Premium cache, you can run Redis commands using the Redis Console. The Redis console provides a secure way to run Redis commands in the Azure portal.
- You can also use the Redis command-line tools. To use them, perform the following steps:
- Download the Redis command-line tools.
- Connect to the cache using redis-cli.exe. Pass in the cache endpoint using the -h switch and the key using -a as shown in the following example: redis-cli -h .redis.cache.windows.net -a