Page 1 of 1

FTP File > Save issue (Eclipse 3.2 plugin)

Posted: Wed Jan 30, 2008 12:50 am
by ktrustin
I'm running oXygen 8.2 on Eclipse 3.2 (CentOS Linux 5, Sun JDK 1.5.0_05) under the 30 day trial license. I open an xml file via ftp from an AIX server and edit it. No problem. But when I try to save the file, I get the following error:

Save could not be completed
Reason: [553 (path-to-file): The file access permissions do not allow the specified action.]

The Details button shows the same error.

In fact, I do have write permissions to the file in question, and I'm logging in as myself via ftp when I open the file. I verified that I can send and receive to/from the same ftp service in passive mode. The ftp daemon doesn't support UTF-8 but it does support ISO-8859-1 and I have oXygen set to use the latter in the Preferences dialog. Just for fun I changed the files permissions to 666 and tried again, but no joy.

Suggestions are welcome.

Re: FTP File > Save issue (Eclipse 3.2 plugin)

Posted: Wed Jan 30, 2008 12:28 pm
by sorin_ristache
Hello,

The error message is received from the FTP server. You can check the permissions for that file in the dialog Open using FTP/WebDAV by right clicking on the file and selecting Change permissions to see if you have write permission.

The error code 553 means that the file name is not allowed, for example it contains spaces. This should not be a problem with the FTP client of oXygen because it handles file paths with spaces correctly. I just checked that by opening and saving a file with spaces in the name on a FTP server. It is strange that the server sends a message with the error code 553 but with the text of the error about the file permissions instead of the file name. Can you edit and save the same file with other FTP client? What does the FTP server log say about the failed save operation?


Regards,
Sorin

Re: FTP File > Save issue (Eclipse 3.2 plugin)

Posted: Wed Jan 30, 2008 5:28 pm
by ktrustin
Thanks for your reply.
sorin wrote:The error message is received from the FTP server. You can check the permissions for that file in the dialog Open using FTP/WebDAV by right clicking on the file and selecting Change permissions to see if you have write permission.
The 'Change permissions' dialog box shows 'Permissions: 640', which is correct since I changed it back from 666.
sorin wrote:The error code 553 means that the file name is not allowed, for example it contains spaces.
Odd. Here's the fully formed filespec with the ftp prefix:
ftp://ktrustin@rs6k.owu.edu/opt/carsi/CXConnect/application/forms/develop/OWtamajor.xml
sorin wrote:Can you edit and save the same file with other FTP client?
I can successfully 'get' the file with my native CentOS Linux ftp client, edit it, and 'put' the file back, replacing the original.
sorin wrote:What does the FTP server log say about the failed save operation?
OK, now this is truly weird. When I try the same oXygen FTP File > Save operation today, I get a different error:

Save could not be completed. Reason: Could not obtain encoding.

The Details button shows:
450 opt/carsi/CXConnect/application/form/develop/OWtamajor.xml: Cannot open or remove a file containing a running program.

Running fuser on the above file shows it not to be in use by any other process. After I click the OK button in the Save Problems dialog, I find that the file on the ftp server side has been overwritten with a zero byte file (yes, I made a backup first to be safe). Here's debug info for the save operation from the ftp daemon:

ftpd[97876]: rs6k FTP server (Version 4.2 Fri Feb 3 22:13:23 CST 2006) ready.
ftpd[97876]: command: USER ktrustin^M
ftpd[97876]: <--- 331
ftpd[97876]: Password required for ktrustin.
ftpd[97876]: command: PASS
ftpd[97876]: <--- 230-
ftpd[97876]: Last unsuccessful login: Wed Jan 30 08:52:30 EST 2008 on ftp from ktrustin
ftpd[97876]: <--- 230-
ftpd[97876]: Last login: Wed Jan 30 09:24:38 EST 2008 on ftp from ktrustin
ftpd[97876]: <--- 230
ftpd[97876]: User ktrustin logged in.
ftpd[97876]: command: TYPE I^M
ftpd[97876]: <--- 200
ftpd[97876]: Type set to I.
ftpd[97876]: command: PASV^M
ftpd[97876]: <--- 227
ftpd[97876]: Entering Passive Mode (192,68,223,3,218,103)
ftpd[97876]: command: CWD /opt/carsi/CXConnect/application/form/develop/OWtamajor.xml^M
ftpd[97876]: <--- 550
ftpd[97876]: /opt/carsi/CXConnect/application/form/develop/OWtamajor.xml: A parameter must be a directory.
ftpd[97876]: command: LIST -L /opt/carsi/CXConnect/application/form/develop/OWtamajor.xml^M
ftpd[97876]: <--- 150
ftpd[97876]: Opening data connection for /bin/ls.
ftpd[97876]: <--- 226
ftpd[97876]: Transfer complete.
ftpd[97876]: command: PASV^M
ftpd[97876]: <--- 227
ftpd[97876]: Entering Passive Mode (192,68,223,3,218,104)
ftpd[97876]: command: STOR /opt/carsi/CXConnect/application/form/develop/OWtamajor.xml^M
ftpd[97876]: <--- 150
ftpd[97876]: Opening data connection for /opt/carsi/CXConnect/application/form/develop/OWtamajor.xml.
ftpd[97876]: <--- 226
ftpd[97876]: Transfer complete.

One thing that stands out to me is that oXygen tried a CWD operation on the fully formed filespec. Maybe you'll notice something more useful. Thanks for your help.

Re: FTP File > Save issue (Eclipse 3.2 plugin)

Posted: Wed Jan 30, 2008 5:54 pm
by ktrustin
Sorin:

I found the problem: By default, the native AIX ftp daemon locks files while in transfer. After I restarted the daemon with the -U parameter to tell it to leave them unlocked, FTP File > Save from oXygen's Eclipse plugin works fine. Sorry for the red herring.

Regards,
Kirk

Re: FTP File > Save issue (Eclipse 3.2 plugin)

Posted: Wed Jan 30, 2008 6:06 pm
by sorin_ristache
The CWD command is a shortcut for finding out if the requested URL is a file or a folder. Please post a fragment of the server log file with the error code 450 or 553. The response codes between 100 and 299 are not for errors.


Regards,
Sorin

Re: FTP File > Save issue (Eclipse 3.2 plugin)

Posted: Wed Jan 30, 2008 6:11 pm
by sorin_ristache
ktrustin wrote:Sorin:

I found the problem:
Oh, I am glad you solved the problem.


Regards,
Sorin