Repercussions of changing FreePBX Database from CLI

I started messing around with the database commands from the CLI, and I wanted to try changing the followme number in an extension from there. It seems to work, meaning that calls get redirected to the new number, simply by running something like:

database put AMPUSER 201/followme/grplist 123456789#

But I read in this post: CLI commands, that this isn’t the best way to do this and that it may cause problems. And that it’s better to change it in the MySQL database, and then run a fwconsole reload.

Is this still the case, and if so, what are the repercussions of changing them directly in the asterisk database rather than in the MySQL database?

Although it will work on a temporary basis, it will revert on a freepbx gui save or fwconsole reload

1 Like

I tested that out, and it doesn’t seem to be the case. Changing the followme number in the database with the command above also updates it in the GUI, and changing something else in the GUI and reloading doesn’t revert the changes. Is this field unique in that it does this, or am I not testing this properly?

I’m running FreePBX 14 with asterisk 16, if that makes any difference.

Are you actually looking at the MySQL database when you make the change in the AstDB via the CLI command? Because looking in the GUI is a skewed result as you have no idea where the GUI is actually sourcing its data from to display.

Make the change like you did and then look at the SQL tables that’s how you know if what you are doing is working the way you expect.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.