@sharonyue You would need to modify the files inside your theme folder, e.g. /node_modules/nodebb-theme-persona/. Keep in mind, these files are overwritten when you update.
Power Off Droplet on DigitalOcean and save dump.rdb?
@SimonQ Yes that's a red flag...
Assuming the dump file is
/var/lib/redis/dump.rdb, who owns that? (Run
ls -lto find out)
@julian I redirected my dump so it is currently pointing to my root folder.
The owner is me
simonand it is a sudo user. Do I have to change this file? If so, how do I go about doing that?
I checked the default dump.rdb in
/var/lib/redis/dump.rdband owner is
redis. How would I change it to that?
If the dump file redis is configured to use is not owned by redis, or if it's permissions are too restrictive, then redis will not be able to write to it.
@julian I changed the ownership/group and permissions to follow that of the default dump.rdb in
sudo chown redis dump.rdband it loaded fine after I restarted nodebb. However, it does not seem to be reading the font awesome icons and I can not click my profile to to see the menu dropdown from there. It works on my mobile though.
Is there a way to test if my redis database can persist to the disk now?
Edit: Just tried logging into my mobile and am still greeted with the same error:
Failed login attempt, please try again.
MISCONF Redis is configured to save RDB snapshots, but is currently not able to press on disk. Commands that may modify the data sets are disabled. Please check Redis logs for details about the error
I then did
./nodeebb logand everything seems to be working with the exception of some warnings from of a few plugins.
10/7 10:50  - warn: [plugins/nodebb-plugin-dbsearch] This plugin may not be compatible with your version of NodeBB. This may cause unintended behaviour or crashing.
10/7 10:50  - warn: [plugins/nodebb-plugin-dbsearch] In the event of an unresponsive NodeBB caused by this plugin, run ./nodebb reset plugin="nodebb-plugin-dbsearch".
10/7 10:50  - warn: [plugins/nodebb-theme-lavender] This plugin may not be compatible with your version of NodeBB. This may cause unintended behaviour or crashing.
10/7 10:50  - warn: [plugins/nodebb-theme-lavender] In the event of an unresponsive NodeBB caused by this plugin, run ./nodebb reset plugin="nodebb-theme-lavender".
10/7 10:50  - info: [plugins/spam-be-gone] Settings loaded
10/7 10:50  - info: NodeBB Ready
10/7 10:50  - info: NodeBB is now listening on: 0.0.0.0:4567
I just checked
/var/log/redis/redis-server.logand although I have changed the ownership and group to redis and can confirm that it's not saving the .rdb with permission denied still:
933:M 10 Jul 11:42:00.054 * 1 changes in 900 seconds. Saving...
933:M 10 Jul 11:42:00.054 * Background saving started by pid 19861
19861:C 10 Jul 11:42:00.055 # Failed opening .rdb for saving: Permission denied
933:M 10 Jul 11:42:00.155 # Background saving error
The dump.rdb that redis is configured to use has the following that I recently changed to:
-rw-rw---- 1 simon simon 36296 Jul 8 16:50 dump.rdb
-rw-rw---- 1 redis redis 36296 Jul 8 16:50 dump.rdb
Is there another reason that the dump.rdb file is not saving?
@julian I think I managed to solve this problem, not 100% though
I changed the permission to
755for my working root directory and the dump.rdb permissions to
644. I also changed the ownership of my working root directory to redis as well.
redis-cli bgsaveand then checking the
redis-server.logI am greeted with this:
933:M 10 Jul 12:52:17.908 * Background saving started by pid 20754
20754:C 10 Jul 12:52:17.917 * DB saved on disk
20754:C 10 Jul 12:52:17.918 * RDB: 0 MB of memory used by copy-on-write
933:M 10 Jul 12:52:17.946 * Background saving terminated with success
It says 0MB of memory used by copy-on-write? Does this mean it saved?
Looks like you're good to go Hooray for problem solving!
@julian I got it to work however when I restarted the server I was greeted with an error upon starting nodebb up again. I found that the error was the
pidfilewas rewriting as
rootand I keep getting
./pidfile rewrite: operation deniedor something similar
more importantly when I try to do
./nodebb stopI get
Stopping NodeBB. Goodbye!
./nodebb: line 43: kill: (1843) - Operation not permitted
but works when I do
sudo ./nodebb stopsame with
sudo ./nodebb start
Is there a way to change that? This only happened since I changed the directory of the root folder to
redisin order to persist to the DB.
There's no need to keep the redis dump file in with your NodeBB install. Keeping it where it belongs (
/var/lib/redis) is best.
Then you can reset your NodeBB directory's permissions
@julian This may sound silly but, if I were to place the dump.rdb file back into
/var/lib/redis(from my NodeBB install) and reset my server from there would anything horrible go wrong?