
Security News
New CVE Forecasting Tool Predicts 47,000 Disclosures in 2025
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Export redis keys with a prefix or matching a pattern, import from exported file
Export redis keys with a given prefix or pattern, which later can be imported to another redis server. To export all keys, use '*' as pattern.
To install redis-export, simply:
.. code-block:: bash
$ python3 -m pip install redis-export
You should add ~/.local/bin/ to your PATH.
.. code-block:: bash
redis-export PREFIX_OR_PATTERN OUTPUT_FILE redis-import INPUT_FILE
For example,
.. code-block:: bash
redis-export 'phonebook:' ~/d/t1.json
redis-import --host redis.example.com ~/d/t1.json
For more usage help, run the command with --help
option.
redis-export will export keys with given pattern to a json file (keys and values both base64 encoded).
redis-import will import those keys and values back to redis.
Exported file is a json list, each list item is of form (key, dump_value). The redis key and dump value is encoded in base64 in order to fit in regular json.
Source code is hosted at https://gitlab.emacsos.com/sylecn/redis-export
You may clone it via ssh or https protocol
.. code-block:: bash
git clone git@gitlab.emacsos.com:sylecn/redis-export.git git clone https://gitlab.emacsos.com/sylecn/redis-export.git
Copyright (C) 2022, 2023 Yuanle Song sylecn@gmail.com
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
v0.3.0 2023-03-13
v0.2.0 2022-09-24
v0.1.2 2022-09-18
v0.1.0 2021-11-21
FAQs
Export redis keys with a prefix or matching a pattern, import from exported file
We found that redis-export demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
CVEForecast.org uses machine learning to project a record-breaking surge in vulnerability disclosures in 2025.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.