Error in deploy my application Symfony [duplicate] - symfony

This question already has answers here:
Moving app to production mode in Symfony 2
(5 answers)
Closed 8 years ago.
I am trying to deploy my code on the server.
I followed these steps:
clear cache
update vendor
add configuration of my remote database
change the value of access cache and log
But I'm getting this error:
Fatal error: Uncaught exception 'Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException' with message 'You have requested a non-existent parameter "kernel.debug".' in /home/public_html/demo/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/ParameterBag/ParameterBag.php:106
Stack trace: #0 /home/public_html/demo/app/bootstrap.php.cache(1959): Symfony\Component\DependencyInjection\ParameterBag\ParameterBag->get('kernel.debug')
#1 /home/public_html/demo/vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/FrameworkBundle.php(85): Symfony\Component\DependencyInjection\Container->getParameter('kernel.debug')
#2 /home/public_html/demo/app/bootstrap.php.cache(2562): Symfony\Bundle\FrameworkBundle\FrameworkBundle->build(Object(Symfony\Component\DependencyInjection\ContainerBuilder))
#3 /home/public_html/demo/app/bootstrap.php.cache(2542): Symfony\Component\HttpKernel\Kernel->prepareContainer(Object(Symfony\Component\DependencyInjection\ContainerBuilde in /home/public_html/demo/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/ParameterBag/ParameterBag.php on line 106

As you can see, this error is being thrown in bootstrap.php.cache.
Symfony uses a bootstrap file to improve class loading performance, as documented here. However, you presumably copied this file over from your development environment, and it hasn't yet been regenerated for production.
You will need to regenerate this file either by running composer install or by running the build script directly: php ./vendor/sensio/distribution-bundle/Sensio/Bundle/DistributionBundle/Resources/bin/build_bootstrap.php

Related

Wordpress - After I import Wordpress file while using All-In-One Migration, then I closed the browser? it shown error like this

After I import Wordpress file while using All-In-One Migration, then I closed the browser. it shown error like this. (I used Hostinger Hosting)
Fatal error: Uncaught Error: Class 'ComposerAutoloaderInit564f0d7c7a3ed0753d301c1d6e444524' not found in /home/u218179303/domains/manavissolutions.com/public_html/wp-content/plugins/all-in-one-seo-pack/vendor/autoload.php:7 Stack trace: #0 /home/u218179303/domains/manavissolutions.com/public_html/wp-content/plugins/all-in-one-seo-pack/app/AIOSEO.php(212): require() #1 /home/u218179303/domains/manavissolutions.com/public_html/wp-content/plugins/all-in-one-seo-pack/app/AIOSEO.php(153): AIOSEO\Plugin\AIOSEO->includes() #2 /home/u218179303/domains/manavissolutions.com/public_html/wp-content/plugins/all-in-one-seo-pack/app/AIOSEO.php(137): AIOSEO\Plugin\AIOSEO->init() #3 /home/u218179303/domains/manavissolutions.com/public_html/wp-content/plugins/all-in-one-seo-pack/app/AIOSEO.php(368): AIOSEO\Plugin\AIOSEO::instance() #4 /home/u218179303/domains/manavissolutions.com/public_html/wp-content/plugins/all-in-one-seo-pack/all_in_one_seo_pack.php(87): aioseo() #5 /home/u218179303/domains/manavissolutions.com/public_html/wp-settings. in /home/u218179303/domains/manavissolutions.com/public_html/wp-content/plugins/all-in-one-seo-pack/vendor/autoload.php on line 7
There has been a critical error on this website.
Learn more about troubleshooting WordPress.
How do we fix this address?

How to solve this error related to a WordPress upgrade on the server?

WordPress error on live website:
I can not understand what the error means. This error happened when I updated the WordPress version.
Error like this :
Deprecated: date.php is deprecated since version 5.3.0! Use wp-includes/class-wp-date-query.php instead. in /home/stageberide/public_html/public/blog/wp-includes/functions.php on line 4967
Deprecated: class-oembed.php is deprecated since version 5.3.0! Use wp-includes/class-wp-oembed.php instead. in /home/stageberide/public_html/public/blog/wp-includes/functions.php on line 4967
Fatal error: Uncaught Error: Call to undefined function wp_recovery_mode() in /home/stageberide/public_html/public/blog/wp-includes/load.php:870 Stack trace: #0 /home/stageberide/public_html/public/blog/wp-includes/load.php(754): wp_is_recovery_mode() #1 /home/stageberide/public_html/public/blog/wp-settings.php(303): wp_get_active_and_valid_plugins() #2 /home/stageberide/public_html/public/blog/wp-config.php(89): require_once('/home/stageberi...') #3 /home/stageberide/public_html/public/blog/wp-load.php(37): require_once('/home/stageberi...') #4 /home/stageberide/public_html/public/blog/wp-admin/admin.php(34): require_once('/home/stageberi...') #5 /home/stageberide/public_html/public/blog/wp-admin/index.php(10): require_once('/home/stageberi...') #6 {main} thrown in /home/stageberide/public_html/public/blog/wp-includes/load.php on line 870
first of all, create backup on your hosting provider. then,
Try downloading WordPress again, access your server via SFTP or FTP, or a file manager in your hosting account’s control panel (consult your hosting provider’s documentation for specifics on these), and delete then replace your copies of everything on the server except the wp-config.php file and the /wp-content/ directory with fresh copies from the download. This will effectively replace all of your core files without damaging your content and settings.
Some uploaders tend to be unreliable when overwriting files, so don’t forget to delete the original files before replacing them.

