This page describes the gcsfuse
command-line options used to interact with
Cloud Storage FUSE.
Synopsis
gcsfuse GLOBAL_OPTIONS BUCKET_NAME MOUNT_POINT
Where:
GLOBAL_OPTIONS
are the options that control how the mount is set up and how Cloud Storage FUSE behaves.BUCKET_NAME
is the name of the bucket to mount. For example,my-mount-bucket
. Optional. Exclude a bucket name from this command to perform dynamic mounting.MOUNT_POINT
is the local directory where the bucket will be mounted. For example,/path/to/mount/point
.
Description
The gcsfuse CLI is used to mount Cloud Storage buckets as file systems on a local machine.
Global options
Global options | Description |
---|---|
--anonymous-access BOOLEAN |
Disables authentication for requests. This flag should be set if you're
using a custom endpoint that doesn't support authentication. This flag
should also be set if you're using Cloud Storage FUSE with public buckets.
The default value is false . |
--app-name VALUE |
The application name of the mount. |
--billing-project VALUE |
Specifies a project to use for billing when the mounted bucket is accessed. This flag is often required when mounting a bucket enabled with Requester Pays. The default project is none. |
--client-protocol VALUE |
Specifies the protocol used for communicating with the
Cloud Storage backend. The value can be http1
for HTTP/1.1 or http2 for HTTP/2. The default value is
http1 . |
--config-file VALUE |
Specifies the path to the configuration file
you want to use to configure Cloud Storage FUSE behaviors. For example,
--config-file /etc/gcsfuse.yaml |
--custom-endpoint VALUE |
Specifies an alternative custom endpoint for fetching data.
The custom endpoint must support the equivalent resources and operations as
the Cloud Storage JSON endpoint, https://storage.googleapis.com/storage/v1 .
If a custom endpoint is not specified, Cloud Storage FUSE uses the global
Cloud Storage JSON API endpoint, https://storage.googleapis.com/storage/v1 .
If authentication isn't supported on the custom endpoint you specify, set
the --anonymous-access flag to true to
bypass authentication.
|
--debug_fuse_errors |
If excluded, evaluates to False and prevents
FUSE errors
from being logged to the console (if --foreground
is used) or the log file (if --log-file is used). |
--debug_fuse |
Enables FUSE-related
debugging output. If this option is specified, the severity level of logs is
automatically set to trace , which includes trace logs,
debug logs, info logs, warning logs, and error logs. |
--debug_gcs |
Prints Cloud Storage request and timing information. If this
option is specified, the severity level of logs is
automatically set to trace , which includes trace logs,
debug logs, info logs, warning logs, and error logs. |
--debug-invariants |
Panics when internal invariants are violated. |
--debug_mutex |
Prints debug messages when a mutex is held too long. If this option is
specified, the severity level of logs is automatically set to
trace , which includes trace logs, debug logs, info logs,
warning logs, and error logs. |
--dir-mode VALUE |
Permissions bits for directories, in octal. The default value is
755 . |
--enable-nonexistent-type-cache |
Creates a type cache entry with the type NonexistentType
if a file is not found in Cloud Storage. If the file gets created
in Cloud Storage but the NonexistentType entry for
the file is cached, then Cloud Storage FUSE cannot request that file until
the NonexistentType entry is removed from the type cache. |
--experimental-enable-json-read |
Specifies Cloud Storage FUSE to use the Cloud Storage JSON API for read operations. By default, read operations are performed using the Cloud Storage XML API. |
--experimental-opentelemetry-collector-address VALUE |
Exports metrics to the OpenTelemetry Collector at the specified address. Experimental. |
--file-mode VALUE |
Specifies permissions bits for files, in octal. Default value is 644 . |
--foreground |
Runs the gcsfuse command in the foreground. |
--gid VALUE |
Specifies the Group Identifier (GID) owner of all inodes. The default GID value is -1 . |
--help or -h |
Displays help about Cloud Storage FUSE. |
--http-client-timeout VALUE |
Specifies how long the Cloud Storage FUSE HTTP client can
wait to get a response from the server before timing out. The
default value is 0s , which indicates no timeout. |
--ignore-interrupts VALUE |
Instructs Cloud Storage FUSE to ignore system interrupt signals, like
SIGINT triggered by Control+C . This prevents signals from
terminating in-flight operations. Values are true
or false . The default value is true . |
--implicit-dirs |
Implicitly includes folders and managed folders. See the files and directories documentation in GitHub for more information. |
--key-file VALUE |
Specifies an absolute path to the credential JSON key file for authenticating requests to Cloud Storage. By default, Cloud Storage FUSE uses Application Default Credentials to authenticate requests. |
--limit-bytes-per-sec VALUE |
Specifies the bandwidth limit at which Cloud Storage FUSE can read data
from Cloud Storage, measured over a 30-second window. The default
limit value is -1 , which specifies no limit. |
--limit-ops-per-sec VALUE |
Specifies a limit for operations performed per second, measured over a
30-second window. The default limit value is -1 , which
specifies no limit. |
--log-file VALUE |
Specifies the file for storing logs that can be parsed by
Fluentd. When not
provided, plain text logs are printed to stdout when
Cloud Storage FUSE is run in the foreground, or to syslog when
Cloud Storage FUSE is run in the background. |
--log-format VALUE |
Specifies the format of the log file. The value can be either
text or json . The default value is
json . |
--max-conns-per-host VALUE |
Specifies the maximum number of TCP connections allowed per server. This
becomes effective when --client-protocol is set to
http1 . The default value is 0 , which specifies
that there is no limit on TCP connections except for limitations set by your
machine's specifications. |
--max-idle-conns-per-host VALUE |
Specifies the maximum number of idle connections allowed per server. The
default value is 100 . |
--max-retry-sleep VALUE |
Specifies the maximum duration that Cloud Storage FUSE is allowed to sleep in
a retry loop with
exponential backoff. Once the
backoff duration exceeds the specified maximum duration, the retry continues
with the specified maximum duration. The default limit value is
30s (30 seconds). |
-o VALUE |
Specifies additional system-specific mount options. Most generic mount
options in FUSE (such as |
-o ro |
Mounts a bucket as read-only. |
--only-dir VALUE |
Mounts only a specific directory within a bucket. |
--rename-dir-limit VALUE |
Allows the renaming of directories containing fewer descendants than the
specified limit. The default limit value is 0 . |
--retry-multiplier VALUE |
Specifies the waiting time between two consecutive retries. |
--reuse-token-from-url |
If included, evaluates to True and specifies that the token acquired
from --token-url be used. If excluded, evaluates to False and
specifies that the token acquired from --token-url shouldn't
be reused. |
--sequential-read-size-mb VALUE |
Specifies the chunk size of the data to be downloaded from Cloud Storage, in megabytes (MB). |
--stackdriver-export-interval VALUE |
Exports metrics to stackdriver with the specified interval. The default
value is 0s , which specifies no exporting. |
--stat-cache-capacity VALUE |
Deprecated. Specifies the number of entries that the stat cache
can hold. This impacts memory consumption. The default value is
4096 .
Instead of this flag, use the metadata-cache: stat-cache max-size
field in a configuration file
to set the maximum size of the stat cache. For more information, see the
Cloud Storage FUSE configuration file.
|
--stat-cache-ttl VALUE |
Deprecated. Specifies how long to cache StatObject
results and inode attributes. The default value is 60s .
Instead of this flag, use the metadata-cache: ttl-secs field
in a configuration file to specify the
time to live (TTL) of metadata entries of both stat and type caches. For
more information, see the Cloud Storage FUSE configuration file. |
--type-cache-ttl VALUE |
Deprecated. Specifies how long to cache the mapping between
names and files or directories in directory inodes. The default value is
60s .
Instead, use the metadata-cache: ttl-secs field to specify the
time to live (TTL) of metadata entries of both stat and type caches. For
more information, see the
Cloud Storage FUSE configuration file. |
--temp-dir value VALUE |
Specifies a path to the temporary directory where writes are staged
prior to being uploaded to Cloud Storage. The default value is your
system default, most likely /tmp . |
--token-url VALUE |
Specifies a URL for getting an access token when the
--key-file is absent. |
--uid VALUE |
Specifies the User Identifier (UID) owner of all inodes. The default
UID value is -1 . |
--version or -v |
Displays the Cloud Storage FUSE version you have installed. |