Magento 2 product import won't import imagesMagento 2.0.5 Product Image Import error 'timeout or permissions'Magento 2 product images not showing, 2 different directoriesMagento2 - Import Product with Images Using Absolute PathHow to upload Multiple Images Of same product using CSV FIle in magento 2.0?Trying to upload images via CSV and getting an errorMagento 2 import products with imagesMagento 2.2 import product images from csv giving errorMagento 2 Import Product IssueMagento 2.1.17 product imported but product images not showMagento2 - Failed to import products

What instances can be solved today by modern solvers (pure LP)?

Question about targeting a Hexproof creature

What can a novel do that film and TV cannot?

When is one 'Ready' to make Original Contributions to Mathematics?

Why do Martians have to wear space helmets?

Park the computer

Can you take the Dodge action while prone?

Is it bad to suddenly introduce another element to your fantasy world a good ways into the story?

Did Stalin kill all Soviet officers involved in the Winter War?

Advice for making/keeping shredded chicken moist?

Why do most airliners have underwing engines, while business jets have rear-mounted engines?

How did Captain Marvel do this without dying?

How do I check that users don't write down their passwords?

How to supply water to a coastal desert town with no rain and no freshwater aquifers?

n-level Ouroboros Quine

What's the difference between 反面 and 一方?

What is the fundamental difference between catching whales and hunting other animals?

What is the shape of the upper boundary of water hitting a screen?

LTSpice: how to setup sinusoidal or exponential voltage source?

How did Einstein know the speed of light was constant?

Do intermediate subdomains need to exist?

Why weren't Gemini capsules given names?

Boss furious on bad appraisal

What is the highest level of accuracy in motion control a Victorian society could achieve?



Magento 2 product import won't import images


Magento 2.0.5 Product Image Import error 'timeout or permissions'Magento 2 product images not showing, 2 different directoriesMagento2 - Import Product with Images Using Absolute PathHow to upload Multiple Images Of same product using CSV FIle in magento 2.0?Trying to upload images via CSV and getting an errorMagento 2 import products with imagesMagento 2.2 import product images from csv giving errorMagento 2 Import Product IssueMagento 2.1.17 product imported but product images not showMagento2 - Failed to import products






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








8















I am importing products using the built in CSV import (System - import - products)



All my data is imported fine, but I get an error
"Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in rows: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10"



in my css I have written the base_image path as
http://mywebsite.ca/pub/media/import/img/hose/jpg/Ach7938.jpg



as a test I removed my folder structure, edited the csv and tried this and got same problem, same error
http://mywebsite.ca/pub/media/import/Ach7938.jpg



I tried writing file path as so
/pub/media/import/img/hose/jpg/Ach7938.jpg
but it won't let me past the "check data" validator.



I confirmed the permissions on the folders and files is 775



I am using php 5.6, I tried 7 but it broke the whole site in many different ways, so that isn't an option



As a side note, if I run this 20 times in a row, the entire site hangs and import won't work again until I do a full system restore (whats up with that?)



Can I put the images on a different server and link to them that way?










