Hi Roland
Hope you are well !
Here is the problem : I am trying to connect and import data from distant ftp file
Ftp connection is ok but I get a final message Cannot read file from FTP
I checked name of file and permissions to read and don't see anything wrong.
Any idea ?
Eric
- ekcsvi
- RO CSVI
- Tuesday, 07 January 2020
- Subscribe via email
0
Accepted Answer
Accepted Answer
Pending Moderation
Hi Roland
I got my provider on the phone and we agreed he is going to generate the files in a FTP directory I have set up for him on my server so case is closed... but we will never know what the issue is !
Regards
Eric
I got my provider on the phone and we agreed he is going to generate the files in a FTP directory I have set up for him on my server so case is closed... but we will never know what the issue is !

Regards
Eric
- more than a month ago
- RO CSVI
- # Permalink
Accepted Answer
Pending Moderation
Hello Eric,
Check the path set for FTP Root Folder on Source tab in your import template. It is possible that RO CSVI is not able to read the files from the folder you have set under Root. If you still have problem send me the FTP details you have used. I will test it here on my local site.
Check the path set for FTP Root Folder on Source tab in your import template. It is possible that RO CSVI is not able to read the files from the folder you have set under Root. If you still have problem send me the FTP details you have used. I will test it here on my local site.
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Hi
The Root Folder ( / ) and the file name are the same than in Filezilla ( which is working )
FTP connection is ok
Don't know what to do and you can't test because the FTP connection is based on IP
The Root Folder ( / ) and the file name are the same than in Filezilla ( which is working )
FTP connection is ok
Don't know what to do and you can't test because the FTP connection is based on IP
Accepted Answer
Pending Moderation
Hello Eric,
Can you send me a screenshot of Filezilla where you have your import file? Also in your Joomla global configuration page on System tab, what is the path set in Path to Log Folder field? Can you post it here?
Can you send me a screenshot of Filezilla where you have your import file? Also in your Joomla global configuration page on System tab, what is the path set in Path to Log Folder field? Can you post it here?
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Joomla global configuration page on System tab, what is the path set in Path to Log Folder field
-> .../administrator/logs
Attachments (1)
Accepted Answer
Pending Moderation
Hello,
I asked for Log file path so i can get the whole of root path from there. This will not help as i don't know what the prefix path for /administrator/logs
Can you also check your FTP logs and see if you can find any error in there?
-> .../administrator/logs
I asked for Log file path so i can get the whole of root path from there. This will not help as i don't know what the prefix path for /administrator/logs
Can you also check your FTP logs and see if you can find any error in there?
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Nothing special in logs where Joomla site is installed => connection ftp ok & don't say anything about file reading
Attachments (1)
Accepted Answer
Pending Moderation
Hello Eric,
Yes, there seems be no log of any error.
Can you paste the whole of log folder path as requested in my previous reply?
Also did you test the FTP connection using Test FTP button on Source tab? Does it say Connection ok? Can you post a screenshot of FTP details set on Source tab?
Yes, there seems be no log of any error.
Can you paste the whole of log folder path as requested in my previous reply?
Also did you test the FTP connection using Test FTP button on Source tab? Does it say Connection ok? Can you post a screenshot of FTP details set on Source tab?
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Hey Eric,
Since you can access the log file of the FTP server, can you use the Test button as Tharuna suggested and post the log of that? Please also include a screenshot of your FTP settings (you can remove any username/password).
Since you can access the log file of the FTP server, can you use the Test button as Tharuna suggested and post the log of that? Please also include a screenshot of your FTP settings (you can remove any username/password).
Kind regards,
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
The test button has been used... says the connection is OK
CSVI template simply says "cannot read file from FTP"
I tested on server with a small php script and it's returning the file names ok... don't know if this helps
here is the script :
****************
Return This :
Connecting to www.distant-site.fr via FTP...
Login Ok.
.
..
TAREXPP9.csv
TARFAMP1.txt
TARMARP1.txt
*****************
TAREXPP9.csv is the file I want to import with CSVI
CSVI template simply says "cannot read file from FTP"
I tested on server with a small php script and it's returning the file names ok... don't know if this helps
here is the script :
<?php
$ftp_host = "yourFTPHost";
$ftp_user = "yourUsername";
$ftp_password = "yourPassword";
//Connect
echo "<br />Connecting to $ftp_host via FTP...";
$conn = ftp_connect($ftp_host);
$login = ftp_login($conn, $ftp_user, $ftp_password);
//
//Enable PASV ( Note: must be done after ftp_login() )
//
$mode = ftp_pasv($conn, TRUE);
//Login OK ?
if ((!$conn) || (!$login) || (!$mode)) {
die("FTP connection has failed !");
}
echo "<br />Login Ok.<br />";
//
//Now run ftp_nlist()
//
$file_list = ftp_nlist($conn, "");
foreach ($file_list as $file)
{
echo "<br>$file";
}
//close
ftp_close($conn);
?>
****************
Return This :
Connecting to www.distant-site.fr via FTP...
Login Ok.
.
..
TAREXPP9.csv
TARFAMP1.txt
TARMARP1.txt
*****************
TAREXPP9.csv is the file I want to import with CSVI
Attachments (1)
Accepted Answer
Pending Moderation
Hello,
So I have been looking into this, the message cannot read file from FTP is generated when there is no list of filenames returned from the FTP server by Joomla. We don't use our own code but we use the Joomla core for connecting to an FTP server.
One thing I notice in your code is that you use the following line:
The second argument is the folder to read, which you leave empty. However in your template configuration this is set to a /. If you leave the FTP Root folder empty, can you run the import in that case?
Is there any jerror log file in the logs folder of Joomla? Just to be sure, Joomla didn't log any errors related to this.
So I have been looking into this, the message cannot read file from FTP is generated when there is no list of filenames returned from the FTP server by Joomla. We don't use our own code but we use the Joomla core for connecting to an FTP server.
One thing I notice in your code is that you use the following line:
$file_list = ftp_nlist($conn, "");
The second argument is the folder to read, which you leave empty. However in your template configuration this is set to a /. If you leave the FTP Root folder empty, can you run the import in that case?
Is there any jerror log file in the logs folder of Joomla? Just to be sure, Joomla didn't log any errors related to this.
Kind regards,
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Hi Roland
Back at work...
I tried it and Joomla return error "No folder has been given"
I did have a look at logs folder too and it doesn't seem that any errors are recorded relatively to this.
As I understand it's a Joomla problem : how can I set up Joomla in order that this script works ?
( PS : I have until monday evening to resolve the issue )
Thank you in advance !
Eric
Back at work...
However in your template configuration this is set to a /. If you leave the FTP Root folder empty, can you run the import in that case?
I tried it and Joomla return error "No folder has been given"
I did have a look at logs folder too and it doesn't seem that any errors are recorded relatively to this.
As I understand it's a Joomla problem : how can I set up Joomla in order that this script works ?
( PS : I have until monday evening to resolve the issue )
Thank you in advance !
Eric
Accepted Answer
Pending Moderation
Hello Eric,
Can you load the attached patch file and run your import? Let us know on how it goes.
Can you load the attached patch file and run your import? Let us know on how it goes.
Attachments (1)
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Hi Tharuna
I have copied the file source.php in folder /administrator/components/com_csvi/helper
Unfortunately I get the same error message :-(
Eric
I have copied the file source.php in folder /administrator/components/com_csvi/helper
Unfortunately I get the same error message :-(
Eric
Accepted Answer
Pending Moderation
Hello Eric,
If you are getting the same error message means that the file has not been copied correct. Please use the link i provided in my previous reply to load the patch file and check the import.
If you are getting the same error message means that the file has not been copied correct. Please use the link i provided in my previous reply to load the patch file and check the import.
Kind regards,
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Tharuna
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Retried loading the patch via maintenance = same result : Joomla return error "cannot read file from FTP"

Accepted Answer
Pending Moderation
Hello Erik,
Can you please give it a try with this patch? I saw there is one more thing we can eliminate. Let me know how it goes.
Can you please give it a try with this patch? I saw there is one more thing we can eliminate. Let me know how it goes.
Attachments (1)
Kind regards,
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
Accepted Answer
Pending Moderation
Hi Roland
Thank you very much for your desire to help me so far !
Unfortunately : still the same, not working and still same error message
But please wait until Monday now as I did some tests on ANOTHER DISTANT SERVER and CSVI is working fine there.
I will send a mail to the supplier of the file who assured me it wasn't their fault we can't read the file on their server.
May be there is something there !
Eric
Thank you very much for your desire to help me so far !
Unfortunately : still the same, not working and still same error message
But please wait until Monday now as I did some tests on ANOTHER DISTANT SERVER and CSVI is working fine there.
I will send a mail to the supplier of the file who assured me it wasn't their fault we can't read the file on their server.
May be there is something there !
Eric
Accepted Answer
Pending Moderation
Hello Eric,
There is definitely not a common problem with the FTP because it is working for many other people. The one thing I am thinking of is that your provider perhaps doesn't support passive connections. That has been an issue in the past. This is the only thing I can think of at this point.
There is definitely not a common problem with the FTP because it is working for many other people. The one thing I am thinking of is that your provider perhaps doesn't support passive connections. That has been an issue in the past. This is the only thing I can think of at this point.
Kind regards,
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
RolandD
=========================
If you use our extensions, please post a rating and a review at the Joomla! Extension Directory
- Page :
- 1
There are no replies made for this post yet.
Be one of the first to reply to this post!
Be one of the first to reply to this post!
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here. Register Here »