I know that to enable logging through admin you can go:
System > Configuration > Advanced > Developer > Log Settings > Enable
But is there any way to enable it through database? As I don't have access to admin.
You can normally locate your Magento 2 error logs in {project root}\var\log\exception. log .
You can view the logs from the file system, the project web UI, and the magento-cloud CLI. File system—The /var/log system directory contains logs for all environments. The var/log/ directory contains app-specific logs unique to a particular environment.
All settings appearing in System / Configuration are stored in the core_config_data
table.
The one you're searching is dev/log/active
.
Be careful, in this table, you can have different values for each stores
Change variable values in the file lib/Varien/Db/Adapter/Pdo/Mysql.php to
$_debug = true;
$_logQueryTime = 0.05;
$_logAllQueries = true;
$_logCallStack = false;
$_debugFile = 'var/debug/pdo_mysql.log';
This will print out the sql queries
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With