VMware Cloud Community
ii00907
Contributor
Contributor
Jump to solution

Add and remove new hd, rdmp with command line

Goodmorning,

i have a problem,

I know how to create a vmdk or Rdm but I do not know

if 'can hook these new devices from the command line without the Power off - on

the VM's

The command vmware-cmd and vmkftools There isn't info about this.

Very thanks

Ivan Venga

Reply
0 Kudos
1 Solution

Accepted Solutions
dmn0211
Enthusiast
Enthusiast
Jump to solution

It can be on any windows box. It is a toolkit for both ESX hosts and Virutal Center functions.

http://www.vmware.com/beta/vitk_win/

Overview

The VMware Infrastructure (VI) Toolkit (for Windows) 1.0 includes more than 120 cmdlets, a set of sample scripts, and a function library that make managing and automating the VMware Infrastructure easier than ever before.

The VI Toolkit (for Windows) is a command-line and scripting tool based on PowerShell that provides useful functionality for virtual infrastructure management.

Usage

The first thing you need to do after launching the VI Toolkit (for Windows) is to get a connection to a VirtualCenter or ESX server. To get started, call the Connect-VIServer cmdlet and specify the IP address or DNS name of your VirtualCenter or ESX server, the protocol (http or https), user name, and password.

Connect-VIServer -Server 10.22.36.36 -protocol https -user admin -password mypass

View solution in original post

Reply
0 Kudos
7 Replies
dmn0211
Enthusiast
Enthusiast
Jump to solution

Check out this script. I believe it has the function. This is for the VI-ToolKit.

*New-HardDisk -VM $vm -DiskType rawPhysical -DeviceName $lun.DeviceName | Out-File -Append "RDMMapper.txt"*

http://communities.vmware.com/docs/DOC-7951

Reply
0 Kudos
ii00907
Contributor
Contributor
Jump to solution

Thanks,

This tool must be installed on the server virtual center or on any car windows?

Also manages the Linux virtual machines?

Thanks a lot to give this info.

By

Reply
0 Kudos
dmn0211
Enthusiast
Enthusiast
Jump to solution

It can be on any windows box. It is a toolkit for both ESX hosts and Virutal Center functions.

http://www.vmware.com/beta/vitk_win/

Overview

The VMware Infrastructure (VI) Toolkit (for Windows) 1.0 includes more than 120 cmdlets, a set of sample scripts, and a function library that make managing and automating the VMware Infrastructure easier than ever before.

The VI Toolkit (for Windows) is a command-line and scripting tool based on PowerShell that provides useful functionality for virtual infrastructure management.

Usage

The first thing you need to do after launching the VI Toolkit (for Windows) is to get a connection to a VirtualCenter or ESX server. To get started, call the Connect-VIServer cmdlet and specify the IP address or DNS name of your VirtualCenter or ESX server, the protocol (http or https), user name, and password.

Connect-VIServer -Server 10.22.36.36 -protocol https -user admin -password mypass

Reply
0 Kudos
ii00907
Contributor
Contributor
Jump to solution

Ok, very thanks,

but is not possible with command line to esx host?

Reply
0 Kudos
dmn0211
Enthusiast
Enthusiast
Jump to solution

You may be able to use vmware-vim-cmd vmsvc/device.diskadd. You will need the vmid, you can get that with vm-support -x.

Reply
0 Kudos
ii00907
Contributor
Contributor
Jump to solution

Ok,

but when i run this command , i have this info

# vmware-vim-cmd vmsvc/device.diskadd 32

Insufficient arguments.

Usage: device.diskadd vmid size controller number unit number datastore

when 32 is the vmid the VM but size controller number unit number datastore ?

do you write a example for me?

Very thanks

Reply
0 Kudos
dingding
Enthusiast
Enthusiast
Jump to solution

please refer to KB http://kb.vmware.com/kb/1006685

---- Idleness is not doing nothing. Idleness is being free to do anything.
Reply
0 Kudos