FTP File Read Access Denied

Hello NR Team,
I am Trying to read a file from remote ftp server. But I am receiving error access denied.

[
    {
        "id": "8c9f40dfe34c996a",
        "type": "tab",
        "label": "Flow 1",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "2d15e0ae3c021f91",
        "type": "ftp in",
        "z": "8c9f40dfe34c996a",
        "ftp": "3ff000adc12c66a2",
        "operation": "list",
        "filename": "backup/WD008DA2",
        "localFilename": "",
        "name": "",
        "x": 330,
        "y": 40,
        "wires": [
            [
                "7b44bfa7a13102fc"
            ]
        ]
    },
    {
        "id": "ebaa3e94ed1cfb7b",
        "type": "debug",
        "z": "8c9f40dfe34c996a",
        "name": "debug 1",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 740,
        "y": 40,
        "wires": []
    },
    {
        "id": "32e7857053c83cf9",
        "type": "inject",
        "z": "8c9f40dfe34c996a",
        "name": "",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "",
        "payloadType": "date",
        "x": 160,
        "y": 40,
        "wires": [
            [
                "2d15e0ae3c021f91"
            ]
        ]
    },
    {
        "id": "7b44bfa7a13102fc",
        "type": "function",
        "z": "8c9f40dfe34c996a",
        "name": "function 1",
        "func": "msg.payload=msg.payload[26782];\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 500,
        "y": 40,
        "wires": [
            [
                "ebaa3e94ed1cfb7b"
            ]
        ]
    },
    {
        "id": "37c23ceb12e50d38",
        "type": "zip",
        "z": "8c9f40dfe34c996a",
        "name": "",
        "mode": "decompress",
        "filename": "",
        "compressionlevel": 6,
        "outasstring": false,
        "x": 730,
        "y": 160,
        "wires": [
            []
        ]
    },
    {
        "id": "095b2a645732137d",
        "type": "debug",
        "z": "8c9f40dfe34c996a",
        "name": "debug 3",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 760,
        "y": 220,
        "wires": []
    },
    {
        "id": "6ff7e20d7e254180",
        "type": "inject",
        "z": "8c9f40dfe34c996a",
        "name": "read",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "",
        "payloadType": "date",
        "x": 130,
        "y": 220,
        "wires": [
            [
                "e6088fc20d358684"
            ]
        ]
    },
    {
        "id": "e6088fc20d358684",
        "type": "function",
        "z": "8c9f40dfe34c996a",
        "name": "function 3",
        "func": "msg.filename = \"WD008DA2_MODBUS_230712_073101.csv.gz\";\nreturn msg;",
        "outputs": 1,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 320,
        "y": 220,
        "wires": [
            [
                "d2f3bb84c6784a30"
            ]
        ]
    },
    {
        "id": "d2f3bb84c6784a30",
        "type": "ftp in",
        "z": "8c9f40dfe34c996a",
        "ftp": "a7676b1a.e9714",
        "operation": "get",
        "filename": "backup/WD008DA2",
        "localFilename": "",
        "name": "",
        "x": 490,
        "y": 220,
        "wires": [
            [
                "095b2a645732137d"
            ]
        ]
    },
    {
        "id": "3ff000adc12c66a2",
        "type": "ftp",
        "host": "103.117.180.48",
        "port": "21",
        "secureOptions": "",
        "user": "mainftp",
        "connTimeout": "10000",
        "pasvTimeout": "",
        "keepalive": ""
    },
    {
        "id": "a7676b1a.e9714",
        "type": "ftp",
        "host": "103.117.180.48",
        "port": "21",
        "secureOptions": "",
        "user": "mainftp",
        "connTimeout": "1000",
        "pasvTimeout": "",
        "keepalive": ""
    }
]

add a catch node and connect it to a debug node (set output to display the complete msg object) and see if that shows anything.

You do have a valid user and password...correct?


Yes Username and Password are correct as i am able to list file from above node red flow.

I have had little success using any of the FTP nodes. Instead I use Exec nodes to run the system commands to achieve what I want with FTP.

1 Like

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.