PowerCLI - customizations on Redhat5, host name not correctly define

Hello

I'm new on using PowerCLI so I can be is silent, so say if I make a stupid mistake.

I want to create a number of machines based on a model; the only thing that will be different is the host name and IP address.

I have a CSV file:

VM, Datastore, VMhost, IP
NWB-vb85sp1rh5x64c1t1, vmfs-vb-s08, NWB - devesx01.microfocus.com, 10.120.70.167

And I'm processing with the following script.

Import-Csv "nwb-vb85sp1rh5x64.csv" | %{
   Get-OSCustomizationSpec VBautomation_VLAN70 | Get-OSCustomizationNicMapping | Set-OSCustomizationNicMapping -IpMode UseStaticIp -IpAddress $_.IP -SubnetMask 255.255.255.0 –DefaultGateway 10.120.70.254
   New-VM -VMhost $_.VMhost -name $_.VM -Template nwb-vb85sp1rh5x64Level3 -Datastore $_.Datastore -OSCustomizationSpec “VBautomation_VLAN70”
}

Once the machine has started, the host name is not NWB-vb85sp1rh5c1t1 but SDO-vb85sp1rh5c1t1-0 (the model, if started would have a host of SDO-vb85sp1rh5templ name, so something that happens).  Is this a known issue?  Someone at - he no idea how I can get the name of the ideal machine?  I have a load of scripts which do various things, based on a host name and change all them that it would be a pain.

Thank you very much.

I suspect that the NamingScheme in your OSCustomizationSpec could be wrong.

You can change this with the Set-OSCustomizationSpec cmdlet.

Tags: VMware

