CentOS 多线程下载工具 lftp

lftp 使用方法:

# lftp -c "pget -n 10 http://www.21andy.com/test.tar.gz"

-c 表示断点续传
-n10 表示10线程

lftp 安装:

# yum -y install lftp

装好后看一下
# lftp-v

LFTP | Version 3.7.11 | Copyright (c) 1996-2009 Alexander V.Lukyanov

LFTP is free software: you can redistribute it and/ormodify
it under the terms of the GNU General Public License as publishedby
the Free Software Foundation, either version 3 of the License,or
(at your option) any later version.

This program is distributed in the hope that it will beuseful,
but WITHOUT ANY WARRANTY; without even the implied warrantyof
MERCHANTABILITY or FITNESS FOR A PARTICULARPURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General PublicLicense
along with LFTP.  If not, see .

Send bug reports and questions to the mailing list .

Libraries used: Readline 5.1

# manlftp

NAME
        lftp - Sophisticated file transferprogram

SYNTAX
        lftp [-d] [-e cmd] [-p port] [-u user[,pass]][site]
        lftp -f script_file
        lftp -c commands
        lftp --version
        lftp --help

VERSION
        This man page documents lftp version3.7.7.

DESCRIPTION
        lftp  is  file  transfer program thatallows sophisticated ftp, http and other connections to otherhosts. If site is specified then lftp will connect to that siteotherwise a connection has to be estab-
        lished with the open command.

        lftp can handle several file access methods -ftp, ftps, http, https, hftp, fish, sftp and file (https and ftpsare only available when lftp is compiled with GNU TLS or OpenSSLlibrary). You can specify the
        method  to  use  in  ‘open  URL’  command,  e.g.  ‘open  http://www.us.kernel.org/pub/linux’.  hftp  is  ftp-over-http-proxy  protocol.  It  can  be  used automatically instead of ftp if ftp:proxy is set to
        ‘http://proxy[:port]’. Fish is a protocolworking over an ssh connection to a unix account. SFtp is aprotocol implemented in ssh2 as sftp subsystem.

        Every operation in lftp is reliable, that is anynot fatal error is ignored and the operation is repeated. So ifdownloading breaks, it will be restarted from the pointautomatically.  Even  if  ftp  server
        does not support REST command, lftp will try toretrieve the file from the very beginning until the file istransferred completely.

        lftp  has shell-like commandsyntax allowing you to launch several commands in parallel inbackground (&). It is also possible to group commands within ()and execute them in background. All background jobs
        are executed in the same single process. You canbring a foreground job to background with ^Z (c-z) and back withcommand ‘wait’ (or ‘fg’ which is alias to ‘wait’). To list runningjobs, use command ‘jobs’.
        Some commands allow redirecting their output(cat, ls, ...) to file or via pipe to external command. Commandscan be executed conditionally based on termination status ofprevious command (&&, ||).

        If you exit lftp when some jobs are not finishedyet, lftp will move itself to nohup mode in background. The samehappens when you have a real modem hangup or when you close anxterm.

        lftp  has builtin mirror whichcan download or update a whole directory tree. There is alsoreverse mirror (mirror -R) which uploads or updates a directorytree on server. Mirror can also synchronize direc-
        tories between two remote servers, using FXP ifavailable.

        There is command ‘at’ to launch a job atspecified time in current context, command ‘queue’ to queuecommands for sequential execution for current server, and muchmore.

        On startup, lftp executes /etc/lftp.conf andthen ~/.lftprc and ~/.lftp/rc. You can place aliases and ‘set’commands there. Some people prefer to see full protocol debug, use‘debug’ to turn the  debug  on.
        Use ‘debug 3’ to see only greeting messages anderror messages.

        lftp  has  anumber of settable variables. You can use ‘set -a’ to see allvariables and their values or ‘set -d’ to see list ofdefaults.  Variable names can be abbreviated andprefix can be omitted unless
        the rest becomes ambiguous.

        If lftp was compiled with OpenSSL (configure--with-openssl), then it includes software developed by the OpenSSLProject for use in the OpenSSL Toolkit.(http://www.openssl.org/)
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值