Hi Mitch,
Hard to tell exactly after fiddling much with fop2 configuration files. If you are not using FreePBX/Issabel/Mirta, but a custom backend, then some special consideration is needed, and some clarifications on how the big scheme of things works in FOP2:
Stock config files (and auto config scripts) rely on getting user/buttons configuration from the FOP2 Manager.
FOP2 Manager needs to access a database to store its own data, and perhaps to retrieve backend data. If it recognizes a known installed backend, it will read mysql credentials for its config file and use those. If that connection fails, it will try to use the one defined in config.php (note you have two config.php, one for fop2 and one for fop2 manager in directory fop2/admin)
If you can log into FOP2 Manager and add users, then MySQL access was successful
If you remove/comment the #exec autoconfig-users.sh line in fop2.cfg, then nothing you do on FOP2 Manager will work, nor users you create or buttons you add via web will work. ever.
Mixing manually created users in fop2.cfg and leaving the #exec line to mix results with FOP2 Manager will not work as expected. It might work sometimes, or not other times, depends on order of things, so, just don't do it.
If no backend is detected, but credentials to access a specific database in fop2/admin/config.php are correct, and you have a tablesnamed sippeers or files like /etc/asterisk/sip.conf, it will attempt to read config from that source, using some static rules that might be fine, or not, depending on your setup,. You can modify functions-custom.php in FOP2 Manager to suit your needs in that case. In general, a sip.conf entry with callerid will be added as an extension, a sip.conf entry without callerid will be added as a trunk.
If possible, try to use the FOP2 Manager and adapt functions-custom.php when using a custom backend to populate FOP2 internal configs, as uers/permissions and plugins can be still managed and you will limit the user errorness of a fully manual installation.
I am sorry I cannot tell you what happened in your installation in this post, you can try to catch me on the live help and we can review your install together and see how it goes from there. But hopefully all of the above might shed some light to other users wanting to get FOP2 working with their custom setups.
Best regards,