

To enter the second redis instance interactive console. Open ~/Library/LaunchAgents/ and change the configuration as need so it will look like the below Open the nf and change the configuration for deamonize, pidfile, port, unixsocket, logfile and dbfilename to the belowĬp ~/Library/LaunchAgents/ ~/Library/LaunchAgents/Ĥ. Copy the default redis config file that is used for the default redis instance.Ĭp /usr/local/etc/nf /usr/local/etc/nfĢ. To set a new instance of redis, all you need is a new redis config file, start redis with that config file and you will have a second redis instance up and running.ġ. Ln -sfv /usr/local/opt/redis/*.plist ~/Library/LaunchAgents If you install redis with homebrew, you can see whats in the package like this: brew install redis brew ls redis You will see that it only installs very. # Will cause data loss for a period of time when the power is off.Install Redis with brew, if you don’t have brew installed yet, google how to install brew on Mac. Redis writes data to disk asynchronously by default. #Specify whether to log after each update operation. Copy the default redis config file that is used for the default redis instance. # Can close the # option, but it will cause the database file to become huge Install Redis and set multiple Redis instances on Mac OS 1.

#Specify whether to compress data when storing to the local database, the default is yes, Redis uses LZF compression, if in order to save CPU time, #RedisDefault configuration file provides three conditions: #Specify how many update operations within how long and how many times the data will be synchronized to the data file, multiple conditions can be matched #Set the number of databases, the default database is 0, you can use the SELECT command to specify the database id on the connection They all require you to have the XCode developer tools installed, which includes. Logfile /usr/local/redis-5.0.3/log-redis.log Installing on Mac OS X There are several ways to install Redis on Mac OS X. Modify the /usr/local/bin/nf configuration file Sudo cp /usr/local/redis-5.0.3/nf /usr/local/etc Sudo cp /usr/local/redis-3.2.5/src/redis-server /usr/local/binĬopy /usr/local/redis-5.0.3/nf to /usr/local/etc Sudo cp /usr/local/redis-3.2.5/src/redis-cli /usr/local/bin Sudo cp /usr/local/redis-3.2.5/src/redis-check-rdb /usr/local/bin Sudo cp /usr/local/redis-3.2.5/src/redis-benchmark /usr/local/bin Sudo cp /usr/local/redis-5.0.3/src/mkreleasehdr.sh /usr/local/bin (If the directory already exists, please ignore the above command, you can view it in the figure below, or use the command cd /usr/local to check whether the file exists)Ĭopy mkreleasehdr.sh, redis-benchmark, redis-check-rdb, redis-cli, redis-server under /usr/local/redis/src directory to /usr/local/bin directory


in the /usr/local directory, and create a db folder in the redis-5.0.3 directory Open the official website: the stable versionĪfter the download is complete, double-click to decompress, open the command line tool, and enterĬreate two folders, bin, etc.
