Add a new disk to an existing Linode. You can create an empty disk to manually configure it later. You can also target a stored image
to build the disk using a pre-configured file system.
-
A Linode can have up to 50 disks.
-
When creating an empty disk, you need to provide a
label
for it. If you don't include alabel
, you need to target animage
instead. -
When you create a disk from an
image
, you need to set aroot_pass
for the disk. -
The default file system for a new disk is
ext4
. If you're creating one from animage
, the disk inherits the file system of thatimage
, is unless you specify otherwise. -
When you deploy a StackScript on a disk:
-
You can run List StackScripts to review available StackScripts.
-
You need to include a compatible
image
when creating the disk. Run Get a StackScript to review compatible images. -
You should supply SSH keys for the disk's root user, using the
authorized_keys
field. -
You can include individual users via the
authorized_users
field. Before you can add a user, it needs an SSH key assigned to its profile. See Add an SSH key for more information.
-
linode-cli linodes disk-create 123 \
--size 1300 \
--authorized_keys "ssh-rsa AAAA_valid_public_ssh_key_123456785== user@their-computer" \
--authorized_users "myUser" \
--authorized_users "secondaryUser" \
--root_pass aComplex@Password \
--image "linode/debian9" \
--stackscript_id 10079 \
--stackscript_data '{"gh_username": "linode"}'
<https://techdocs.akamai.com/cloud-computing/docs/getting-started-with-the-linode-cli>
linodes:read_write
<https://techdocs.akamai.com/linode-api/reference/get-started#oauth>