MuleSoft · SFTP Connector
SFTP:FILE_ALREADY_EXISTS
Short answer
SFTP:FILE_ALREADY_EXISTS means the operation tried to create a file where a file with the same name already exists. It happens, for example, when Write uses the CREATE_NEW mode on an existing file's path, so change the write mode or the target name.
VerifiedLast verified
01Error text
Error type: SFTP:FILE_ALREADY_EXISTS02Likely causes
- An attempt was made to create a file at the same location and with the same name as an existing file.
- For example, the Write operation uses the
CREATE_NEWmode and the path is that of an existing file.
03How to fix it
- Decide whether the existing file should be replaced, appended to or kept.
- Set the Write operation's mode to match, or write to a different file name.
- Handle the failure with an error handler of type
SFTP:FILE_ALREADY_EXISTS.
04Official documentation
→Related errors
- FILE:FILE_ALREADY_EXISTSFILE:FILE_ALREADY_EXISTS means the target file already exists and the operation is not allowed to overwrite it. Set Overwrite to true, pick a different write mode, or use a unique file name.
- SFTP Write in APPEND mode overwrites the file or failsWhen SFTP Write in APPEND mode overwrites the file or fails with a generic error, the server is a legacy one that lacks the SSH_FXF_APPEND flag. Set Write Strategy to CUSTOM and Write Mode to CUSTOM_APPEND.
- SFTP:ILLEGAL_PATHSFTP:ILLEGAL_PATH means the path given to the SFTP operation is invalid, for example because it does not exist. Correct the path, or create the directory on the server first.
Test every fix in a non-production environment before you apply it to production. See how entries are verified.
More for MuleSoft work:Open MuleSoft jobsMuleSoft rates and salariesHire a senior MuleSoft developer