Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to make erlang timed request for ftp files

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/01 Report--

This article introduces you how to erlang regular request ftp file, the content is very detailed, interested friends can refer to, hope to be helpful to you.

FTP is the abbreviation of File Transfer Protocol, also known as File transfer Protocol, is a way to upload and download data to Internet. FTP is a recognized and simple protocol, which is the most effective way to transfer single file and multiple files, and the only effective way to upload files.

IIS7 server management tools can be batch management, scheduled upload and download, synchronous operation, data backup, expiration reminder, automatic update. IIS7 server management tools are suitable for Windows operating system and liunx operating system; support Ftp client batch operation.

Official website address

One: ftp access process

1. Establish a connection

{ok,Pid} = ftp:open (Host).

2. Log in to ftp server

Ftp:user (Pid, User, Password).

3. The path to enter the clause

Ftp:cd (Pid, Path).

4. Download the terms and conditions file locally

%% name: clause name

%% LocalFileName: local storage address

Ftp:recv (Pid, Name,LocalFileName).

5. Read clause

{ok, Manual} = file:read_file (LocalFileName).

=

Second: sftp access process

1. Create a new configuration file sftp.config

{sshdemo, [

{ssh,Host}

{port,22}

{user,User}

{password,Pwd}

]}.

2. Load the configuration file

Ct:install ([{config, ["sftp.config"]}]).

3. Start interactive

Ct:start_interactive ().

4. Establish a connection

{ok,Pid} = ct_ssh:connect (sshdemo,sftp).

5. Read the file

Ct_ssh:read_file (Pid,FileName).

Note: log files are generated when accessing sftp. What I did at that time was to delete them. If there is a better way, please let me know.

On how to erlang timed request ftp file to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report