Disk shows up incorrectly in /dev/disk/by-id

337 views
Skip to first unread message

Jonas Galvez

unread,
Jul 22, 2016, 9:31:36 PM7/22/16
to gce-discussion
Before:

ls /dev/disk/by-id
google-persistent-disk-0        scsi-0Google_PersistentDisk_persistent-disk-0
google-persistent-disk-0-part1  scsi-0Google_PersistentDisk_persistent-disk-0-part1

After:

gcloud compute instances attach-disk intersowa-develop --disk intersowa-develop-hdd --zone us-central1-a
ls /dev/disk/by-id
google-persistent-disk-0        google-persistent-disk-1                       scsi-0Google_PersistentDisk_persistent-disk-0-part1
google-persistent-disk-0-part1  scsi-0Google_PersistentDisk_persistent-disk-0  scsi-0Google_PersistentDisk_persistent-disk-1

So it looks like it's being named google-persistent-disk-1. Is this expected?

-- Jonas

Kamran (Google Cloud Support)

unread,
Jul 22, 2016, 11:27:28 PM7/22/16
to gce-discussion

Hello Jonas,

If the device name is not specified in the command, attached additional persistent disk(s) will be named 'google-persistent-disk-n" in the guest operating system, where n is the number of additional disk(s). You can specify the disk name that the guest operating system will see by using --device-name DEVICE_NAME in your command. For more information about gcloud compute instances attach-disk command and its flags please visit this article.

Sincerely,
Reply all
Reply to author
Forward
0 new messages