lunes, 22 de octubre de 2018

PowerCLI: Configuration PowerCLI



Configuring PowerCLI


ALARMS:


PowerCLI C:\>Connect-VIServer -Server 10.60.105.77 -User administrator@vsphere.local -Password Passw0rd!

PowerCLI C:\> Get-AlarmDefinition -Name 'Host connection and power state' |Set-AlarmDefinition -Description 'Host Power State'


PowerCLI C:\> Get-AlarmDefinition -Name 'Host connection and power state' |Set-AlarmDefinition -Description 'Host Power State'  -ActionRepeatMinutes 5

PowerCLI C:\> Get-AlarmDefinition -Name 'Host connection and power state' |New-AlarmAction -Email -To 'operaciones@company.com'


PowerCLI C:\> Get-AlarmDefinition -Name 'Host connection and power state' | Get-AlarmAction


NETWORKING:


New dvSwitch:

New-VDSwitch -Name 'VMware_COMPANY

Remove dvSwitch:

Get-VDSwitch -Name 'VMwar3_COMPANY' | Remove-VDSwitch -Name 'VMwar3_COMPANY'

Get-VDSwitch -Name 'VMwar3_COMPANY' | New-VDPortgroup -Name 'VMware_POrtgroup'

Teaming Policy dvportgroup:

Get-VDSwitch "dvsCOMPANY" | Get-VDPortGroup DMZ Virtual IPs | Get-VDUplinkTeamingPolicy | Set-VDUplinkTeamingPolicy -LoadBalancingPolicy LoadBalanceLoadBased


-LoadBalancingPolicy

1.  LoadBalanceIP - Description #Set Route based on IP hash
2.  LoadBalanceSrcMac - Description #Set Route based on source MAC hash
3.  LoadBalanceSrcId - Description #Set Route based on originating virtual port
4.  ExplicitFailover - Description #Set Use explicit failover order
5.  LoadBalanceLoadBased - Description #Set Route based on physcial NIC load
6.  LoadBalanceIP - Description #Remove $pg to apply new load balancing policy to all portgroups on the same VDS


CLUSTER DRS

PowerCLI C:\>Connect-VIServer -Server 10.60.105.77 -User administrator@vsphere.local -Password Passw0rd!


Get-Cluster

DRS Configuration

Get-Cluster C3-MGMT |Set-DrsAutomationLevel Manual

Set-Cluster C3-DEV -DRSAutomationLevel PartiallyAutomated

Set-Cluster C3-DEV -DRSAutomationLevel FullyAutomated

Add Host to Cluster

Get-Cluster C3-MGMT | Add-VMHost 1amp-esxi02.company.net -User root -Password VMwr3!!


Remove Host from Cluster

Get-VMHost covbneswcinrm2002.ilumno.net -Location DC | Remove-VMHost -Confirm:$false



VCSA CLI Installer



VCSA CLI INSTALLER

Hello Guys,

In this post I'm going to show how to install VCSA 6.5 with CLI Installer, In this post I did this installation in Mac and Windows Server 2016 too.  


1.  Configuring the Json File:


  • Where I find de JSON File
          F:\vcsa-cli-installer\templates\install

          In my case I used a Windows Server but you can use Linux or Mac too (I promise in Mac :))


In this Deploymet I'm going to Install VMware vCenter Server and Platform Services Controller:

       
The First Step is configure the PSC_first_instance_on_ESXi file.




Imagen 1: VCSA Json File


So After that you need to excecute the next command (In windows CMD, Terminal on Mac or Linux)

Where I find these commands?

Here: https://www.vmware.com/content/dam/digitalmarketing/vmware/en/pdf/techpaper/products/vsphere/vmware-vsphere-60-vcenter-server-appliance-cmdline-install-technical-note.pdf 

2. Executing the command for the VMware Platform Service Controller



  • Command Options:



  • Command Structure
            Windows:

            Verify the JSON File:
             
           F:\vcsa-cli-installer\win32>vcsa-deploy.exe install --acknowledge-ceip --accept-eula --no-esx-             ssl-verify --verify-only C:\temp\install\PSC_first_instance_on_ESXi.json 

             Result:


            Install PSC

            Windows:

              F:\vcsa-cli-installer\win32>vcsa-deploy.exe install --acknowledge-ceip --accept-eula --no-                    esx-ssl-verify C:\temp\install\PSC_first_instance_on_ESXi.json 













martes, 18 de julio de 2017

Getting Host Id


How to get the Host ID?

Hello Guys!!

In this post I'm going to show you how to get the Host ID.

Using PowerCLI




Using hostlist



Thanks for visiting my Blog!!!

Share and be sociable!!

lunes, 17 de julio de 2017

Storage vMotion: PowerCLI



Storage vMotion With PowerCLI

Hello Guys!!!


In this post I'm going to show you how to do a Storage vMotion Using PowerCLI. Something basic but cool 😋


The first step is connect to vCenter Server 




Use this command: Get-VM VMNAME   | Move-VM -Datastore DATASTORENAME


Check the picture... This really works 😉


Thanks for visiting my Blog!!!

Share and be sociable!!!




domingo, 16 de julio de 2017

Horizon with View 7.2: Installation



Installing View Connection Server


Hello Guys!!

In this post I'm going to show the installation of VMware Horizon 7.2 Connection Server.

Let's Start!!!

Execute the installer with Priviligies, click Next to continue



Check the license agreement.....


Select the folder for the installers files


Select standar... check HTML Acces... In my case IPv4 but is possible IPv6


Recovery password.......... Next


Check the Windows Firewall.... Next...


I reccomend to use the same user that the installation..... Next.


Next.......


Click to Install......



Click to Finish... Don't forget to check the read me file...


Take note......


And finally you can go to this url:

For acces the desktop or download the client:

https://fqdnconnectionserver

For admin interface:

https://fqdnconnectionserver/admin




Thanks for visiting my Blog!!!

Share and be sociable!!


lunes, 3 de julio de 2017

vCenter Server 6.5: Backup


Backup vCenter Server 6.5

Hello Guys!!

In this post I'm going to show you how to take backup of vcenter server.

First, We need to go to this address: https://IPofvCenterServer:5480

Please use root and password


Click in Backup...





In my case I'm using a FTP Server (Windows Based) fill the path, port, user and password click Next

  

Select the information for take backup; I recommend select both options.. After click to Next



Check the Ready to Complete and click to Finish..





...........And the backup is succesfull click OK.


............................



VMware Reference:
https://blogs.vmware.com/vsphere/2017/01/vcenter-server-appliance-file-based-backup-restore-walkthroughs.html


Thanks for visiting my Blog!!!

Share and be sociable!!!

sábado, 1 de julio de 2017

PowerCLI: Delete From Disk


Delete From Disk

Hello Guys!!

In this post I'm going to show you how to delete a VM using PowerCLI (Something Basic but Cool).


First you need to identify the VM

Get-VM



After that we need to stop the VM,...., how? Use this command

Stop-VM -VM PHOTON01 -Confirm

So, the last step is delete the virtual machine...

Remove-VM PHOTON01 -DeletePermanently




VMware reference:https://www.vmware.com/support/developer/PowerCLI/PowerCLI41U1/html/Get-VM.html 

Thanks for visiting my blog!!

Share and be sociable!!!




VMware Tools Using VIB

 Hello Guys, In this post I'm going to show you how to apply a VMware Tools VIB to update the version propagated by the ESXi Host. First...