在线工具
网站地图    收藏    合作   
<

快捷菜单 返回顶部

php操作redis

返回上层

系统和通用函数 - info - 命令/方法/函数

Description

Returns an associative array from REDIS that provides information about the server. Passing no arguments to INFO will call the standard REDIS INFO command, which returns information such as the following:

返回redis的相关系统信息,类似于PHP的PHPINFO();可以选择参数,按照选择的参数返回相应的信息,也可以不写参数,返回所有的信息。

info可以查看redis当前占用的内存大小、当前系统信息、持久化信息、key数量等。


redis_version

arch_bits

uptime_in_seconds

uptime_in_days

connected_clients

connected_slaves

used_memory 内存使用情况

changes_since_last_save

bgsave_in_progress

last_save_time

total_connections_received

total_commands_processed

role

You can pass a variety of options to INFO (per the Redis documentation), which will modify what is returned.

你可以通过多种选择的信息(每使用文档),这将是返回修改。


Parameters

option: The option to provide redis (e.g. "COMMANDSTATS", "CPU")

option:redis提供一些选项(如"COMMANDSTATS", "CPU")


Example

$redis->info(); /* standard redis INFO command */

$redis->info("COMMANDSTATS"); /* Information on the commands that have been run (>=2.6 only)

$redis->info("CPU"); /* just CPU information from Redis INFO */


来源:https://www.daixiaorui.com/

自学PHP网专注网站建设学习,PHP程序学习,平面设计学习,以及操作系统学习

京ICP备14009008号@版权所有www.zixuephp.com

网站声明:本站所有视频,教程都由网友上传,站长收集和分享给大家学习使用,如由牵扯版权问题请联系站长邮箱904561283@qq.com