Skip to content

Commit 3daa787

Browse files
committed
Update Redis configuration instructions for Magento 2 documentation to include session save settings and correct Redis CLI command.
1 parent c0cac35 commit 3daa787

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

docs/ecommerce-applications/magento-2/how-to-configure-redis-for-magento-2.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,6 +134,7 @@ After enabling the second Redis instance you need to change the configured Redis
134134
```console
135135
$ cd /data/web/magento2
136136
$ bin/magento setup:config:set \
137+
--session-save=redis \
137138
--session-save-redis-port=6378 \
138139
--session-save-redis-db=0
139140
```
@@ -149,15 +150,15 @@ Furthermore you need to add the following line to your crontab:
149150
To verify whether your configuration is working properly, first clear your session store:
150151

151152
```console
152-
$ rm /data/web/public/var/sessions/*
153+
$ rm /data/web/magento2/var/sessions/*
153154
```
154155

155156
Now open the site in your browser and hit `F5` a few times or log in to the admin panel. If all is well, no additional sessions files should be written to `/data/web/var/sessions`, but instead to the Redis database:
156157

157158
To verify whether your configuration is working properly, first clear your session store:
158159

159160
```console
160-
$ redis-cli -n 2 keys '*'
161+
$ redis-cli -p 6378 keys '*'
161162
```
162163

163164
## Troubleshooting

0 commit comments

Comments
 (0)