How to fix chmod errors when updating wordpress theme?

I recently upgraded from php 5 to 7.2 and my wp site didnt work, service temporarily unavailable error. So I logged into the backend and WP 5.4 was telling me I needed to check security issues of which I resolved 2 of 3 automatically but 1 could not which is "restrict access to files and folders". So I tried to update the 2017 theme and when I do so I get a bunch of these(although its the same error):
Selected items were updated with errors:
- Unable to update theme 'twentyseventeen_1.7_1_', details: PHP Warning: chmod(): Operation not permitted in /var/www/vhosts/santiapps.com/httpdocs/wordpress_2/wp-admin/includes/class-wp-filesystem-direct.php on line 168
Warning: chmod(): Operation not permitted in /var/www/vhosts/santiapps.com/httpdocs/wordpress_2/wp-admin/includes/class-wp-filesystem-direct.php on line 168
PHP Warning: chmod(): Operation not permitted in /var/www/vhosts/santiapps.com/httpdocs/wordpress_2/wp-admin/includes/class-wp-filesystem-direct.php on line 168
Warning: chmod(): Operation not permitted in /var/www/vhosts/santiapps.com/httpdocs/wordpress_2/wp-admin/includes/class-wp-filesystem-direct.php on line 168...
and near the end it reads:
Warning: The update cannot be installed because we will be unable to copy some files. This is usually due to inconsistent file permissions. "front-page.php, rtl.css, 404.php...
Then in the end it doesnt update of course. A suggestion by the Wordpress Toolkit on plesk is:
Im using filezilla and changing the permissions to those files but I get "operation not permitted".
[SOLVED] (at least for me)
Me too on Cloudways and Digital Ocean.
Just restart the server and error is gone.

Application failed to start on shiny web server after a few days [duplicate]

This question already has an answer here:
Error: Discard position id too big
(1 answer)
Closed 4 years ago.
I have a running shiny app on a web server that worked fine until I would say last week. Now, on occasion (I guess every two days) the app stops working with the "Application failed to start" message. When I restart the shiny server, as I did just now, everything runs fine again.
https://butterlab.imb-mainz.de/flydev/
The funny thing is, I have other apps on this server as well, and they are not affected and run fine in parallel, even if this app failed.
I can not find any error message in the log files. And I am wondering: how I could debug this, since the app is now running fine?
Looking forward to any advice.
EDIT:
I checked the shiny-server.log file after the error occurred and I found the following message:
[2018-06-14 14:29:20.080] [WARN] shiny-server - RobustSockJS collision: MqU4rgur76RPgjJIPr
[2018-06-15 01:28:18.398] [WARN] shiny-server - Error handling message: Error: Discard position id too big
[2018-06-15 02:00:10.358] [INFO] shiny-server - Error getting worker: Error: The application took too long to respond.
[2018-06-15 02:00:10.364] [INFO] shiny-server - Error getting worker: Error: The application took too long to respond.
The last message gets repeated whenever someone accesses the server.
So in the end, it seems this page solved my problem Error: Discard position id too big
I set app_init_timeout and app_idle_timeout both to 1800and since then I have no further problems.
Also the comment with the restart.txt file might be interesting. I thought about testing with a shell script if the page is still working, otherwise touching the txt.
http://docs.rstudio.com/shiny-server/#restarting-an-application
But as I said, in the end it works by adjusting the app_init_timeout and app_idle_timeout.

Error:symfony 3 Uncaught Twig_Error_Loader: [duplicate]

This question already has an answer here:
Symfony2: ResourceNotFoundException when using extends in a twig template
(1 answer)
Closed 4 years ago.
i downloaded a Symfony project from my friends run both
Composer update and php bin/console doctrine:schema:update --force
commands without errors
but when i open the project on my browser i get this error:
Fatal error: Uncaught Symfony\Component\Routing\Exception\ResourceNotFoundException in /Applications/MAMP/htdocs/Animaux/Animaux/var/cache/prod/appProdProjectContainerUrlMatcher.php:407 Stack trace: #0 /Applications/MAMP/htdocs/Animaux/Animaux/vendor/symfony/symfony/src/Symfony/Component/Routing/Matcher/UrlMatcher.php(90): appProdProjectContainerUrlMatcher->match('/app_dev.app/') #1 /Applications/MAMP/htdocs/Animaux/Animaux/vendor/symfony/symfony/src/Symfony/Component/Routing/Router.php(262): Symfony\Component\Routing\Matcher\UrlMatcher->matchRequest(Object(Symfony\Component\HttpFoundation\Request)) #2 /Applications/MAMP/htdocs/Animaux/Animaux/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/EventListener/RouterListener.php(104): Symfony\Component\Routing\Router->matchRequest(Object(Symfony\Component\HttpFoundation\Request)) #3 [internal function]: Symfony\Component\HttpKernel\EventListener\RouterListener->onKernelRequest(Object(Symfony\Component\HttpKernel\Event\GetResponseEvent), 'kernel.request', Object(Symfony\ in /Applications/MAMP/htdocs/Animaux/Animaux/vendor/twig/twig/lib/Twig/Loader/Filesystem.php on line 101
help me please
Composer update - It is a bad idea. For normal development or migrate to production, you need to use the same version of dependencies, with the project must be provided composer.lock file (versions of dependencies), and you need to use composer install instead of Composer update.
...Animaux/var/cache/prod/app... it meant you didn't clear the cache, for development use https://your_host.com/app_dev.php for production - clear the cache php bin/console cache:clear -e prod
Check for PHP version, it must be the same of development.

Resources