FTP users can't rename a file if the directory path is specified.
(Last modified: 12Apr2002)
This document (10052554) is provided subject to the disclaimer at the end of this document.
fact
Novell NetWare 5.1.
Novell FTP Server (NWFTPD.NLM).
symptom
FTP users can't rename a file if the directory path is specified.
cause
If a path beginning with a slash ("/") is specified, FTP still assumes a relative path, and appends the current path, and fails:
ftp> ren /sys/newtest/config.sys config.old
550 sys//sys/newtest/config.sys: File unavailable
If a correct relative path is entered, the rename still fails:
ftp> ren newtest/config.sys newtest/config.old
350 Requesting file action pending further information "newtest/config.sys"
550 Could not rename newtest/config.sys
fix
NWFTPD.NLM has been enhanced to report support renaming with specified paths. It will also allow the "target" path to differ from the "source" path, thereby accomplishing a "move" operation. NOTE that if rename is used to move a file, the resulting file will have a new time stamp. Most of this functionality is included in NetWare 5.1 Support Pack 2, with the exception of one enhancement noted at the end of example #4 below. This last additional enhancement requires the updates found in NWFTPD.NLM v5.01i, November 8, 2000. This (or newer) NWFTPD.NLM is also part of NetWare 5.1 Support Pack 3.
Below are examples of the new implementation. Consider an FTP session, with the current directory as /vol1/dir1.
1. Users may rename from any directory to any directory.
I.E. ren /vol2/dir2/file1 /vol3/dir3/file2
2. If the user doesn't give the path in the "target" name, the path of the "source" name is assumed.
I.E. ren /vol2/dir2/file1 file2
This will rename file1 to file2 in /vol2/dir2 itself (even though the user was in /vol1/dir1 at the time).
3. To move a file from some path to the current directory, users should specify "./" and then the file name.
I.E. ren /vol2/dir2/file1 ./file2
this will result in /vol2/dir2/file1 to be moved to /vol1/dir1/file2
4. Support has also been added for server navigation. But the constraint is that files cannot be moved between servers.
Assume the user is at server1 (which can be the FTP Server or a remote server).
I.E. ren //server2/vol1/dir1/file1 /vol2/dir2/file2
This will rename (On server2) /vol1/dir1/file1 to /vol2/dir2/file2.
With NetWare 5.1 Support Pack 2, only the "source" path may have a server name specified. Therefore the following 2 examples will FAIL.
I.E. ren //server1/vol1/file1 //server2/vol1/file1
I.E. ren //server1/vol1/file1 //server1/vol1/file2
Note that even though the second example is not actually trying to move the file to a different server, it will still fail because NWFTPD.NLM will not accept a server name in the "target" path.
With the addition of the updates in NWFTPD.NLM v5.01i, a server name can be contained in the "target" path, so long as it is the SAME as the servername in the "source" path. Therefore the following example would succeed:
I.E. ren //server1/vol1/file1 //server1/vol1/file2
document
Document Title: | FTP users can't rename a file if the directory path is specified. |
Document ID: | 10052554 |
Solution ID: | NOVL9096 |
Creation Date: | 01May2000 |
Modified Date: | 12Apr2002 |
Novell Product Class: | Connectivity Products NetWare |
disclaimer
The Origin of this information may be internal or external to Novell. Novell makes all reasonable efforts to verify this information. However, the information provided in this document is for your information only. Novell makes no explicit or implied claims to the validity of this information.
Any trademarks referenced in this document are the property of their respective owners. Consult your product manuals for complete trademark information.