share|improve this question






























    8















    I am importing products using the built in CSV import (System - import - products)



    All my data is imported fine, but I get an error
    "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in rows: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10"



    in my css I have written the base_image path as
    http://mywebsite.ca/pub/media/import/img/hose/jpg/Ach7938.jpg



    as a test I removed my folder structure, edited the csv and tried this and got same problem, same error
    http://mywebsite.ca/pub/media/import/Ach7938.jpg



    I tried writing file path as so
    /pub/media/import/img/hose/jpg/Ach7938.jpg
    but it won't let me past the "check data" validator.



    I confirmed the permissions on the folders and files is 775



    I am using php 5.6, I tried 7 but it broke the whole site in many different ways, so that isn't an option



    As a side note, if I run this 20 times in a row, the entire site hangs and import won't work again until I do a full system restore (whats up with that?)



    Can I put the images on a different server and link to them that way?










    share|improve this question


























      8












      8








      8


      2






      I am importing products using the built in CSV import (System - import - products)



      All my data is imported fine, but I get an error
      "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in rows: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10"



      in my css I have written the base_image path as
      http://mywebsite.ca/pub/media/import/img/hose/jpg/Ach7938.jpg



      as a test I removed my folder structure, edited the csv and tried this and got same problem, same error
      http://mywebsite.ca/pub/media/import/Ach7938.jpg



      I tried writing file path as so
      /pub/media/import/img/hose/jpg/Ach7938.jpg
      but it won't let me past the "check data" validator.



      I confirmed the permissions on the folders and files is 775



      I am using php 5.6, I tried 7 but it broke the whole site in many different ways, so that isn't an option



      As a side note, if I run this 20 times in a row, the entire site hangs and import won't work again until I do a full system restore (whats up with that?)



      Can I put the images on a different server and link to them that way?










      share|improve this question
















      I am importing products using the built in CSV import (System - import - products)



      All my data is imported fine, but I get an error
      "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in rows: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10"



      in my css I have written the base_image path as
      http://mywebsite.ca/pub/media/import/img/hose/jpg/Ach7938.jpg



      as a test I removed my folder structure, edited the csv and tried this and got same problem, same error
      http://mywebsite.ca/pub/media/import/Ach7938.jpg



      I tried writing file path as so
      /pub/media/import/img/hose/jpg/Ach7938.jpg
      but it won't let me past the "check data" validator.



      I confirmed the permissions on the folders and files is 775



      I am using php 5.6, I tried 7 but it broke the whole site in many different ways, so that isn't an option



      As a side note, if I run this 20 times in a row, the entire site hangs and import won't work again until I do a full system restore (whats up with that?)



      Can I put the images on a different server and link to them that way?







      magento2 import






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Sep 9 '16 at 7:25









      Mukesh

      9451 gold badge15 silver badges45 bronze badges




      9451 gold badge15 silver badges45 bronze badges










      asked Apr 1 '16 at 17:15









      Justin BlayneyJustin Blayney

      1002 gold badges2 silver badges9 bronze badges




      1002 gold badges2 silver badges9 bronze badges




















          8 Answers
          8






          active

          oldest

          votes


















          6














          the image path should be something like this in the csv: Ach7938.jpg



          M1 would then search for the image file in media/import so I think it would be pub/media/import in M2



          You could create a product with an Image and then export the data to get a clue how the value in the csv has to be






          share|improve this answer






























            5














            I got the error mentioned as "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions" when I used following format of csv file to import image in Magento 2.0.0 version(Windows 10).



            The format of csv which I used was as following >>



            sku,base_image,errors
            WT09-XS-Purple,/pub/media/import/wt09-white_back-test.jpg


            and under the File to import section's sub section Images File Directory I used the path as /pub/media/import



            I had the image to be imported at pub/media/import location



            The problem solved when I used following csv format :



            "sku","base_image"
            "WT09-XS-Purple","wt09-white_back-test.jpg"


            and Images File Directory value as pub/media/import
            enter image description here



            Issue on Github : https://github.com/magento/magento2/issues/2666






            share|improve this answer






























              5














              Not sure if this has anything to do with your issue as this is an internal import but:



              In M2 I have images stored in pub/media/import but would get the same error




              1. Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in row(s): 1, 2



              I removed the path name from my CSV file and just have the image path as image.jpg with no slashes and it works great now.






              share|improve this answer

























              • I think this is specific to your case. Your images are directory in the directory not in a sub directory.

                – Stevie G
                Feb 28 '17 at 14:26


















              2














              i am now working on Magento 2.2.6 / 7

              and i faced the same error because directory path mechanism of different operating systems.



              lets assume if images are in pub/media/import folder than we should mention the path like that :
              1. in Windows (mostly for localhost/development purpose)- /pub/media/import
              2. in Ubuntu (mostly for production server)- pub/media/import



              here the one extra slash is causing the problem.






              share|improve this answer






























                1














                If you imported with external image url you can see my hotfix.



                I found the problem come from the duplicate path for image after download from external url image.



                I also created a pull request for it.






                share|improve this answer

























                • That worked for me. Could not import images from external urls anymore in 2.2.7.

                  – Johnny Longneck
                  Mar 19 at 18:55


















                0














                Image path can be or cannot be without / that isn't problem. I've imported with both and it worked. In my case issue was the images given in path wasn't available in folder. I tried it with importing available and not-available image and was getting error in case when that image wasn't available.
                Path can be any one ,it isn't must to use pub/media/import only.






                share|improve this answer






























                  0














                  For the import images issue i have fixed the issue from Uploader.php file. change below file path code and success working import images.




                  File path:
                  magento/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php




                  Find the below line from line number 201:



                  $filePath = $this->_directory->getRelativePath($filePath . $fileName);




                  Replace with:



                  $filePath = strpos($filePath, $fileName) !== false ?
                  $filePath:$this->_directory->getRelativePath($filePath . $fileName);




                  For More information Refer github link:



                  https://github.com/magento/magento2/pull/20761/commits/8612789375b0c173f0ba852c587882af6ff8bc7f






                  share|improve this answer






























                    0














                    Just fixed the same issue by setting the owner of the images in pub/media/import to the web user.



                    In var/log/exception.log I found the following



                    [2019-06-05 21:02:06] main.CRITICAL: File 'pub/media/import/xxxx.jpg' was not found or has read restriction. "exception":"[object] (Magento\Framework\Exception\LocalizedException(code: 0): File 'pub/media/import/xxxx.jpg' was not found or has read restriction. at /opt/bitnami/apps/magento/htdocs/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php:209)" []


                    Under a Bitnami install the files were uploaded via FTP as the user 'bitnami' but in this install the webuser is 'daemon'



                    I ran the following to fix all ownerships on a Bitnami install and now it imports the images. Dont run this if your web user is not daemon.



                    sudo chown -R daemon:daemon /opt/bitnami/apps/magento/htdocs && sudo find . -type d -exec chmod 770 ; && sudo find . -type f -exec chmod 660 ; && sudo chmod u+x bin/magento-cli``


                    Although this solution is for a BItnami install it might help find your issue.






                    share|improve this answer








                    New contributor



                    DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                    Check out our Code of Conduct.





















                      Your Answer








                      StackExchange.ready(function()
                      var channelOptions =
                      tags: "".split(" "),
                      id: "479"
                      ;
                      initTagRenderer("".split(" "), "".split(" "), channelOptions);

                      StackExchange.using("externalEditor", function()
                      // Have to fire editor after snippets, if snippets enabled
                      if (StackExchange.settings.snippets.snippetsEnabled)
                      StackExchange.using("snippets", function()
                      createEditor();
                      );

                      else
                      createEditor();

                      );

                      function createEditor()
                      StackExchange.prepareEditor(
                      heartbeatType: 'answer',
                      autoActivateHeartbeat: false,
                      convertImagesToLinks: false,
                      noModals: true,
                      showLowRepImageUploadWarning: true,
                      reputationToPostImages: null,
                      bindNavPrevention: true,
                      postfix: "",
                      imageUploader:
                      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
                      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
                      allowUrls: true
                      ,
                      onDemand: true,
                      discardSelector: ".discard-answer"
                      ,immediatelyShowMarkdownHelp:true
                      );



                      );













                      draft saved

                      draft discarded


















                      StackExchange.ready(
                      function ()
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f109066%2fmagento-2-product-import-wont-import-images%23new-answer', 'question_page');

                      );

                      Post as a guest















                      Required, but never shown

























                      8 Answers
                      8






                      active

                      oldest

                      votes








                      8 Answers
                      8






                      active

                      oldest

                      votes









                      active

                      oldest

                      votes






                      active

                      oldest

                      votes









                      6














                      the image path should be something like this in the csv: Ach7938.jpg



                      M1 would then search for the image file in media/import so I think it would be pub/media/import in M2



                      You could create a product with an Image and then export the data to get a clue how the value in the csv has to be






                      share|improve this answer



























                        6














                        the image path should be something like this in the csv: Ach7938.jpg



                        M1 would then search for the image file in media/import so I think it would be pub/media/import in M2



                        You could create a product with an Image and then export the data to get a clue how the value in the csv has to be






                        share|improve this answer

























                          6












                          6








                          6







                          the image path should be something like this in the csv: Ach7938.jpg



                          M1 would then search for the image file in media/import so I think it would be pub/media/import in M2



                          You could create a product with an Image and then export the data to get a clue how the value in the csv has to be






                          share|improve this answer













                          the image path should be something like this in the csv: Ach7938.jpg



                          M1 would then search for the image file in media/import so I think it would be pub/media/import in M2



                          You could create a product with an Image and then export the data to get a clue how the value in the csv has to be







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Apr 1 '16 at 19:22









                          David VerholenDavid Verholen

                          5,5461 gold badge12 silver badges31 bronze badges




                          5,5461 gold badge12 silver badges31 bronze badges























                              5














                              I got the error mentioned as "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions" when I used following format of csv file to import image in Magento 2.0.0 version(Windows 10).



                              The format of csv which I used was as following >>



                              sku,base_image,errors
                              WT09-XS-Purple,/pub/media/import/wt09-white_back-test.jpg


                              and under the File to import section's sub section Images File Directory I used the path as /pub/media/import



                              I had the image to be imported at pub/media/import location



                              The problem solved when I used following csv format :



                              "sku","base_image"
                              "WT09-XS-Purple","wt09-white_back-test.jpg"


                              and Images File Directory value as pub/media/import
                              enter image description here



                              Issue on Github : https://github.com/magento/magento2/issues/2666






                              share|improve this answer



























                                5














                                I got the error mentioned as "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions" when I used following format of csv file to import image in Magento 2.0.0 version(Windows 10).



                                The format of csv which I used was as following >>



                                sku,base_image,errors
                                WT09-XS-Purple,/pub/media/import/wt09-white_back-test.jpg


                                and under the File to import section's sub section Images File Directory I used the path as /pub/media/import



                                I had the image to be imported at pub/media/import location



                                The problem solved when I used following csv format :



                                "sku","base_image"
                                "WT09-XS-Purple","wt09-white_back-test.jpg"


                                and Images File Directory value as pub/media/import
                                enter image description here



                                Issue on Github : https://github.com/magento/magento2/issues/2666






                                share|improve this answer

























                                  5












                                  5








                                  5







                                  I got the error mentioned as "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions" when I used following format of csv file to import image in Magento 2.0.0 version(Windows 10).



                                  The format of csv which I used was as following >>



                                  sku,base_image,errors
                                  WT09-XS-Purple,/pub/media/import/wt09-white_back-test.jpg


                                  and under the File to import section's sub section Images File Directory I used the path as /pub/media/import



                                  I had the image to be imported at pub/media/import location



                                  The problem solved when I used following csv format :



                                  "sku","base_image"
                                  "WT09-XS-Purple","wt09-white_back-test.jpg"


                                  and Images File Directory value as pub/media/import
                                  enter image description here



                                  Issue on Github : https://github.com/magento/magento2/issues/2666






                                  share|improve this answer













                                  I got the error mentioned as "Imported resource (image) could not be downloaded from external resource due to timeout or access permissions" when I used following format of csv file to import image in Magento 2.0.0 version(Windows 10).



                                  The format of csv which I used was as following >>



                                  sku,base_image,errors
                                  WT09-XS-Purple,/pub/media/import/wt09-white_back-test.jpg


                                  and under the File to import section's sub section Images File Directory I used the path as /pub/media/import



                                  I had the image to be imported at pub/media/import location



                                  The problem solved when I used following csv format :



                                  "sku","base_image"
                                  "WT09-XS-Purple","wt09-white_back-test.jpg"


                                  and Images File Directory value as pub/media/import
                                  enter image description here



                                  Issue on Github : https://github.com/magento/magento2/issues/2666







                                  share|improve this answer












                                  share|improve this answer



                                  share|improve this answer










                                  answered Sep 9 '16 at 7:21









                                  MukeshMukesh

                                  9451 gold badge15 silver badges45 bronze badges




                                  9451 gold badge15 silver badges45 bronze badges





















                                      5














                                      Not sure if this has anything to do with your issue as this is an internal import but:



                                      In M2 I have images stored in pub/media/import but would get the same error




                                      1. Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in row(s): 1, 2



                                      I removed the path name from my CSV file and just have the image path as image.jpg with no slashes and it works great now.






                                      share|improve this answer

























                                      • I think this is specific to your case. Your images are directory in the directory not in a sub directory.

                                        – Stevie G
                                        Feb 28 '17 at 14:26















                                      5














                                      Not sure if this has anything to do with your issue as this is an internal import but:



                                      In M2 I have images stored in pub/media/import but would get the same error




                                      1. Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in row(s): 1, 2



                                      I removed the path name from my CSV file and just have the image path as image.jpg with no slashes and it works great now.






                                      share|improve this answer

























                                      • I think this is specific to your case. Your images are directory in the directory not in a sub directory.

                                        – Stevie G
                                        Feb 28 '17 at 14:26













                                      5












                                      5








                                      5







                                      Not sure if this has anything to do with your issue as this is an internal import but:



                                      In M2 I have images stored in pub/media/import but would get the same error




                                      1. Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in row(s): 1, 2



                                      I removed the path name from my CSV file and just have the image path as image.jpg with no slashes and it works great now.






                                      share|improve this answer















                                      Not sure if this has anything to do with your issue as this is an internal import but:



                                      In M2 I have images stored in pub/media/import but would get the same error




                                      1. Imported resource (image) could not be downloaded from external resource due to timeout or access permissions in row(s): 1, 2



                                      I removed the path name from my CSV file and just have the image path as image.jpg with no slashes and it works great now.







                                      share|improve this answer














                                      share|improve this answer



                                      share|improve this answer








                                      edited Jan 16 '17 at 16:29









                                      Devtype

                                      2,2751 gold badge13 silver badges33 bronze badges




                                      2,2751 gold badge13 silver badges33 bronze badges










                                      answered Aug 24 '16 at 17:10









                                      babywitbabywit

                                      4047 silver badges17 bronze badges




                                      4047 silver badges17 bronze badges












                                      • I think this is specific to your case. Your images are directory in the directory not in a sub directory.

                                        – Stevie G
                                        Feb 28 '17 at 14:26

















                                      • I think this is specific to your case. Your images are directory in the directory not in a sub directory.

                                        – Stevie G
                                        Feb 28 '17 at 14:26
















                                      I think this is specific to your case. Your images are directory in the directory not in a sub directory.

                                      – Stevie G
                                      Feb 28 '17 at 14:26





                                      I think this is specific to your case. Your images are directory in the directory not in a sub directory.

                                      – Stevie G
                                      Feb 28 '17 at 14:26











                                      2














                                      i am now working on Magento 2.2.6 / 7

                                      and i faced the same error because directory path mechanism of different operating systems.



                                      lets assume if images are in pub/media/import folder than we should mention the path like that :
                                      1. in Windows (mostly for localhost/development purpose)- /pub/media/import
                                      2. in Ubuntu (mostly for production server)- pub/media/import



                                      here the one extra slash is causing the problem.






                                      share|improve this answer



























                                        2














                                        i am now working on Magento 2.2.6 / 7

                                        and i faced the same error because directory path mechanism of different operating systems.



                                        lets assume if images are in pub/media/import folder than we should mention the path like that :
                                        1. in Windows (mostly for localhost/development purpose)- /pub/media/import
                                        2. in Ubuntu (mostly for production server)- pub/media/import



                                        here the one extra slash is causing the problem.






                                        share|improve this answer

























                                          2












                                          2








                                          2







                                          i am now working on Magento 2.2.6 / 7

                                          and i faced the same error because directory path mechanism of different operating systems.



                                          lets assume if images are in pub/media/import folder than we should mention the path like that :
                                          1. in Windows (mostly for localhost/development purpose)- /pub/media/import
                                          2. in Ubuntu (mostly for production server)- pub/media/import



                                          here the one extra slash is causing the problem.






                                          share|improve this answer













                                          i am now working on Magento 2.2.6 / 7

                                          and i faced the same error because directory path mechanism of different operating systems.



                                          lets assume if images are in pub/media/import folder than we should mention the path like that :
                                          1. in Windows (mostly for localhost/development purpose)- /pub/media/import
                                          2. in Ubuntu (mostly for production server)- pub/media/import



                                          here the one extra slash is causing the problem.







                                          share|improve this answer












                                          share|improve this answer



                                          share|improve this answer










                                          answered Mar 12 at 14:00









                                          spider01spider01

                                          1687 bronze badges




                                          1687 bronze badges





















                                              1














                                              If you imported with external image url you can see my hotfix.



                                              I found the problem come from the duplicate path for image after download from external url image.



                                              I also created a pull request for it.






                                              share|improve this answer

























                                              • That worked for me. Could not import images from external urls anymore in 2.2.7.

                                                – Johnny Longneck
                                                Mar 19 at 18:55















                                              1














                                              If you imported with external image url you can see my hotfix.



                                              I found the problem come from the duplicate path for image after download from external url image.



                                              I also created a pull request for it.






                                              share|improve this answer

























                                              • That worked for me. Could not import images from external urls anymore in 2.2.7.

                                                – Johnny Longneck
                                                Mar 19 at 18:55













                                              1












                                              1








                                              1







                                              If you imported with external image url you can see my hotfix.



                                              I found the problem come from the duplicate path for image after download from external url image.



                                              I also created a pull request for it.






                                              share|improve this answer















                                              If you imported with external image url you can see my hotfix.



                                              I found the problem come from the duplicate path for image after download from external url image.



                                              I also created a pull request for it.







                                              share|improve this answer














                                              share|improve this answer



                                              share|improve this answer








                                              edited Feb 15 at 2:41

























                                              answered Feb 15 at 2:35









                                              JokerbaseJokerbase

                                              112 bronze badges




                                              112 bronze badges












                                              • That worked for me. Could not import images from external urls anymore in 2.2.7.

                                                – Johnny Longneck
                                                Mar 19 at 18:55

















                                              • That worked for me. Could not import images from external urls anymore in 2.2.7.

                                                – Johnny Longneck
                                                Mar 19 at 18:55
















                                              That worked for me. Could not import images from external urls anymore in 2.2.7.

                                              – Johnny Longneck
                                              Mar 19 at 18:55





                                              That worked for me. Could not import images from external urls anymore in 2.2.7.

                                              – Johnny Longneck
                                              Mar 19 at 18:55











                                              0














                                              Image path can be or cannot be without / that isn't problem. I've imported with both and it worked. In my case issue was the images given in path wasn't available in folder. I tried it with importing available and not-available image and was getting error in case when that image wasn't available.
                                              Path can be any one ,it isn't must to use pub/media/import only.






                                              share|improve this answer



























                                                0














                                                Image path can be or cannot be without / that isn't problem. I've imported with both and it worked. In my case issue was the images given in path wasn't available in folder. I tried it with importing available and not-available image and was getting error in case when that image wasn't available.
                                                Path can be any one ,it isn't must to use pub/media/import only.






                                                share|improve this answer

























                                                  0












                                                  0








                                                  0







                                                  Image path can be or cannot be without / that isn't problem. I've imported with both and it worked. In my case issue was the images given in path wasn't available in folder. I tried it with importing available and not-available image and was getting error in case when that image wasn't available.
                                                  Path can be any one ,it isn't must to use pub/media/import only.






                                                  share|improve this answer













                                                  Image path can be or cannot be without / that isn't problem. I've imported with both and it worked. In my case issue was the images given in path wasn't available in folder. I tried it with importing available and not-available image and was getting error in case when that image wasn't available.
                                                  Path can be any one ,it isn't must to use pub/media/import only.







                                                  share|improve this answer












                                                  share|improve this answer



                                                  share|improve this answer










                                                  answered Jul 5 '18 at 7:31









                                                  Shahzaib Hayat KhanShahzaib Hayat Khan

                                                  2991 silver badge6 bronze badges




                                                  2991 silver badge6 bronze badges





















                                                      0














                                                      For the import images issue i have fixed the issue from Uploader.php file. change below file path code and success working import images.




                                                      File path:
                                                      magento/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php




                                                      Find the below line from line number 201:



                                                      $filePath = $this->_directory->getRelativePath($filePath . $fileName);




                                                      Replace with:



                                                      $filePath = strpos($filePath, $fileName) !== false ?
                                                      $filePath:$this->_directory->getRelativePath($filePath . $fileName);




                                                      For More information Refer github link:



                                                      https://github.com/magento/magento2/pull/20761/commits/8612789375b0c173f0ba852c587882af6ff8bc7f






                                                      share|improve this answer



























                                                        0














                                                        For the import images issue i have fixed the issue from Uploader.php file. change below file path code and success working import images.




                                                        File path:
                                                        magento/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php




                                                        Find the below line from line number 201:



                                                        $filePath = $this->_directory->getRelativePath($filePath . $fileName);




                                                        Replace with:



                                                        $filePath = strpos($filePath, $fileName) !== false ?
                                                        $filePath:$this->_directory->getRelativePath($filePath . $fileName);




                                                        For More information Refer github link:



                                                        https://github.com/magento/magento2/pull/20761/commits/8612789375b0c173f0ba852c587882af6ff8bc7f






                                                        share|improve this answer

























                                                          0












                                                          0








                                                          0







                                                          For the import images issue i have fixed the issue from Uploader.php file. change below file path code and success working import images.




                                                          File path:
                                                          magento/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php




                                                          Find the below line from line number 201:



                                                          $filePath = $this->_directory->getRelativePath($filePath . $fileName);




                                                          Replace with:



                                                          $filePath = strpos($filePath, $fileName) !== false ?
                                                          $filePath:$this->_directory->getRelativePath($filePath . $fileName);




                                                          For More information Refer github link:



                                                          https://github.com/magento/magento2/pull/20761/commits/8612789375b0c173f0ba852c587882af6ff8bc7f






                                                          share|improve this answer













                                                          For the import images issue i have fixed the issue from Uploader.php file. change below file path code and success working import images.




                                                          File path:
                                                          magento/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php




                                                          Find the below line from line number 201:



                                                          $filePath = $this->_directory->getRelativePath($filePath . $fileName);




                                                          Replace with:



                                                          $filePath = strpos($filePath, $fileName) !== false ?
                                                          $filePath:$this->_directory->getRelativePath($filePath . $fileName);




                                                          For More information Refer github link:



                                                          https://github.com/magento/magento2/pull/20761/commits/8612789375b0c173f0ba852c587882af6ff8bc7f







                                                          share|improve this answer












                                                          share|improve this answer



                                                          share|improve this answer










                                                          answered Jun 26 at 13:47









                                                          Kirti NariyaKirti Nariya

                                                          1,6195 silver badges19 bronze badges




                                                          1,6195 silver badges19 bronze badges





















                                                              0














                                                              Just fixed the same issue by setting the owner of the images in pub/media/import to the web user.



                                                              In var/log/exception.log I found the following



                                                              [2019-06-05 21:02:06] main.CRITICAL: File 'pub/media/import/xxxx.jpg' was not found or has read restriction. "exception":"[object] (Magento\Framework\Exception\LocalizedException(code: 0): File 'pub/media/import/xxxx.jpg' was not found or has read restriction. at /opt/bitnami/apps/magento/htdocs/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php:209)" []


                                                              Under a Bitnami install the files were uploaded via FTP as the user 'bitnami' but in this install the webuser is 'daemon'



                                                              I ran the following to fix all ownerships on a Bitnami install and now it imports the images. Dont run this if your web user is not daemon.



                                                              sudo chown -R daemon:daemon /opt/bitnami/apps/magento/htdocs && sudo find . -type d -exec chmod 770 ; && sudo find . -type f -exec chmod 660 ; && sudo chmod u+x bin/magento-cli``


                                                              Although this solution is for a BItnami install it might help find your issue.






                                                              share|improve this answer








                                                              New contributor



                                                              DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                                              Check out our Code of Conduct.























                                                                0














                                                                Just fixed the same issue by setting the owner of the images in pub/media/import to the web user.



                                                                In var/log/exception.log I found the following



                                                                [2019-06-05 21:02:06] main.CRITICAL: File 'pub/media/import/xxxx.jpg' was not found or has read restriction. "exception":"[object] (Magento\Framework\Exception\LocalizedException(code: 0): File 'pub/media/import/xxxx.jpg' was not found or has read restriction. at /opt/bitnami/apps/magento/htdocs/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php:209)" []


                                                                Under a Bitnami install the files were uploaded via FTP as the user 'bitnami' but in this install the webuser is 'daemon'



                                                                I ran the following to fix all ownerships on a Bitnami install and now it imports the images. Dont run this if your web user is not daemon.



                                                                sudo chown -R daemon:daemon /opt/bitnami/apps/magento/htdocs && sudo find . -type d -exec chmod 770 ; && sudo find . -type f -exec chmod 660 ; && sudo chmod u+x bin/magento-cli``


                                                                Although this solution is for a BItnami install it might help find your issue.






                                                                share|improve this answer








                                                                New contributor



                                                                DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                                                Check out our Code of Conduct.





















                                                                  0












                                                                  0








                                                                  0







                                                                  Just fixed the same issue by setting the owner of the images in pub/media/import to the web user.



                                                                  In var/log/exception.log I found the following



                                                                  [2019-06-05 21:02:06] main.CRITICAL: File 'pub/media/import/xxxx.jpg' was not found or has read restriction. "exception":"[object] (Magento\Framework\Exception\LocalizedException(code: 0): File 'pub/media/import/xxxx.jpg' was not found or has read restriction. at /opt/bitnami/apps/magento/htdocs/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php:209)" []


                                                                  Under a Bitnami install the files were uploaded via FTP as the user 'bitnami' but in this install the webuser is 'daemon'



                                                                  I ran the following to fix all ownerships on a Bitnami install and now it imports the images. Dont run this if your web user is not daemon.



                                                                  sudo chown -R daemon:daemon /opt/bitnami/apps/magento/htdocs && sudo find . -type d -exec chmod 770 ; && sudo find . -type f -exec chmod 660 ; && sudo chmod u+x bin/magento-cli``


                                                                  Although this solution is for a BItnami install it might help find your issue.






                                                                  share|improve this answer








                                                                  New contributor



                                                                  DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                                                  Check out our Code of Conduct.









                                                                  Just fixed the same issue by setting the owner of the images in pub/media/import to the web user.



                                                                  In var/log/exception.log I found the following



                                                                  [2019-06-05 21:02:06] main.CRITICAL: File 'pub/media/import/xxxx.jpg' was not found or has read restriction. "exception":"[object] (Magento\Framework\Exception\LocalizedException(code: 0): File 'pub/media/import/xxxx.jpg' was not found or has read restriction. at /opt/bitnami/apps/magento/htdocs/vendor/magento/module-catalog-import-export/Model/Import/Uploader.php:209)" []


                                                                  Under a Bitnami install the files were uploaded via FTP as the user 'bitnami' but in this install the webuser is 'daemon'



                                                                  I ran the following to fix all ownerships on a Bitnami install and now it imports the images. Dont run this if your web user is not daemon.



                                                                  sudo chown -R daemon:daemon /opt/bitnami/apps/magento/htdocs && sudo find . -type d -exec chmod 770 ; && sudo find . -type f -exec chmod 660 ; && sudo chmod u+x bin/magento-cli``


                                                                  Although this solution is for a BItnami install it might help find your issue.







                                                                  share|improve this answer








                                                                  New contributor



                                                                  DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                                                  Check out our Code of Conduct.








                                                                  share|improve this answer



                                                                  share|improve this answer






                                                                  New contributor



                                                                  DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                                                  Check out our Code of Conduct.








                                                                  answered 2 days ago









                                                                  DaveJDaveJ

                                                                  1




                                                                  1




                                                                  New contributor



                                                                  DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                                                  Check out our Code of Conduct.




                                                                  New contributor




                                                                  DaveJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
                                                                  Check out our Code of Conduct.





























                                                                      draft saved

                                                                      draft discarded
















































                                                                      Thanks for contributing an answer to Magento Stack Exchange!


                                                                      • Please be sure to answer the question. Provide details and share your research!

                                                                      But avoid


                                                                      • Asking for help, clarification, or responding to other answers.

                                                                      • Making statements based on opinion; back them up with references or personal experience.

                                                                      To learn more, see our tips on writing great answers.




                                                                      draft saved


                                                                      draft discarded














                                                                      StackExchange.ready(
                                                                      function ()
                                                                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f109066%2fmagento-2-product-import-wont-import-images%23new-answer', 'question_page');

                                                                      );

                                                                      Post as a guest















                                                                      Required, but never shown





















































                                                                      Required, but never shown














                                                                      Required, but never shown












                                                                      Required, but never shown







                                                                      Required, but never shown

































                                                                      Required, but never shown














                                                                      Required, but never shown












                                                                      Required, but never shown







                                                                      Required, but never shown







                                                                      Popular posts from this blog

                                                                      Category:9 (number) SubcategoriesMedia in category "9 (number)"Navigation menuUpload mediaGND ID: 4485639-8Library of Congress authority ID: sh85091979ReasonatorScholiaStatistics

                                                                      Circuit construction for execution of conditional statements using least significant bitHow are two different registers being used as “control”?How exactly is the stated composite state of the two registers being produced using the $R_zz$ controlled rotations?Efficiently performing controlled rotations in HHLWould this quantum algorithm implementation work?How to prepare a superposed states of odd integers from $1$ to $sqrtN$?Why is this implementation of the order finding algorithm not working?Circuit construction for Hamiltonian simulationHow can I invert the least significant bit of a certain term of a superposed state?Implementing an oracleImplementing a controlled sum operation

                                                                      Magento 2 “No Payment Methods” in Admin New OrderHow to integrate Paypal Express Checkout with the Magento APIMagento 1.5 - Sales > Order > edit order and shipping methods disappearAuto Invoice Check/Money Order Payment methodAdd more simple payment methods?Shipping methods not showingWhat should I do to change payment methods if changing the configuration has no effects?1.9 - No Payment Methods showing upMy Payment Methods not Showing for downloadable/virtual product when checkout?Magento2 API to access internal payment methodHow to call an existing payment methods in the registration form?