I am using Migrate and Migrate D2D to migrate my D6 site to D7. I am using Migrate D2D UI to manually map all the fields and doing the migration process.

During migration, everything runs pretty smoothly except for File migrations. Out of 800 files, around 103 files failed to get copied over. Below is an excerpt of the migration error message for the file migration.

I am unsure why the files fail to copy. All the other files were copied smoothly from the same source directory into the same destination directory without issues. If other files were copied properly, I am sure this can't be related to permission issues... Attached is a screen shot of my file migration configuration in the GUI.

1356	Error	The specified file http://localhost/www/my_d6_site/sites/default/files/20160307_123817.jpg could not be copied to public://migrate//20160307_123817.jpg: "copy(http://localhost/www/my_d6_site/sites/default/files/20160307_123817.jpg): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found File C:\xampp\htdocs\www\my_d7_site\sites\all\modules\migrate\plugins\destinations\file.inc, line 393"
1357	Error	The specified file http://localhost/www/my_d6_site/sites/default/files/11825870_10155887956455274_2183794052626654269_n.jpg could not be copied to public://migrate//11825870_10155887956455274_2183794052626654269_n.jpg: "copy(http://localhost/www/my_d6_site/sites/default/files/11825870_10155887956455274_2183794052626654269_n.jpg): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found File C:\xampp\htdocs\www\my_d7_site\sites\all\modules\migrate\plugins\destinations\file.inc, line 393"
1358	Error	The specified file http://localhost/www/my_d6_site/sites/default/files/Huipengchen.jpg could not be copied to public://migrate//Huipengchen.jpg: "copy(http://localhost/www/my_d6_site/sites/default/files/Huipengchen.jpg): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found File C:\xampp\htdocs\www\my_d7_site\sites\all\modules\migrate\plugins\destinations\file.inc, line 393"
1360	Error	The specified file http://localhost/www/my_d6_site/sites/default/files/WIN_20160822_17_08_22_Pro.jpg could not be copied to public://migrate//WIN_20160822_17_08_22_Pro.jpg: "copy(http://localhost/www/my_d6_site/sites/default/files/WIN_20160822_17_08_22_Pro.jpg): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found File C:\xampp\htdocs\www\my_d7_site\sites\all\modules\migrate\plugins\destinations\file.inc, line 393"
1372	Error	The specified file http://localhost/www/my_d6_site/sites/default/files/Capture_0.PNG could not be copied to public://migrate//Capture_0.PNG: "copy(http://localhost/www/my_d6_site/sites/default/files/Capture_0.PNG): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found File C:\xampp\htdocs\www\my_d7_site\sites\all\modules\migrate\plugins\destinations\file.inc, line 393"
1387	Error	The specified file http://localhost/www/my_d6_site/sites/default/files/IMG_6311%20%281%29.jpg could not be copied to public://migrate//IMG_6311 (1).jpg: "copy(http://localhost/www/my_d6_site/sites/default/files/IMG_6311%20%281%29.jpg): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found File C:\xampp\htdocs\www\my_d7_site\sites\all\modules\migrate\plugins\destinations\file.inc, line 393"
1390	Error	The specified file http://localhost/www/my_d6_site/sites/default/files/IMG_1784_0.JPG could not be copied to public://migrate//IMG_1784_0.JPG: "copy(http://localhost/www/my_d6_site/sites/default/files/IMG_1784_0.JPG): failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found File C:\xampp\htdocs\www\my_d7_site\sites\all\modules\migrate\plugins\destinations\file.inc, line 393"
CommentFileSizeAuthor
my_file_migration_config.png83.51 KBzythyr

Comments

Zythyr created an issue. See original summary.

zythyr’s picture

It seems there was some issue copying files from live website to local. Specific to my situation, some files were actually missing but other files were hidden due to symbolic links. Over all, I resolved this issue by pulling files from live to local again and trying to do migration.

In additions, truly some files missing on the live website from the sites/default/files/ folder. I did a migration from D6 to D7 and noted down all the file ids of the missing files in the D6's database. Then, I wen to the D6 database and delete the rows that were referencing the missing files using the Mysql command example below. Then I repeated a fresh migration from D6 to D7. No more failed to copy files error occurred...

Example mysql command to delete all rows in the files table with the give fid.
DELETE from files WHERE fid IN (81,26,1304,1399,1508);

zythyr’s picture

Category: Bug report » Support request
Priority: Major » Minor
Status: Active » Fixed

Fixed.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.