Bug #57314
closedcli_dispatch.phpsh returns 1
Added by Jan Kiesewetter over 10 years ago. Updated over 9 years ago.
0%
Description
The cli_dispatch.phpsh from the stable 6.2.0 returns 1.
Updated by Alexander Opitz over 10 years ago
- Status changed from New to Under Review
Which PHP version?
How do you called the script?
Which parameters did you use?
Updated by Alexander Opitz over 10 years ago
- Status changed from Under Review to Needs Feedback
Updated by Jan Kiesewetter over 10 years ago
I have a shell script which worked proper with 6.1.7 on the same server and project
#!/bin/sh php /abspath/to/project/typo3/cli_dispatch.phpsh scheduler
PHP version is 5.3.10
Updated by Jan Kiesewetter over 10 years ago
I found out that the PHP CLI also has to use APC
So I added
apc.enable_cli=1
to my /etc/php/conf.d/apc.ini
Is this an expected behavior, as it seems to work without that setting in TYPO3 6.1?
Updated by Jan Kiesewetter over 10 years ago
The documentation of APC says:
apc.enable_cli integer
Mostly for testing and debugging. Setting this enables APC for the CLI version of PHP. Under normal circumstances, it is not ideal to create, populate and destroy the APC cache on every CLI request, but for various test scenarios it is useful to be able to enable APC for the CLI version of PHP easily.
http://php.net/manual/en/apc.configuration.php#ini.apc.enable-cli
That sounds like enable apc for cli is not for production environments...
Updated by Helmut Hummel over 10 years ago
Jan Kiesewetter wrote:
I found out that the PHP CLI also has to use APC
So I added
[...]
to my /etc/php/conf.d/apc.iniIs this an expected behavior, as it seems to work without that setting in TYPO3 6.1?
Do you have caches configured to use the ApcBackend?
Updated by Jan Kiesewetter over 10 years ago
I have enabled the APC cache backend with:
AdditionalConfiguration.php
$GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['cache_pages']['backend'] = 'TYPO3\\CMS\\Core\\Cache\\Backend\\ApcBackend'; $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['cache_pages']['options'] = array();
And the Extbase object cache APC cache backend via Install Tool -> Configuration Presets
Updated by Alexander Opitz over 10 years ago
If your System uses the APC cache backend, then you also need to enable APC in CLI else the cache backend couldn't be used.
Updated by Jan Kiesewetter over 10 years ago
If you enable apc for cli, you get problems with composer and have to work around them!
https://github.com/composer/composer/issues/264
http://robertlemke.com/en/blog/composer-and-apc.html
Updated by Alexander Opitz over 10 years ago
- Category set to Caching
- Status changed from Needs Feedback to New
So we need a way to disable ApcCache in CLI mode without having different configurations.
Updated by Job Rutgers over 10 years ago
I still get the "Could not set value" error.
I have the following APC options:
apc.enabled=1 apc.shm_segments=1 apc.shm_size=128M apc.stat=0 apc.canonicalize=1 apc.filters="-typo3temp/.*,-/usr/share/phpmyadmin/.*"
And I tried apc.enable_cli = 1 and = 0
Setting up those values in /etc/php5/conf.d20-apc.ini or in /etc/php5/fpm/php.ini make no sense.
I run Typo3 6.2.4 with nginx 1.2.1 and php5-fpm and APC 3.1.13
Updated by Helmut Hummel almost 10 years ago
- Status changed from New to Needs Feedback
There is nothing we can do here for the core, can we?
It is possible to have a different caching configuration for cli by adding different cache backends in an if construct like this in AdditionalConfiguration.php:
if (PHP_SAPI === 'cli') { // cache config for CLI here }
Updated by Alexander Opitz over 9 years ago
- Status changed from Needs Feedback to Closed
No feedback within the last 90 days => closing this issue.
If you think that this is the wrong decision or experience this issue again, then please write to the mailing list typo3.teams.bugs with issue number and an explanation or open a new ticket and add a relation to this ticket number.