Similar Questions

  • Help with a script. Need to host name, not the FULL domain name

    I'm trying to gather a workflow that will create a user in Active directory and then install SQL server using this account for the service.

    the format of the username I want is SQL_servername

    I use ' hostname = vm.guest.guestId; ' to remove the host name of the virtual machine, but it returns the domain (i.e. servername.domain.name) FULL name

    I tried various methods (rtrim, trim, righttrim, etc.) to remove the domain name to leave me with only the name server, but not appear to work.

    Is there a way of Orchestrator to delete the domain name, or is there another function, I should use to get the short server name.

    Thank you

    server = hostname.substring(0, hostname.indexOf("."));
    
  • host name not fully desplayed for v$ instance

    Hi all

    I am facing a problem of pecuilar with my Oracle 10 g 2 server.
    As I am unable to view the full hostname of the server while the instance of $ v views from database level.
    Please help me with this explaining how do I update the v$ instance view to display the full hostname of the server.

    output below

    SQL > select distinct (HOST_NAME) of v$ instance;

    HOST_NAME
    ----------------------------------------------------------------
    uaedxbpd

    SQL >! hostname
    uaedxbpdctapp02

    DB version: 10 gr 2
    OPERATING SYSTEM: HP - UX

    According to the note * Health Check Alert: host name must be 8 characters or less [957443.1 ID] * + the host name should not be longer than 8 characters length (on HP - UX)... otherwise, it will be truncated.
    This "problem" seems to be fixed at 11 GR 2.

    Nicolas.

  • FTP troubleshooting DWCS5.1: the proxy settings "are not correctly defined.

    Hi all

    I'm unable to ftp with DW. Joined a screengrab of the error message. As always, thanks for your comments.

    Jacqui

    ScreenSnapz004.png

    You have switched your site FTP settings to use SFTP, as FTP connection was put out of service?

  • Cannot bind Gmail to Outlook, receive error: the pop3.gmail of the host could not be found. Please check that you have entered the server name correctly.

    Original title: Link to Outlook g.mail

    I'm loving g.mail at Outlook 03, but I get the following error message: the pop3.gmail of the host could not be found. Please check that you have entered the server name correctly. Pop3g.mail.com, server pop3g.mail.com, Prtotocal pop3, Port 995, SSL server without error Socket 11001, error 0x800CCC0D account No. Can someone help me with this problem?

    Hi Eva,

    Thanks for posting on Microsoft Community. According to your description, it seems that you couldn't configure Gmail on Outlook and you receive error 0x800CCC0F. If I'm not mistaken you have Microsoft Outlook 2003 is installed.

    This happens usually when there are questions about the server. If you have not been able to set up the account successfully, I suggest you read this article that shows how to set up email on Outlook accounts.

    If you have configured the account successfully, but I could not send or receive e-mails, you go through this article which has troubleshooting for this issue.

    If this is not enough, you can replicate with the result, then we can help you solve more.

    Thank you!

  • Problem with Linux Blueprint receives not to HOST name or IP address after provisioning

    We run VCAC 6.x and I have setup a plan for a version of linux RHEL 5. Network profiles have been implemented, as well as some ip address ranges. When I load the action plan the machine does not receive the defined HOST name. The network interface comes up, also has a MAC address, but has no IP address assigned address. When I connect vcac and check stocks of intellectual property, I see that an IP address has been assigned. What I'm missing here?

    You have a configuration specification of customization vCenter and applied to this profile of renewal and construction?

  • try to email photos frm digital camera. Download window saying pop3 host could not be found. VFY server name. don't know the name of the server. If I did where I would use it.

    I am trying to send pictures from the digital camera.  A window pops up saying that the pop3 host is not found.  Check the name of the server.  I don't know name of server and if I did it when I would use.

    1. On your computer the pictures?
    2. What email program are you using?
  • Host name can not enter in the browser

    Hello

    I put my printer hostname to HP8600.   On my PC, I can't enter the host name in the url and the HP Web Interface will go up.   I am unable to do it with my Mac.   I can't get to it with the entry of the intellectual property.   I use Firefox on both browsers.   Do you know what could be the problem?   Thank you.

    David

    It seems strange, but it doesn't look like Mac will allow you to do.  I tested it on my own under 10.8.3 and it would not connect to my 8600 or my other printers using the host name.  It would connect using the IP address only.  It seems that just Macs do not support this feature.  I'm sorry.

  • Availability of the critical apparatus report shows too many bars, not enough host names

    Hello

    The availability of critical devices report includes a graph showing the availability of each server in the selected period.

    On my report, I get 2 bars for each displayed hostname. Maybe the host names are not displayed as there a lot and the report is rendered for optimal playback.

    Even when export to HTML and looking at the source, host names are not available to extract and there is no option to export CSV. This is why I'm a bit stuck on how to generate a report with all the listed host names and their availability without going into the backend database.

    Any ideas?

    Hello

    What version of NMS are you running? The current version shows only one line per device. If you have upgraded and still see this behavior, pleaese reply to this topic.

    Thank you

  • EWS Officejet 6700: Host name is not editable

    On the network tab, select general/hostname. In the 'Host name' field change something different from the original host.
    But no name is accepted: for any other name that the original, I get the response "invalid entry. Click "OK" to go back.'.
    So in fact the host name is not editable.

    What is the good behavior of EWS? If this is not the case-how the host name must be changed?

    Hey @zvidan ,

    The firmware version is different than the current download.

    Once you have downloaded the new version then try to make the changes.

    Have you tried another browser?

    Have you tried to disable your antivirus software temporarily to see if that is causing the problem?

    Please let me know if you have the same results.

    Thank you.

  • Q10 Q10 blackBerry WIFI - browser error - could not resolve the host name

    Hello

    I use my Q10 while overseas for the Wifi only. My SIM card is in my 9900 (thank you BB not to tell anyone that BIS no longer works and WW BB roaming is not until after people buy OS 10 devices, anyway...) but I want to use the Q10 for Skype, browsing and Email while on WIFI.

    Skype works.

    Browser gives "Could not resolve the host name" and charge no emails.

    WiFi network is good (the 9900 is connected and works, as do other devices). I reset the phone, router, etc. etc.

    All to nothing does not.

    A telephone conversation of two hours with T-Mobile (from abroad) was unnecessary and disconnected.

    All DNS data seems to be there.

    Please help.

    Thank you

    Aviv

    Hello

    Problem solved.

    I have reset the router before, nothing helps. The only way I got it work is as follows:

    (1) turn off the router and wait for the phone to 'do not see' to the network in question.

    (2) turn off Wifi on the phone (menu setting and tap on wifi)

    (3) restart router

    (4) restart the phone

    After about 10 minutes, it is finally connected.

    Thank you all,

    I would BB would have simply kept the features of the 9900 and just made more attractive to the masses, instead of making an iphone with a keyboard...

  • Unsigned app deployment failed: "error: host name can not be null.

    Hello. "" I tried to download an app with Flash Builder 4.5 for my physical playbook unsigned, but this message has occurred: ' error: host name can not be null. The same mistake that happened when I tried to download the debugging token, but I managed to manipulate it using the command line. However, the problem with downloading mind because I can't run and test applications signed and cannot use the debug mode. Someone at - it had the same problem or knows how to get around? Additional information: Windows 7 (x 86); Flash Builder Burrito (build 287807), Playbook OS Version 1.0.1.1710

    I take that as a "I am the only one having this kind of problem" and nobody knows how to solve this (or has not yet read)

    [edit] so much worse... I just changed the IP address, this is the reason for the error.

  • I can't connect to the other user account... error message read s 'user name' or password. We have not set up a password and user name is correct.

    I can not access another user account.  It to request a username and password.  I enter the user name is correct and there is no password.  The login page, used to have two icons of the user; but for some reason, the last log on the user icon is here and a new white icon for the new user.

    Once a week a few posters noted a problem similar to yours. In this case, I post the answer you see below. The little that I find very irritating that in each case, without exception, the poster was not able to return and account for the results, either because they found my recipe too difficult to follow, or because he or she lost interest, he or she could not be bothered to post a few comments for the benefit of other people with the same problem. There it is again...

    I do not know why you can not change this password, but maybe this method will shed light on the question:

    1. Safe boot mode.
    2. Click Start.
    3. Type the three letters cmd into the search box.
    4. Press Ctrl + Shift + Enter
    5. Click on "Run as Administrator".
    6. Type the following commands and press ENTER after each one:
      'John Doe' ppp NET user / add
      (to create an account called "John Doe" with the ppp password)
      net localgroup administrators/add "John Doe"
      (to promote "John Doe" to the Administrators group)
      net localgroup administrators/del 'John Doe'
      (to demote this account)
      NET user "John Doe" ppp
      (to set the password for John Doe at ppp)
      NET user "John Doe" / active: Yes
      (to activate this account)
      NET user "John Doe" / active: No.
      (to disable this account)
      NET user "John Doe" / del
      (do not delete this account)
      NET user
      (to view all existing account names)
  • F0169 (host name ESXi) service profile could not apply the configuration

    I just created a new vNIC on 2 of my new hosts. I created the pools MAC address before you start. As I create the vNIC I got the following error:

    Your changes:

    Created VNIC FTNNIC

    Create: network fault tolerance

    Fail the Configuration of:

    Profile service (ESXi host name) org-root-[(Server:sys/chassis-2/blade-8)]

    Failure reason: connection-investment

    There are not enough global resources

    Not enough available vNIC

    Are you sure you want to apply the changes?

    I click Yes, and then get F0168 error service profile could not apply the configuration?

    What I do wrong here and how to fix it?

    Can you please more information, for example

    -What type of Blade model, input-output adapter

    -Version UCS

    -ESXi version

  • Hello, my name is Elias. I'm having problems with Adobe Creative Cloud, I wrote an email is not correct and I can't change it. How to fix?

    Hello, my name is Elias. I'm having problems with Adobe Creative Cloud, I wrote an email is not correct and I can't change it. How to fix it?

    Hello

    See the following topics:

    Bad e-mail address to sign in to Creative Cloud Desktop, how to pass to my email address?

    CC has a fake email, can not change

    Hope that helps!

    Kind regards

    Sheena

Maybe you are looking for