Device name of an attached disk volume, which should align with a device_name specified by job.allocation_policy.instances[0].policy.disks[i].device_name or defined by the given instance template in job.allocation_policy.instances[0].instance_template.
↳ mount_path
string
The mount path for the volume, e.g. /mnt/disks/share.
↳ mount_options
array
Mount options vary based on the type of storage volume: * * For a Cloud Storage bucket, all the mount options provided by the gcsfuse tool are supported. * * For an existing persistent disk, all mount options provided by the mount command except writing are supported. This is due to restrictions of multi-writer mode. * * For any other disk or a Network File System (NFS), all the mount options provided by the mount command are supported.
getNfs
A Network File System (NFS) volume. For example, a
Filestore file share.
Device name of an attached disk volume, which should align with a
device_name specified by
job.allocation_policy.instances[0].policy.disks[i].device_name or
defined by the given instance template in
job.allocation_policy.instances[0].instance_template.
Returns
Type
Description
string
hasDeviceName
setDeviceName
Device name of an attached disk volume, which should align with a
device_name specified by
job.allocation_policy.instances[0].policy.disks[i].device_name or
defined by the given instance template in
job.allocation_policy.instances[0].instance_template.
Parameter
Name
Description
var
string
Returns
Type
Description
$this
getMountPath
The mount path for the volume, e.g. /mnt/disks/share.
Returns
Type
Description
string
setMountPath
The mount path for the volume, e.g. /mnt/disks/share.
Parameter
Name
Description
var
string
Returns
Type
Description
$this
getMountOptions
Mount options vary based on the type of storage volume:
For a Cloud Storage bucket, all the mount options provided
by
the gcsfuse tool
are supported.
For an existing persistent disk, all mount options provided by the
mount command
except writing are supported. This is due to restrictions of
multi-writer
mode.
For any other disk or a Network File System (NFS), all the
mount options provided by the mount command are supported.
Mount options vary based on the type of storage volume:
For a Cloud Storage bucket, all the mount options provided
by
the gcsfuse tool
are supported.
For an existing persistent disk, all mount options provided by the
mount command
except writing are supported. This is due to restrictions of
multi-writer
mode.
For any other disk or a Network File System (NFS), all the
mount options provided by the mount command are supported.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Google Cloud Batch V1 Client - Class Volume (1.2.2)\n\nVersion latestkeyboard_arrow_down\n\n- [1.2.2 (latest)](/php/docs/reference/cloud-batch/latest/V1.Volume)\n- [1.2.1](/php/docs/reference/cloud-batch/1.2.1/V1.Volume)\n- [1.1.7](/php/docs/reference/cloud-batch/1.1.7/V1.Volume)\n- [1.0.3](/php/docs/reference/cloud-batch/1.0.3/V1.Volume)\n- [0.17.0](/php/docs/reference/cloud-batch/0.17.0/V1.Volume)\n- [0.16.10](/php/docs/reference/cloud-batch/0.16.10/V1.Volume)\n- [0.15.0](/php/docs/reference/cloud-batch/0.15.0/V1.Volume)\n- [0.14.0](/php/docs/reference/cloud-batch/0.14.0/V1.Volume)\n- [0.13.1](/php/docs/reference/cloud-batch/0.13.1/V1.Volume)\n- [0.12.1](/php/docs/reference/cloud-batch/0.12.1/V1.Volume)\n- [0.11.3](/php/docs/reference/cloud-batch/0.11.3/V1.Volume)\n- [0.10.0](/php/docs/reference/cloud-batch/0.10.0/V1.Volume)\n- [0.9.0](/php/docs/reference/cloud-batch/0.9.0/V1.Volume)\n- [0.8.0](/php/docs/reference/cloud-batch/0.8.0/V1.Volume)\n- [0.7.0](/php/docs/reference/cloud-batch/0.7.0/V1.Volume)\n- [0.6.0](/php/docs/reference/cloud-batch/0.6.0/V1.Volume)\n- [0.5.2](/php/docs/reference/cloud-batch/0.5.2/V1.Volume)\n- [0.4.0](/php/docs/reference/cloud-batch/0.4.0/V1.Volume)\n- [0.3.0](/php/docs/reference/cloud-batch/0.3.0/V1.Volume)\n- [0.2.2](/php/docs/reference/cloud-batch/0.2.2/V1.Volume) \nReference documentation and code samples for the Google Cloud Batch V1 Client class Volume.\n\nVolume describes a volume and parameters for it to be mounted to a VM.\n\nGenerated from protobuf message `google.cloud.batch.v1.Volume`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ Batch \\\\ V1\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getNfs\n\nA Network File System (NFS) volume. For example, a\nFilestore file share.\n\n### hasNfs\n\n### setNfs\n\nA Network File System (NFS) volume. For example, a\nFilestore file share.\n\n### getGcs\n\nA Google Cloud Storage (GCS) volume.\n\n### hasGcs\n\n### setGcs\n\nA Google Cloud Storage (GCS) volume.\n\n### getDeviceName\n\nDevice name of an attached disk volume, which should align with a\ndevice_name specified by\njob.allocation_policy.instances\\[0\\].policy.disks\\[i\\].device_name or\ndefined by the given instance template in\njob.allocation_policy.instances\\[0\\].instance_template.\n\n### hasDeviceName\n\n### setDeviceName\n\nDevice name of an attached disk volume, which should align with a\ndevice_name specified by\njob.allocation_policy.instances\\[0\\].policy.disks\\[i\\].device_name or\ndefined by the given instance template in\njob.allocation_policy.instances\\[0\\].instance_template.\n\n### getMountPath\n\nThe mount path for the volume, e.g. /mnt/disks/share.\n\n### setMountPath\n\nThe mount path for the volume, e.g. /mnt/disks/share.\n\n### getMountOptions\n\nMount options vary based on the type of storage volume:\n\n- For a Cloud Storage bucket, all the mount options provided\n by\n the [`gcsfuse` tool](https://cloud.google.com/storage/docs/gcsfuse-cli)\n are supported.\n\n- For an existing persistent disk, all mount options provided by the\n [`mount` command](https://man7.org/linux/man-pages/man8/mount.8.html)\n except writing are supported. This is due to restrictions of\n [multi-writer\n mode](https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms).\n\n- For any other disk or a Network File System (NFS), all the mount options provided by the `mount` command are supported.\n\n### setMountOptions\n\nMount options vary based on the type of storage volume:\n\n- For a Cloud Storage bucket, all the mount options provided\n by\n the [`gcsfuse` tool](https://cloud.google.com/storage/docs/gcsfuse-cli)\n are supported.\n\n- For an existing persistent disk, all mount options provided by the\n [`mount` command](https://man7.org/linux/man-pages/man8/mount.8.html)\n except writing are supported. This is due to restrictions of\n [multi-writer\n mode](https://cloud.google.com/compute/docs/disks/sharing-disks-between-vms).\n\n- For any other disk or a Network File System (NFS), all the mount options provided by the `mount` command are supported.\n\n### getSource"]]