Find the answer to your Linux question:
Results 1 to 5 of 5
Browse through the manual and couldn't find the command. Does anyone know how to refresh the directory in lftp?...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Jan 2007
    Posts
    9

    how to refresh in lftp


    Browse through the manual and couldn't find the command. Does anyone know how to refresh the directory in lftp?

  2. #2
    Linux Enthusiast likwid's Avatar
    Join Date
    Dec 2006
    Location
    MA
    Posts
    649
    You mean like, typing dir?

  3. #3
    Just Joined!
    Join Date
    Jan 2007
    Posts
    1

    Smile Did you try...

    Did you try
    ls
    ?
    ls gives a list of files in a directory.
    ( That is a small L by the way)

    Basicwebus

  4. $spacer_open
    $spacer_close
  5. #4
    Just Joined!
    Join Date
    Jan 2007
    Posts
    9
    No, I mean something like when you use gftp, if you have new files in the remote machine then you need to click refresh in order to see it. What's the corresponding command for that?

  6. #5
    Just Joined!
    Join Date
    Apr 2011
    Posts
    2

    howto refresh dir lftp

    Heya,

    I've just registered to Linux Forums to post the answer to this (easy) question. The reason i'm doing that is because i'm struggling to get RID off m$ products and lftp is the ftp client that i'm currently trialing and i had exactly the same question/problem as you. Therefore even tho it's been 4 years since you posted that question, i'm posting this answer w/ the hope that it will be useful to somebody else in the future.

    I found 2 ways to refresh a dir when connected using lftp.

    The simplest one: just change directory!

    So you're in /a and you want it refreshed? "cd /" then back to "cd /a" and it'll refresh /a. As easy as that!

    Real pros will you tell however that there is a "cache" trigger : Let's issue "help cache"

    <<
    help cache
    Usage: cache [SUBCMD]
    cache command controls local memory cache

    The following subcommands are recognized:
    stat - print cache status (default)
    on|off - turn on/off caching
    flush - flush cache
    size <lim> - set memory limit
    expire <Nx> - set cache expiration time to N seconds (x=s)
    minutes (x=m) hours (x=h) or days (x=d)
    >>

    So if we do :

    <<
    cache flush
    ls
    >>

    It will refresh the PWD (Presently Working Dir). Alternatively issuing "cache off" will get rid of the cache as a whole.

    ENJOY!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •