Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-28871

Can't upload large binary files using v2 admin UI

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: High High
    • Resolution: Fixed
    • Affects Version/s: 2.0.2
    • Fix Version/s: Customer request, 2.1.0-beta1
    • Component/s: Field types
    • Labels:
      None
    • Environment:

      PHP 7.1.11-0ubuntu0.17.10.1
      memory_limit=-1

      Description

      Steps to reproduce:

      1. Create new Media -> File
      2. Select large binary file (tested with ~200MB .txt file)
      3. Try to publish content

      You will get a 500 error (Status Code header contains 400) and exception:

      Argument 'localFile' is invalid: file does not exist or is unreadable: /var/www/v21/web
      

      For small files (tested with 1MB .pdf) everything works as expected.

      Additional information:
      It seems that the problem with large files starts here:
      https://github.com/ezsystems/ezplatform-admin-ui/blob/master/src/bundle/Controller/ContentEditController.php#L97
      so probably comes from Symfony itself.

      Please take a look at the screenshots from the debugger.
      For the small file, you can see correct inputUri value, file is in /tmp/ directory as it should, also, fileSize value is correct.
      For the large file, inputUri leads to application web directory, and fileSize is 0.

      1. large.png
        124 kB
      2. small.png
        125 kB

        Issue Links

          Activity

          Show
          Adam Wójs added a comment - Related PRs: https://github.com/ezsystems/repository-forms/pull/218 https://github.com/ezsystems/ezplatform-admin-ui/pull/368
          Show
          Adam Wójs added a comment - Merged: https://github.com/ezsystems/repository-forms/commit/d4091bf70e5e87be08e5826179d9c1bcc608a7cb https://github.com/ezsystems/ezplatform-admin-ui/commit/5f7470661325750ac08dd428e7c7eecf3400e7c7

            People

            • Assignee:
              Unassigned
              Reporter:
              Kamil Madejski
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: