Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

occ files_external:delete on external smb storage fails with php fatal error #19480

Closed
dirks opened this issue Feb 14, 2020 · 2 comments · Fixed by nextcloud/news#636
Closed
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug

Comments

@dirks
Copy link

dirks commented Feb 14, 2020

Steps to reproduce

  1. ensure you have a smb external storage configured (in this example it has the mount_id 4
  2. try to delete the external storage via occ files_external:
    sudo -u www-data php /var/www/nextcloud/occ files_external:delete -- 4

Expected behaviour

The specified external storage is deleted. Exit state of occ is 0.

Actual behaviour

The external storage remains and an error message is displayed:

PHP Fatal error:  Declaration of Symfony\Component\Console\Input\ArrayInput::hasParameterOption($values, bool $onlyParams = false) must be compatible with Symfony\Component\Console\Input\InputInterface::hasParameterOption($values, $onlyParams = false) in /var/www/nextcloud/apps/news/vendor/symfony/console/Input/ArrayInput.php on line 202

Note, removing the storage via the web interface works.

Server configuration

Ubuntu 18.04.4
Apache 2.4.29-1ubuntu4.11
postgresql 10+190ubuntu0.1
php 7.2.24 (using php-fpm)
nextcloud version: 17.0.3.1
Updated from an older Nextcloud/ownCloud (running since oc 5 IIRC)
Installed from https://download.nextcloud.com/server/releases/

No errors have been found.

List of activated apps:

App list
Enabled:
  - accessibility: 1.3.0
  - activity: 2.10.1
  - admin_audit: 1.7.0
  - announcementcenter: 3.6.1
  - bookmarks: 2.3.4
  - bruteforcesettings: 1.5.0
  - calendar: 2.0.1
  - circles: 0.17.10
  - cloud_federation_api: 1.0.0
  - comments: 1.7.0
  - contacts: 3.1.8
  - dav: 1.13.0
  - federatedfilesharing: 1.7.0
  - federation: 1.7.0
  - files: 1.12.0
  - files_accesscontrol: 1.7.0
  - files_external: 1.8.0
  - files_markdown: 2.2.0
  - files_pdfviewer: 1.6.0
  - files_rightclick: 0.15.1
  - files_sharing: 1.9.0
  - files_trashbin: 1.7.0
  - files_versions: 1.10.0
  - files_videoplayer: 1.6.0
  - firstrunwizard: 2.6.0
  - gallery: 18.4.0
  - groupfolders: 5.0.5
  - impersonate: 1.4.0
  - logreader: 2.2.0
  - lookup_server_connector: 1.5.0
  - news: 14.1.3
  - nextcloud_announcements: 1.6.0
  - notes: 3.1.5
  - notifications: 2.5.0
  - oauth2: 1.5.0
  - password_policy: 1.7.0
  - polls: 1.1.6
  - privacy: 1.1.0
  - provisioning_api: 1.7.0
  - recommendations: 0.5.0
  - serverinfo: 1.7.0
  - sharebymail: 1.7.0
  - spreed: 7.0.2
  - survey_client: 1.5.0
  - systemtags: 1.7.0
  - tasks: 0.11.3
  - text: 1.1.1
  - theming: 1.8.0
  - twofactor_backupcodes: 1.6.0
  - updatenotification: 1.7.0
  - user_ldap: 1.7.0
  - viewer: 1.2.0
  - workflowengine: 1.7.0
Disabled:
  - encryption
  - support

Nextcloud configuration:

Config report
{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "nextcloud01.idiv.de",
            "portal.idiv.de"
        ],
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "forwarded_for_headers": [
            "HTTP_X_FORWARDED_FOR"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "pgsql",
        "version": "17.0.3.1",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "ldapIgnoreNamingRules": false,
        "theme": "",
        "maintenance": false,
        "loglevel": 3,
        "secret": "***REMOVED SENSITIVE VALUE***",
        "singleuser": false,
        "memcache.local": "\\OC\\Memcache\\APCu",
        "filelocking.enabled": true,
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": "0",
            "dbindex": "0",
            "timeout": 0,
            "password": "***REMOVED SENSITIVE VALUE***"
        },
        "logfile": "\/var\/log\/nextcloud\/nextcloud.log",
        "log_rotate_size": "104857600",
        "mail_smtpmode": "sendmail",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "25",
        "trashbin_retention_obligation": "30, 180",
        "ldapProviderFactory": "\\OCA\\User_LDAP\\LDAPProviderFactory",
        "overwritehost": "portal.idiv.de",
        "overwrite.cli.url": "https:\/\/portal.idiv.de\/nextcloud",
        "overwriteprotocol": "https",
        "mail_smtpauthtype": "LOGIN",
        "mail_sendmailmode": "smtp",
        "updater.release.channel": "stable",
        "data-fingerprint": "4d55dc833a8f1e2170cfacbda1c5b752"
    }
}

Are you using external storage, if yes which one: smb

Are you using encryption: no

Are you using an external user-backend, if yes which one: ActiveDirectory

Nextcloud log (data/nextcloud.log)

Nextcloud log
{"reqId":"52D1mJ7K6yuhBlHrcurH","level":3,"time":"2020-02-14T12:12:06+00:00","remoteAddr":"","user":"--","app":"PHP","method":"","url":"--","message":"Declaration of Symfony\\Component\\Console\\Input\\ArrayInput::hasParameterOption($values, bool $onlyParams = false) must be compatible with Symfony\\Component\\Console\\Input\\InputInterface::hasParameterOption($values, $onlyParams = false) at \/var\/www\/nextcloud\/apps\/news\/vendor\/symfony\/console\/Input\/ArrayInput.php#202","userAgent":"--","version":"17.0.3.1"}
@dirks dirks added 0. Needs triage Pending check for reproducibility or if it fits our roadmap bug labels Feb 14, 2020
@kesselb
Copy link
Contributor

kesselb commented Feb 14, 2020

I never run into that issue but I know the problem. news app has feed-io (a library to parse rss feeds) as dependency and feed-io has symfony-console as dependency but symfony-console is also a nextcloud dependency. If the news app is installed two versions of symfony-console are installed and there are not compatible with each other.

@kesselb
Copy link
Contributor

kesselb commented Feb 14, 2020

cc @ChristophWurst could the news app use something like https://stackoverflow.com/questions/18882201/how-does-the-replace-property-work-with-composer to prevent composer from installing the symfony/console as dependency?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage Pending check for reproducibility or if it fits our roadmap bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants