Names of directory data store

Hello

Sorry for the N00b question, but I can't find an answer anywhere.

I noticed that on my data stores, there are often multiple directories for the same customer. For example, if there is a guest named 'foo', there will be a directory "foo". But sometimes there will also be a directory named "foo_1".

Whence the _1, < name >?  That is generated?

TIA,

T

with the _1 means that the virtual machine has generally more than 1 HDD presented to her.

But, in your case, by referring to the names of directories _1, it probably means that there are names that are duplicated in the data store.  A folder will be created when you create the virtual machine. The folder represents the object name of VMs.

So, if I have a virtual machine named VM1, on the data store must be a VM1 folder with all the files associated with this virtual machine (.vmx, hard, etc.)

If I create another virtual machine called VM1 and the content of the store data don't have not removed correctly a previous virtual computer that may have been moved, destroyed, removed from inventory, etc., there will be a VM1_1 folder with the associated files.  Have your records _1 files inside of them?

You can also look something like RVTools.  It will help you find virtual machines that can be stunned. Check the Tab Vsante

Tags: VMware

Similar Questions

  • Machine virtual IOPS / s report, how to display the name of the data store?

    Hi guys

    I am new to the Foglight community, this is a great tool, and I learn a lot.

    Currently I am trying to create a simple table that will show me metric of my VMware environment: Virtual Machine name, Datastore IOPS and data store.

    However I can't find how to include data store name in the table, because it is not a measure of the Virtual Machine. I think I need to expand the scope of my table to include VMware Datastore, but I don't know how to do this.

    -Mark

    Check the options available it seems that it can be done with WCF (the frame behind the Foglight dashboards).  We recommend generally customers who plan to build views WCF take adequate training or our PSO people engaged in it.

    In any case I can help show a quick example of how it's done.

    Please try this on a local/test server.

    Go to Configuration > definition >

    Make sure that you are in my definition, and click the icon to add a view. then choose from the tables and trees - oriented line table

    Give a name to the view, go public and make a portlet/reportlet and apply

    Switch to the configuration tab and click the change for the lines and choose a query

    Under query, expand the VMware and scroll down

    Until you can select the query for virtual machines

    And press the set button.

    Your view should look like this

    Now you must select the columns.

    Each column has a value you can edit and there is a button + to add additional columns.

    Lets start with the name of the virtual machine - click on the button to change to your default column and choose the context.

    Click on the drop down menu to enter key and choose the current line (virtual vmware machine)

    Click on the drop down menu to access path and scroll down until you can select the name and then click on set.

    You have created a table that lists the names of all virtual machines.

    You can click on save. and then click test, choose a time and click the result. A new window will open a show the list you of virtual machines.
    From here you can continue to add additional columns, each time choosing the key entry in the current line and the path to the metric/string to display.

    For example, the name of the data store.
    I change the module

    Click the configuration tab and click the icon to add a column

    For the column value, that I chose defined context once again, the key input is the current row and for the path, I expand the node for the data store

    And scroll until I see the Proprietename

    If you save and test you will see the result

    Keep adding columns and the data you want, notice that you have arrows that allow you to control the order of the columns.

    Note that you can click Show advanced configuration properties

    This will give you the opportunity to see the properties of the extra table, such as header - giving you the opportunity to give a more meaningful name (name of the data store, the name of the virtual machine, etc.) to the column header.

    You can now go you drag and drop the table edge/report and under my eyes, you will see your new view

    Drop it in the main view

    I hope this has given you the starting point to build this table.

    As I said, I strongly recommend going through our WCF training if you plan build more custom views or hire software Dell PSO Organisation to help build you views that correspond to your need.

    Best regards

    Golan

  • Change the name of a data store?

    Hello

    Is it possible to change the display name of a data store NFS I have 8 nodes in a cluster connected to?  This is for aesthetic reasons only - consistency of the naming convention.  Just curious, if I renamed the store of data for data store in vSphere VCenter, did change the display name for each host?  Or I have to change the display name to each host using the "hosts and Clusters".  Just curious to know if I can do that, while virtual machines are run with no negative effect... or should I stop literally all of the virtual machines to do this.

    Thanks in advance.

    Hello

    You can change the name of data warehouses (NFS, iSCSI, FC etc.) at any time and without any negative effects.

    Just right click, rename it to your heart's content!

    See you soon,.

  • How to set vm-description/notes and get the name of the data store, where the virtual machine

    Hello guys,.
    I have vCenter Orchestrator 4.1.1 build 733 installed and it works fine, but I need your help for the following two issues:
    (1) I want to put the description/notes of a virtual machine using a workflow. But I have not found any API useful to create this workflow (I don't want custom attributes, see attachment for details).

    (2) how can I get the name of the data store, where the virtual machine? I need this name for a workflow.
    I need your help.
    Thanks in advance!

    With regard to the notes of the VM, the following code (see enclosed package) can do this:

    var oldNotes = vm.summary.config.annotation;
    If (oldNotes == null) {oldNotes = ' ' ;}}
    System.log ("Notes of VM current:" + oldNotes);
    Now put the new notes:
    Start by creating a context
    Context of var = new VcVirtualMachineConfigSpec();
    Update the annotation with the new value property
    configSpec.annotation = notes;
    launch the task to reconfigure the virtual machine with the new context
    NOTE: This is sure to apply with a virtual machine under tension
    var task = vm.reconfigVM_Task (configSpec);

    And, in what concerns the VM information, take a look at the workflow of the library: \Library\vCenter\Virtual Machine management\Others\Extract virtual machine information

  • Change of name of the data store?

    Hi, I would like to know, what's going to happen, if I rename my data store?

    I have the VDI and the production of other virtual machines in my environment.

    Thank you

    We renamed 32 stores data shared in our environment vSphere4 some weeks ago, with no problems at all.  Everything you do changes the name of the object, it has no effect on how the ESX hosts see LUNS.

  • You can change the name of a data store that has active VM on it?

    We have a number of logical units shared through our table CX700 SAN ESX4.  Each lun has a unique about this data store.  In vCenter, if I rename one of the data stores that have active virtual machines on it, it will break anything?

    Mike O.

    Hello.

    You can rename them at any time.  These names are 'friendly names' only.

    Good luck!

  • Help with report VM (name MemoryMB NumCPU, data store, total size of the disk)

    I currently have a script (listed below) to the CR of query for each virtual computer and their allocated disks. The problem with the script is that when he meets a VM with disks on several data only stores the first data store is listed in the report. However, the total size of the disk is correct.

    Any ideas to fix this?

    $datastoreExp = @{N = "Datastore"; E = {($_ | get-datastore | select-object-1 premier).} Name}}

    $diskSizeExp = @{N = "Total disk"; E = {($_ | get-harddisk | mesure-objet-propriété CapacityKB-somme).} Sum}}

    Get - vm | Select the name MemoryMB NUmCPU, $datastoreExp, $diskSizeExp | Sort - property datastore, "Total disc | Export-Csv C:\Scripts\Reports\chargeback.csv

    I thought that was what you wanted, judging by your examples.

    In any case, no problem, the following should do the trick.

    
    $dsRegEx = [regex]"\[(\w+)\]"
    $report = @()
    get-vm | % {
         $vm = $_
        $vm.HardDisks | %{
              $row = "" | Select Name,MemoryMB,NUmCPU, Datastore, "Total Disk (Gb)"
              $row.Name = $vm.Name
              $row.MemoryMb = $vm.MemoryMb
              $row.NumCpu = $vm.NumCpu
              $row.Datastore = $dsRegEx.Match($_.Filename).Groups[1].Value
              $row.{Total Disk (Gb)} = "{0:N}" -f ($_.CapacityKB / 1Mb)
              $report += $row
         }
    }
    $report | sort -property Name, datastore,"Total Disk" |Export-Csv "C:\chargeback.csv" -noTypeInformation
    

    Since there are sometimes problems with the display of the hooks I have attached the script.

  • How to retrieve the name of the data store

    I need to install omsa for esxi 5 I execute the command esxcli.exe - server x.x.x.x software vib install d 'path to the file on the data store. I downloaded the zip file in the store of data and now need to install it. How do I know what the path, so I can finish my order vcli?

    thnx gym, my bad.

  • Name of device for the data store list

    Need help with this simple script

    $datastores = get-Datastore-location "CXXV. Where-Object {$_.ExtensionData.Info.GetType ().} Name - eq "VmfsDatastoreInfo"}

    $myColCurrent = @)

    ForEach ($store in $datastores)

    {

    $myObj = "" | Select-Object Name, devicename

    $myObj.Name = $store.name

    Write-Host $myObj.Name

    $myObj.devicename = $store.ExtensionData.Info.Vmfs.Extent.DiskName

    Write-Host $myObj.devicename

    the name of the data store is writtenl properly but the devicename is empty and get this warning:

    WARNING: The 'Accessible' type of data store property is obsolete. Use the property 'State '.

    Strange thing is that the Script works lab powercli linking the vCenter lab. But gives the error in the production powecli server to vcenter prod.  powercli and vcenter server versions are the same.

    Help is greatly appreciated

    The extended property is an array.

    Try to change this line

    $myObj.devicename = $store.ExtensionData.Info.Vmfs.Extent.DiskName

    in this

    $myObj.devicename = [string]: join (",",($store.ExtensionData.Info.Vmfs.Extent |) %{$_. DiskName}))

    You can safely ignore the warning messages, or may disable them with the Set-PowerCLIConfiguration cmdlet and the DisplayDeprecationWarnings switch.

  • Fill the CSV file with the host name and the name of data store

    Hello

    How can include the hostname in my output csv file?

    The following code adds the name of the data store but not the host name:

    import-csv hosts | % {get-vmhost-name $_.name} | Get-Datastore. SELECT name.

    Export-csv ESX - Datastore.csv - notypeinformation - useculture

    How to watch your entry CSV file?

    If it's something like

    Name

    ESX1

    ESX2

    Do it like this

    &{foreach($esx in (Get-VMHost -Name (Import-Csv host.csv -UseCulture | Select -ExpandProperty Name))){    $esx | Get-Datastore |    Select @{N="VMHost";E={$esx.Name}},Name}} | Export-Csv report.csv -NoTypeInformation -UseCulture
    
  • Detach a lun using the data store name?

    All (or Luc lol)

    I am wanting to use the disc to detach function, but instead of passing naa.id, I wish I could pass the name of a data store already disassembled data store to get the id of the naa. I would also like to pass a list of hosts, rather than to all guests who tied it.  I watched Alan functions but its going to each host rather than being able to move from a specific host.

    I took a slap at him earlier, but I'm a little confused on how to do it.

    http://www.lucd.info/2011/11/25/LUN-juggling-in-vSphere-5/

    Any help?

    With a small change to the functions of Alan, you can use a parameter of VMHost.

    In there, you specify one or more ESXi servers where the data store must be dismounted and detached.

  • Name of the data connection with ConsoleDeviceName and CanonicalName store

    Hi people,

    I would like to connect 3 parameters, ConsoleDeviceName, CanonicalName, and 'name of the data store.

    The first two times (ConsoleDeviceName, CanonicalName) can I get with ' Get-VMHost "MyESXHost |" Get-ScsiLun.

    But how can I get the name of the data store?

    http://communities.vmware.com/servlet/JiveServlet/downloadImage/7964/12-9-2009+1-11-11+PM.png

    Thanks for help

    Hello

    In order to get the name of the data store for each unit number logical you should review the information of measurement of the disk for each data store attached to the host and link them using canonical names of lun. VMFS datastore disk measurement information are available in the HostScsiDiskPartition object. Here's a code example how to do this:

    $h = Get-VMhost "MyESXHost"
    
    # collect VMFS datastore name and extent cannonical names into a hashtable
    $dsLunList = @{}
    $dsView = $h | Get-Datastore | ? {$_.Type -eq "VMFS"} | Get-View
    foreach ($ds in $dsView) {
         foreach ($diskExtent in $ds.Info.Vmfs.Extent) {
              $dsLunList[http://$diskExtent.DiskName|http://$diskExtent.DiskName] = $ds.Info.Name
         }
    } 
    
    #populate datastore name for each lun if available
    $lunList = @()
    $h | Get-ScsiLun | % {
         $lun = "" | select ConsoleDeviceName, CanonicalName, DatastoreName
         $lun.ConsoleDeviceName = $_.ConsoleDeviceName
         $lun.CanonicalName = $_.CanonicalName
    
         if ($dsLunList.ContainsKey($_.CanonicalName)) {
              $lun.DatastoreName = $dsLunList[http://$_.CanonicalName|http://$_.CanonicalName]
         }
    
         $lunList += $lun
    }
    
    $lunList
    

    Kind regards

    Yasen

  • List of virtual machines in the data store that is not in stock

    Hi guys

    PowerCLI rookie here, sorry for the stupid questions.

    I'm trying to clean up a bunch of singehost with local data warehouses. So I need a script that can display a list of files of virtual machine on a data store that is not used by VMs in the inventory. One of the problems is that the files on the data store, isn't every means, named exactly the same as the virtual machine in the inventory.

    Summer watching this, but I think the term "orphan" is "sent, in my view, it is:

    https://communities.VMware.com/thread/266913

    Also it is - this one, I think that I should be able to change it to do what I want:

    http://www.wooditwork.com/2011/08/11/adding-VMX-files-to-vCenter-inventory-with-PowerCLI-gets-even-easier/

    Any tips or hints to push me in the right direction would be appreciated.

    Please try:

    $AllFilesLocalDatastore = get-data store 'localdatastorename ' | Get-fileindatastore

    $FilesIdentifiedAsAssociatedToAllVMs = get-FilesIdentifiedAsAssociatedToAllVMs

    #The two functions above are available here http://thecrazyconsultant.com/find-orphaned-vmdk-files-workflow/

    Check the contents of the two variables for example with VGO or export-csv

    $AllFilesInESX01LocalDatastore | OGV

    Try:

    $FilesNotIdentifiedAsAssociatedToAnyVM = $AllFilesLocalDatastore | {foreach-object

    $FullPath = $_. FullPath

    If ($FilesIdentifiedAsAssociatedToAllVMs.FileName - notcontains $FullPath) {}

    Return $_

    }

    }

    $FilesNotIdentifiedAsAssociatedToAnyVM | OGV

    #The over a will contain all the files that are not identified as associated with any virtual computer

    $ProbablyOrphanedFiles = $FilesNotIdentifiedAsAssociatedToAnyVM | where {$_.} FileTypeFullName-match "VMware.Vim.Vm *"-GOLD ($_.) FileTypeFullName - eq "VMware.Vim.FileInfo" - AND ($_.) FullPath-match ".vmsd" - or $_. FullPath-match ".vmxf" - or $_. FullPath-match "aux.xml" - or $_. FullPath-match ".vswp" - GOLD ($_.) FullPath-match "hard" - AND $_. FullPath - notmatch 'ctk.vmdk') - GOLD ($_.) FullPath-match ".vmx" - AND $_. FullPath - notmatch ".vmx ~"- AND $_. FullPath - notmatch "." VMX.lck")))}

    $ProbablyOrphanedFiles | OGV

    Edit:

    Changed the name of the data store, it seems that he was not supposed to be in the first screenshot.

    Edit2:
    The first command control switch, more details in the last post in this thread

  • Bay of Cluster data store turns into a string?

    I am very new to the vCO (or maybe I should call vRO now) and therefor also very new to script and digging through the API, so I apologize if this is a bit of a noob question.

    I'm currently running below script to find the data store cluster to a cluster host with more available space.

    However, I also want to check for the text in the name of the data store. For this I use indexOf.

    If indexOf detects all matches, it should add the DSC (or pod) in a table.

    But it seems that this operation turns my array into a string.

    Because it is a new environment I have only a DSC connected to the cluster hosts, but I still think that it should be able to be an array with a single value?

    Find the Cluster and related variables

    var hostarray = System.getModule ("com.vmware.library.vc.cluster") .getAllHostSystemsOfCluster (inCluster);

    Host = hostarray [0];

    pool = inCluster. ResourcePool;

    level of var = 'High';

    Find warehouses of data in Cluster

    var = host.datastore data warehouses;

    Find Clusters of Cluster data store

    var storagePods = new Array();

    var storagePodNames = new Array();

    for (d in data warehouses) {

    if (data [d].parent.vimType warehouses is "StoragePod") {

    if (storagePodNames.indexOf (datastores [d].parent.name) < = - 1). {

    storagePodNames.push (datastores [d].parent.name);

    storagePods.push (datastores [d] .parent);

    }

    }

    }

    System.log (' storagePods: ' + storagePods [0].) Summary.freeSpace);

    Find Clusters corresponding to the layer data store

    var podTierArray = new Array();

    for each {(var pod in storagePods)

         if (pod.name.indexOf (tier) > = 0) {

    podTierArray += pod;

    }

    }

    podTierArray becomes a string instead of table after above operation :(((

    System.log (' podTierArray: ' + podTierArray [0]);

    System .log (' podTierArray: ' + podTierArray);

    Here is the result of the above script:

    [12:24:27.307 2015-02-27] [I] storagePods: 4497773428736

    [12:24:27.308 2015-02-27] [I] podTierArray: D

    [12:24:27.310 2015-02-27] [I] podTierArray: DynamicWrapper (Instance): [VcDatastore]-[class com.vmware.vmo.plugin.vi4.model.VimDatastore] - VALUE: < datastore-386 > Datastore 'high Datastore01 '.


    I'm guessing that "D" is the first character in the string (which should be an array), which is also attested by the third row of the output when I print the entire string.

    Because this time is a string I can't use it as an object, for example "podTierArray. Summary.freeSpace' give me an error that it is a property not set.

    In addition, as you can see earlier when I use the variable ""storagePods "this is a picture I have run the podTierArray. "


    Why would he suddenly become a string instead of an array of objects?

    Hi Oskar,

    It happens because of this line in your code

    podTierArray += pod;
    

    This is not the right way to add the element in a table. You need to take it

    podTierArray.push(pod);
    
  • Data store Clusters does not

    I worked with one of the guys in another thread on get the script below works, but we used a work around on the section of the store of available data in a specific data store instead of a cluster data store.  While it will work on a functional level, it fills a particular DS extension and allow now the DTS select the implementation at deployment time.  Has anyone successfully supplied VMs in a cluster data store and may be able to give an overview on the excerpt below?

    $hshNewVMParams = @ {}

    Model = $strSourceTemplate

    Name = $strNewVMName

    # default pool of resources 'Resources', in order to put the desired cluster virtual machine

    ResourcePool = Get-Cluster $strSomeCluster | Get-ResourcePool-name 'resources '.

    Data store = "8000-10kSP1-LUN02.

    DiskStorageFormat = $strStorageFormat

    Location = Get-file $strDestinationFolder

    OSCustomizationSpec = Get-OSCustomizationSpec-name $strOurCustSpecName

    # Owner = $strVMNotes

    } # end s.a.s..

    # create new virtual machine

    $vmNewOne = new machine Virtuelle-@hshNewVMParams

    # define portgroup NIC and MAC addr

    $vmNewOne | Get-NetworkAdapter | Together-NetworkAdapter NetworkName - $strSomePG - MacAddress $strNewMacAddr - confirm: $False | Owner of the whole Annotation-CustomAttribute-value $strVMOwner

    # Start the virtual machine

    Start-VM - VM $vmNewOne

    Update: after a few tries and a support call with VMware, I could get this to work with a few workaround solutions.

    1. the default action for a cluster of data (without specified DiskFormat) store, is to deploy the same format as the source.  I suspected this, but did not confirm until a few weeks ago.

    2. the VMware SDK engineer recommended running New - VM and specifying the format of disk, then Move-VM to have the DTS to implement its recommendations.

    $csv = "C:\ANT_VMs.csv" of import-Csv - UseCulture | %{

    {foreach ($line in $csv)

    # Connect to a vCenter

    SE connect-VIServer usddrmvctr1

    # Clone VM model

    $oNewVM = new-VM-name $_. Name - model $_. Model - ResourcePool (Get-Cluster $_.) Cluster | Get - ResourcePool - name 'Resources') - DiskStorageFormat $_. DiskFormat

    # Reconfigure VM

    $oNewVM | Get-NetworkAdapter | Together-NetworkAdapter - NetworkName $_. PortGroup-confirm: $false | Together-NetworkAdapter - MacAddress $_. MacAddress - StartConnected: $true - confirm: $false

    # Reconfigure VM

    $oNewVM | Move-VM - Datastore (Get-DatastoreCluster-Name $_.) Data store)

    # Owner of the Annotation set

    $oNewVM | Owner of the whole Annotation-CustomAttribute-value of $_. Owner

    #Power on VM

    Start-VM $oNewVM

    }

    }

Maybe you are looking for

  • unknown credential - VIRTUALAPP/DIDLOGICAL

    I am so excited when I read the post that an answer has been found to find the broken link.  Microsoft, please fix!  We get desparaate here...

  • There is a new virus sent to users of Aol, hotmail and g-mail?

    I received the message from one of my friends emails confidence that a new virus is released, which is sent to the user from Aol, hotmail and g-mail titled "here you have it" by a hacker calling himself (owner of life),. If you open the file, one The

  • Check French option comes out only Outlook Express

    Like others, I have spell check the problem of language selection with OE, version 6.0.2900.5512, of not being able to move from the French to the English.  My OS is XP SP3 and I have Office Home & Student 2007 is installed. None of the suggested cor

  • KEYBOARD PROBLEMS AFTER UPGRADING WINDOWS VISTA

    After update to automatic in windows vista, keyboard on my computer toshiba laptop no longer recognizes Maj characters and produced the capitals only with the caps lock on.  Any ideas on how to solve this problem would be appreciated.

  • Display phones smart blackBerry.

    Before you begin, let me quote that I did, in fact, check other issues unmasking so I wouldn't get this post, but responses has not worked for me. I may accidentally hid some icons. One I noticed is my SMS icon in the menu screen. I tried to hit the