php bin/magento deploy:mode:set production Enabling maintenance mode Starting compilation Something went wrong while compiling generated code. See the error log for details. Disabling maintenance mode Command returned non-zero exit code: `/usr/bin/php -f /var/www/html/bin/magento setup:di:compile`
And when i see error log its an error of memory limit. I increase the memory limit in php.ini file but i think this is not the right solution.