Deze pagina is nog niet beschikbaar in uw eigen taal. We werken er hard aan om meer taalversies toe te voegen. Bedankt voor uw steun.

On this page

Show all

Help Center/ Object Storage Service/ obsutil/ FAQs/ Can I Use obsutil to Directly Save a Listing Result to a Local File?

Can I Use obsutil to Directly Save a Listing Result to a Local File?

Updated on 2025-01-16 GMT+08:00

obsutil does not allow you to directly save a listing result to a local file, but you can redirect a listing result displayed on the screen in standard output to a specified local file by relying on the redirection supported by OS. The following uses the listing of objects in a bucket as an example:

  • In Windows, run the following redirection command in the CLI:
    obsutil ls obs://bucketName -format=default -limit=0 > D:/result.txt
  • In Linux or macOS, run the following command:
    ./obsutil ls obs://bucketName -format=default -limit=0 > /root/result.txt
    NOTE:

    In Windows, you need to perform the redirection operation in the CLI to redirect the output to a local file. Do not run the redirection command in the obsutil executable file because obsutil does not support redirection.

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback