Collection of data warehouses in the Script of commissioning

Hi all

First of all, I want to say thank you for all the help provided in these communities.  It has been very valuable in recent years.

I had the opportunity to work on a configuration script treated for over a week now and have got almost ready for release but got stuck on the type of a basic element - collection of data warehouses.

The idea is that we can use this to launch several environments identical demand - ripe for automation!

We get the number of machines required is in $clcount, and $dslist can be equal to something like this...

NameFreeSpaceGBCapacityGB
SAN-ds-33,399.115,119.75
SAN-ds-41,275.265,119.75
SAN-ds-2661.8135,119.75
SAN-ds-5292.3425,119.75
SAN-ds-8273.2045,119.75

My method works as long as the number of machines is less than the number of available data warehouses, but fails if the number of machines exceeds available data warehouses.

$resources = Get-Cluster "Compute 1"
$OSSpec = Get-OSCustomizationSpec "Base 2012 R2"
$dslist = get-datastore | where {$_.Name -match "SAN" -and $_.FreeSpaceGB -gt 200} | Sort FreeSpaceGB -Descending
$folder = Get-Folder "Lab 2"
$clcount = "17"
$envn = "Lab2-"
$OSSpec = $OSSpec | New-OSCustomizationSpec -Name Temp-Spec -Type NonPersistent -Confirm:$false
foreach ($num in 1..$clcount){
    $suffix = "{0:D2}" -f $num
    $datastore = $dslist[$num-1]
    $OSSpec = $OSSpec | Set-OSCustomizationSpec -NamingScheme fixed -NamingPrefix "APPCL$suffix"
    New-VM -Name $envn"APPCL"$suffix -Template $template -OSCustomizationSpec $OSSpec -Location $folder -ResourcePool $resources -Datastore $datastore
}
##End build Client Machines
$OSSpec | Remove-OSCustomizationSpec -Confirm:$false

I know it would be easy to solve with the clusters and SDR data store, but I believe that would always choose the store of data with the most free space and you can see our environment could be a little unbalanced, so I am trying to build in a little more intelligence in the distribution of these machines in data warehouses.

Any help or pointers in the right direction would be greatly appreciated!

Use % (remainder of division) to transform $num into something that will be less than the size of option:

$datastore = $dslist [$num % $dslist.count]

Then change the ascending sort.

Tags: VMware

Similar Questions

  • Cannot see reverse data warehouses in the model

    Hi all

    I am trying to reverse both PeopleSoft custom defined in an Oracle database tables and bring them to ODI.
    However, even if the reversal of the process itself (standard and custom) doesn't give any errors, I can't see the data stores in the model.

    I connect to the Oracle database using a user id that is not sysadm. This user had only read access to the two tables and sys.dba_objects (initially, while doing a reversal on measure, it was an error which I understand that sys.dba_objects need to access) above.
    I am able to query and read data from tables using sql developer using this new user.

    I believe also that the topology has been set up properly and I could do a ping of the database by using the user successfully when you set the physical schema.

    Advice as to why I can't see data warehouses in the model even after the overwhelming success?
    Help any will be appreciated.

    Thanks in advance,
    Vivek

    Yes,

    The latter request must show any xxxx of the user table, and he did not.

    Take a look if the objects you need to reverse are not synonymous. If that's true, if they are public or private and the true owner of the table referenced by the synonym...

    Cezar Santos
    http://odiexperts.com

  • PowerCLI script for DatastoreCluster, data warehouses and the size info, DataCenter, Clusters

    Hello - I am looking to remove the DatastoreClusters and then list data warehouses as well with their size (total size, used space, free space, put in service, uncommitted space) and the total number of virtual machines on this data store. I would also like to understand what data center and they are on clusters. Is this possible? I might want to limit what is displayed in data warehouses that are 13 percent of free space or less.

    Thank you

    LORRI

    Of course, try this way

    Get-Datastore.

    Select @{N = 'Center'; E={$_. Datacenter.Name}},

    @{N = "DSC"; E = {Get-DatastoreCluster - Datastore $_______ |} {{Select - ExpandProperty name}}.

    Name,CapacityGB,@{N='FreespaceGB'; E = {[math]: tour ($_.)} (FreespaceGB, 2)}},

    @{N = "ProvisionedSpaceGB"; E = {}

    [math]: Round (($_.)) ExtensionData.Summary.Capacity - $_. Extensiondata.Summary.FreeSpace + $_. ExtensionData.Summary.Uncommitted)/1GB,2)}}.

    @{N = "UnCommittedGB"; E = {[math]: tour ($_.)} ExtensionData.Summary.Uncommitted/1GB,2)}}.

    @{N = "VM"; E={$_. ExtensionData.VM.Count}} |

    Export Csv report.csv - NoTypeInformation - UseCulture

  • Creation of Data Type when the script crashes LabVIEW

    When you use the script (LV2010) if I call the Create method of Data Type (available appeal node when a reference to the BD is cable), if I have all but 1 up to the wiring on 'style' terminal, LabVIEW, it blocks. LabVIEW then restarts with an error message saying that "the last time that you have run LabVIEW internal error or accident took place in lvmain.cpp, line 1756. If I have wiring 1 However, it creates a constant fine.

    I see in the context-sensitive help that it always creates a control at the start, but it seems that I can't get it to create a constant. So, okay, I decided to go around, create the constant, take the new object refnum he returned and there to change the constant in one control... but I can't get this work. Can someone point me in the right direction? Here is the code and the screenshot; This is a quick drop plugin.

    It is intended to run on a cluster that is perceived as an icon if you want to test, you need to create that.

    I presented the 'style' value, 0 if if you don't want to plant LabVIEW, set it up to 1.

    No time for an in-depth exploration now.  Create from Datatype killed my LV10.  What I was able to do after creating a constant of cluster, the consultation as an icon and select it.  (1) with the scripts, create a new VI and stick that the constant to figure (2) mount the pasted objected to the ClusterConstant and the change of control.

    I think I know where you're going, should be interesting.

  • Storage vmotion, between data warehouses when the block size is different

    Hi all

    I would like to know, is it possible to do a vmotion of storage between two data warehouses, when they have different block sizes. The case is as a former vmfs data store 3 which has been upgraded direct to vmfs5 there, but since it has been updated it maintains its own block size. While the newly created vmfs datastore 5 a block size of 1 MB.

    Thus, storage Vmotion will work in this case? It will fail OR will be with degraded performance?

    Finally, storage vmotion is possible even if you do not have a cluster DRS for storage?

    Thank you

    Yes you can!

    Check some info on the effects of block size: http://www.yellow-bricks.com/2011/02/18/blocksize-impact/

  • Can you pass offline virtual machines between data warehouses using the 'Migration' with the basic Kit Essentials feature?

    I speak not of Essentials Plus vMotion between hosts or migration of VMS between hosts and data warehouses online. Just curious to know if its possible to off a virtual machine and click the button to migrate to another store of data with the basic Essentials bundle.

    Welcome to the community - Yes you can - it's what we call a cold migration.

  • Access error of data while running the script in the script fdm workbench Editor

    Hello Experts,

    I get the error when I run the script in the script of fdqm established client.this editor is the error

    -2147467259 data access error and he navigates the error on line 30 on this script «Set rsAppend = DW.» DataAccess.farsTable (strWorkTableName).

    Please return me asap where I should charge peoplesoft data to one of my database of planning through fdm.

    Thanks in advance...

    You will need to build a script for integration that is an import Script that allows you to import data from SQL in FDM.

    When you create your import format, you will need to configure it with the file Type = Script and then assign the script of integration as an Expression. Assign your import format to the location that you use to import data.

    Then you can test it by going to the import stage and clicking the import button. FDM will run the integration script and data import by running the SQL query that you have defined.

    To the contrary, "Data Pump" import Scripts are used as import expressions in the import formats

    You can run a script to integrate the customer that this script requires input parameters that are passed only when then FDM import step is executed. If you want to see the raised error open the errorlog FDM. You will only be able to run this Workbench script when you want to debug data is being extracted, but in this case, you will need to comment code that inserts the data in the table. Don't forget that the work table is a temporary table that is created when you click on the import button and if you run Workbench this table does not exist

  • The list of virtual machines, data warehouses and the folder name by cluster


    Hello!!  I hope someone can help me with a PowerCLI script that can pull the info from the object into a file, txt or csv.  In order to get our environment cleaned before our next year Dr. with MRS, I want a list showing each VM and the data store (s) in that it is the name of the folder in the virtual computers view and models.  We keep our VMs organized by creating folder names that correspond to the application running on the virtual machine.  I mention a SRM than last year because our protected groups matched groups of our table of 3PAR Rcopy.  However, we have added over 200 new virtual machines from this era and the members of my team essentially placed these new virtual machines on the first available data store that had enough free space.  Unfortunately, we are not using storage profiles... it's scheduled for next year.

    Information extracted would look like the following:

    ServerName Datastore folder name

    Server1 LUN0 ActiveDirectory

    Server2 LUN0 ActiveDirectory

    Serveur3 LUN1 ActiveDirectory

    Server4 LUN3 Argo

    Server5 LUN7 Argo

    LUN6 Lockbox Server6

    LUN5 Lockbox Server7

    Serveur8 LUN9 Citrix

    etc...

    Any help with the extraction of this info from vCenter would be greatly appreciated.

    Thank you

    Charles

    You can redirect the results to a CSV file, for example

    Get-VM |Select Name,@{N="Datastore";E={[string]::Join(',',(Get-Datastore -Id $_.DatastoreIdList | Select -ExpandProperty Name))}},@{N="Folder";E={$_.Folder.Name}} |Export-Csv C:\report.csv -NoTypeInformation -UseCulture
    
  • data and loading the script sale scheme

    Hello
    I'm learning OBIEE on mine. I managed to install oracle XE and OBIEE 10 g. I need a script to create a new db schema and load the dirty tables with sample data to create reports. can someone help me with scripts?

    Yes, I confirmed that only one Enterprise for Oracle Db edition has the SH schema enabled during installation... you can't have the SH schema without this feature which is ONLY on the Enterprise Edition.

    Here is the article: http://www.dba-oracle.com/t_callan_schema_bye_scott.htm

    Please install the full Enterprise edition and select the SEED DB on install. You will have the sh schema

    If it was OK, please mark as correct.

  • Movement of data warehouses from the local storage to SAN virtual computer

    Hello

    I have a few VMs that must be moved on our SAN, they are on an ESX 3.5 stand-alone server.

    It seems that the best way to proceed would be to:

    1. turn off the VMs system.

    2. copy and paste all of their files on the SAN data store configuration.

    3. right click on the vmx files, add them to the ESX cluster.

    4. create a new ID when asked.

    5. turn on them and let it run.

    Am I missing tips here? In this way, I still have the original VMs back if something breaks down - they will have a new ID created and if all goes wrong, I can just stop them and the power on the 'old'.

    Any help/advice appreciated as (as always) here are important to keep servers to work correctly!

    rudybrewster wrote:

    Thnaks for the answers, I'll flat some points a bit.

    The reason why I want to do with a copy/paste is to keep the original files intact, if I vMotion them, I won't have the originals are I'm going?

    Stand alone ESX server is a different model, etc. to the cluster, so I don't think I can add in?

    Bascially, I need to be 100% sure that I can get these servers if something happens on copy - and I have thin, that my method is what?

    Yes, when you svMotion them, you can move them.

    You can add any model of a server to a cluster. What might not work is vMotion one guest from one host to another if the CPU do not match.

    If you want to keep the original files, copy them.

    AWo

  • esxi data warehouses sees the other?

    Can I mount a remote esxi data store as a NFS mount in another instance of esxi?

    Looks like it should be possible, but not succeed all the time tho not having does not much luck connect to MS Win with NFS/Unix Service no more.

    Would it not simple?

    No, this is not possible - ESXi is not natively support NFS it can connect to another server that shares a NFS by NAS - what you is to create a virtual machine and have this share out NFS by NAS storage.

    If you find this or any other answer useful please consider awarding points marking the answer correct or useful

  • Lightroom 5 - Date edition of the Smart Collections, the time is missing!

    In Lightroom 5 what happened to the option 'hour' in smart Collections edition date "is in the last" _ hours, days, weeks, months, years?

    See this thread, especially Adobe Benjamin Warde employee positions:

    http://feedback.Photoshop.com/photoshop_family/topics/_capture_date_is_in_the_last_n_hours _doesnt_work

  • E.M.P. 11.1.2 Essbase data warehouse Infrastructure

    Hello

    We'll implement Hyperion Planning 11.1.2 and we intend having the data warehouse, pushing the budget data for Hyperion Planning and have push Hyperion and retrieve data in Essbase.  It is, has she a sense also push and pull data from essbase in the data warehouse? To make it more clear, we take the budget data from the data warehouse, and he will push to Hyperion Planning.  Budgetary data provided will be also pushed Essbase data warehouse.  Hyperion Planning will then do the what if analysis and then push back to essbase with essbase here will push the hypothetical scenarios back to the manipulated data warehouse.

    Please let me know if the script need for clarification.

    Thank you

    I did something similar in the past the concept is perfectly feasible.

    See you soon

    John

    http://John-Goodwin.blogspot.com/

  • Integration Hub - Eloqua of marketing data warehouse need?

    We believe that in the heart of Eloqua real company, it is often necessary to embrace existing platforms and architecture, there is great need for marketing middleware, meeting between IT and Marketing systems.

    Thus, we have developed the integration Marketing CleverTouch Hub, allowing users of Eloqua dynamically integrate their data warehouse and the existing COMPUTER infrastructure.

    Is there a requirement for such a product, providing business space?

    To date, we were delighted with enthusiasm of Eloqua and support, the company real thought, but we would like to get comments from the end-user and community partners also.

    http://bit.LY/gfbEiI

    YES!  Something is needed to fill this gap in enterprise-class reports.  Please tell us more.

  • Removal of host SDR data warehouses

    Hello

    I have a scenario where I want to migrate to a host and the VM between two clusters. I unfortunately had a number of DTS data warehouses attached to the host, no virtual machine is running from these storages of data on this host... I'm trying to disassemble stores but as expected get the error indicating that data warehouses are part of a cluster of EIM.

    Is it possible to no disturbance delete Host data warehouses.

    Thank you

    Steve

    So, what you want, remove some cluster DTS data warehouses and pass a host of a DRS cluster to another's is?

    Try the following steps:

    (1) remove the DTS cluster data warehouses, just move the data store outside the cluster for DTS;

    (2) move the host to the new DRS cluster target, if you have virtual machines running on it and cannot put the host in maintenance mode, you will need disconnect host, remove from the inventory and then add the host again to the new cluster.

    (3) If you wish, add data warehouses to the DTS of the new DRS cluster cluster.

Maybe you are looking for

  • How can I activate my apple ID

    I can't download any app, because I get an error message saying that my "Apple ID has been disabled.

  • How can I change the clock on my iPhone ringtone 5 for revival

    I want to change the ringtone for the alarm but could not find the option anywhere. When I put my iPhone to the top of the alarm was the same as my ring tone incoming, but given that the setting has been postponed until the factory setting, I have a

  • BlackBerry calendar Z10 Z10 - can you change the default settings?

    I wish that my calendar by default with no reminder entries, is possible to change this setting?

  • PIN BB message

    Hi all I want to access BB PIN Message and send the message through my aplication. How can we achieve this? Your suggestion will be a great help for me. Best regards! Thank you...

  • VPN Site-to RV180W

    Hello I have a basic question of VPN I need to connect 3 sites. Site from A to B Site A-C Of the site: 10.1.42.0/24 Site B: 10.1.43.0/24 Site C: 10.1.44.0/24 Can site B computers contact on site C? What I need to set up a VPN between B and C, or if i