Quantcast
Channel: VMware Communities: Message List
Viewing all 231052 articles
Browse latest View live

Values in variable list have trailing spaces - Ho to get rid of trailing spaces?

$
0
0

I populate my variable with a list of my templates....

 

$MyTemplates = get-template | Select-Object Name | ft -HideTableHeaders

 

I get a list of....

 

server2019_gui         

server2019_cor         

server2016_gui         

server2016_cor         

server2016 domaincont_remotesite         

server2016 domaincont_homesite         

 

Problem is there are a bunch of spaces at the end of each line.

How do you get rid of those spaces? I tried $MyTemplates.Trim() but no luck and I get errors or I am using that totally wrong........lol

 

Thanks


Re:Export to CSV a list of VMs with specific custom attribute values

$
0
0
this is better with the expected output but still getting an error in powershell..  Get-Annotation : 2/11/2019 8:10:32 AM Get-Annotation  Exception has been thrown by the target of an invocation.  At C:\server\script.ps1:19 char:9 + where {(Get-Annotation -Entity $_ -CustomAttribute "flag" ... +         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~     + CategoryInfo          : NotSpecified: (:) [Get-Annotation], VimException     + FullyQualifiedErrorId : Core_BaseCmdlet_UnknownError,VMware.VimAutomation.ViCore.Cmdlets.Commands.GetAnnotation  ---------------------------SCRIPT----------------------  Import-Module VMware.VimAutomation.Core   $vCenters = import-csv \\REMOTESERVER\vCenters.csv $i = 1  $i=0 ForEach ($vCenter in $vCenters) {     $i+=1     Write-Progress -Activity "Processing VCenter $($vCenter.name)"  -PercentComplete ($i/$vCenters.count*100) -Id 0     connect-VIServer $vCenter.name }   $excludedValues = "Windows 7", "Windows 10"  Get-VM |  where {(Get-Annotation -Entity $_ -CustomAttribute "flag").Value -eq $true -and $excludedValues -notcontains (Get-Annotation -Entity $_ -CustomAttribute "custom2").Value } |  Select -Property Name |  Export-Csv -Path C:\server\report.csv -UseCulture

Re:Export to CSV a list of VMs with specific custom attribute values

$
0
0

sorry about the script layout. not sure how to make it pretty in this post. the output CSV also has this:

 

                                                             
#TYPE Selected.VMware.VimAutomation.ViCore.Impl.V1.VM.UniversalVirtualMachineImpl
Name
SERVER1
SERVER2
 

Re: Values in variable list have trailing spaces - Ho to get rid of trailing spaces?

$
0
0

You are using the Format-Table cmdlet, which is intended to format text going to the console, to populate a variable.
You should do this as follows

 

$MyTemplates=Get-Template|Select-Object-ExpandProperty Name

Try to restore 10.12 with TimeMachine

$
0
0

Hello,

 

I try to restore my old 10.12 system virtually.

I manged to setup a 10.12 Guest OS

In setting I set the virtaul drive size to 905GB

despite that I always get an out of diskspace error when I try to restore my old system (I tried both, just a dmg and a TimeMachine Backup)

 

What do I miss here?

 

thanks

admilon

Re:Export to CSV a list of VMs with specific custom attribute values

$
0
0

The extra info in the CSV can be avoided by using the NoTypeInformation switch.

 

The error you are getting could perhaps be caused by one or more VMs not having that custom attribute.

A screenshot of the error would be a bit more helpful.

 

Try like this first (I added the parameter to ignore the error if the custom attribute does not exist)

 

$vCenters=Import-Csv \\REMOTESERVER\vCenters.csv

$i=0

ForEach($vCenterin$vCenters){

    $i+=1

    Write-Progress-Activity "Processing VCenter $($vCenter.name)"  -PercentComplete ($i/$vCenters.count*100)-Id 0

    Connect-VIServer-Server $vCenter.name

}


$excludedValues="Windows 7","Windows 10"

Get-VM|

Where-Object{(Get-Annotation-Entity $_-CustomAttribute "flag"-ErrorAction SilentlyContinue).Value -eq$true-and

               $excludedValues-notcontains(Get-Annotation-Entity $_-CustomAttribute "custom2"-ErrorAction SilentlyContinue).Value }|

Select-Object-Property Name |

Export-Csv-Path C:\server\report.csv -UseCulture -NoTypeInformation

Re: windows 10 1809 slow

$
0
0

As previously mentioned, I can confirm with my environment with hosts upgraded to ESXi 6.7 U3 this is indeed resolved:

"

PR 2287232: Virtual machines with Microsoft Windows 10 Version 1809 might start slowly or stop responding during the start phase if they are running on a VMFS6 datastore

If a virtual machine is with Windows 10 Version 1809, has snapshots, and runs on a VMFS6 datastore, the virtual machine might either start slowly or stop responding during the start phase.

"

 

I have windows 10 1903 vm's.  Built on vmfs 6 storage. vm hardward 15, tools 10.3.10 or 11.0.  Multiple snapshots.  No delays in widows boot time.  Instant Clone deployments work perfectly fine.

Re: Question for Early vRA 8 Adopters

$
0
0

If it is an production environment definitely version 7.6. 8.0 for now has a lot of bugs. As you noticed it has only few weeks. For version 7.x you have a lot of articles, KB etc. which could help you in trouble. But 8.0....you don't know what to expect

But it is only my opinion.


Re: High number of threads on vcenter6 appliance

$
0
0

It has to be somewhere Maybe on Home page?

Or give me info what version do you have and I will try to find it.

Re: NSX-T 2.5 Manager node 100% CPU usage

$
0
0

mauricioamorim

Youre right, this is only a PoC.

 

I am currently running 4CPU yeah. If I up to 8 cores, they still use an insane amount of CPU.

But they are still using 7GHz CPU total for 4 CPU.

 

Also when doing TCPDUMP on one of the management hosts, I am getting about 1200 packets every second from the two other hosts on port 9000. I guess this is sync and API calls. But 1200 packets every second, is that normal?

 

This HOST is running:

  • Hypervisor:VMware ESXi, 6.7.0, 14320388
  • Model:VMware7,1
  • Processor Type:Intel(R) Xeon(R) CPU E5-2650 0 @ 2.00GHz
  • Logical Processors:24

 

 

Still, java command is still using all the CPU, with 8 cores...

 

 

top - 22:05:08 up 16 min,  1 user,  load average: 8.16, 8.14, 6.12

Tasks: 228 total,   1 running, 137 sleeping,   0 stopped,   0 zombie

%Cpu(s): 15.6 us, 33.3 sy,  0.0 ni, 47.2 id,  0.7 wa,  0.0 hi,  3.2 si,  0.0 st

KiB Mem : 20545804 total,  1977508 free, 10460276 used,  8108020 buff/cache

KiB Swap:        0 total,        0 free,        0 used.  9658316 avail Mem

 

 

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU %MEM     TIME+ COMMAND                  

12927 rabbitmq  20   0 4107308  29748   5084 S  68.5  0.1   0:05.14 beam.smp                 

6254 uproton   20   0 7402400 1.368g  18020 S  49.5  7.0  11:35.48 java                     

5401 corfu     10 -10 8576900 725512  20600 S  44.9  3.5   7:03.95 java                     

4535 nsx-cbm   10 -10 6163244 422036  22068 S  43.6  2.1   4:40.20 java                     

5685 uproton   20   0  9.888g 2.503g  16856 S  37.7 12.8  14:28.49 java                     

1184 nsx       10 -10  9.863g 1.149g  32884 S  32.1  5.9   5:17.04 java                     

    7 root      20   0       0      0      0 S   6.6  0.0   0:38.63 ksoftirqd/0              

2057 rabbitmq  20   0 5952776 133252   7280 S   4.6  0.6   1:49.24 beam.smp                 

4536 ucminv    20   0 5911800 756924  17688 S   4.3  3.7   2:11.75 java                     

6218 uphc      20   0 5874616 385424  16044 S   4.3  1.9   1:37.05 java                     

4583 elastic+  20   0 6716980 1.189g  22572 S   3.9  6.1   2:59.54 java                     

4857 uuc       20   0 5971452 765740  17628 S   3.3  3.7   2:18.02 java                     

5123 uproxy    20   0 6039064 527028  18524 S   2.6  2.6   1:49.00 java                     

    8 root      20   0       0      0      0 I   2.0  0.0   0:21.45 rcu_preempt              

  593 root      20   0       0      0      0 S   1.3  0.0   0:15.33 jbd2/dm-1-8              

  892 syslog    20   0  404412   7092   3536 S   1.3  0.0   0:09.30 rsyslogd                 

    9 root      20   0       0      0      0 I   0.7  0.0   0:05.05 rcu_sched                

1030 root      20   0    9512    136     12 S   0.7  0.0   0:07.46 rngd                      

Linux: error: incompatible gcc/plugin versions even though I downgraded to gcc 8.3.0?

$
0
0

I downloaded vmware-workstation from the arch linux AUR: https://aur.archlinux.org/packages/vmware-workstation/

built the package and tried to install it but I get this during the installation of the package:

 

DKMS make.log for vmware-workstation-15.5.0_14665864 for kernel 5.2.21-1-MANJARO (x86_64)

Fr 1. Nov 23:18:03 CET 2019

cp -r /usr/src/vmware-workstation-15.5.0_14665864/vmmon-only vmmon-only

cp -r /usr/src/vmware-workstation-15.5.0_14665864/vmnet-only vmnet-only

make KVERSION=5.2.21-1-MANJARO VM_KBUILD=yes -C vmnet-only

make[1]: Entering directory '/var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only'

make KVERSION=5.2.21-1-MANJARO VM_KBUILD=yes -C vmmon-only

make[1]: Entering directory '/var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only'

Using kernel build system.

Using kernel build system.

make -C /lib/modules/5.2.21-1-MANJARO/build/include/.. M=$PWD SRCROOT=$PWD/. \

  MODULEBUILDDIR= modules

make[2]: Entering directory '/usr/lib/modules/5.2.21-1-MANJARO/build'

make -C /lib/modules/5.2.21-1-MANJARO/build/include/.. M=$PWD SRCROOT=$PWD/. \

  MODULEBUILDDIR= modules

make[2]: Entering directory '/usr/lib/modules/5.2.21-1-MANJARO/build'

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/linux/driverLog.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/linux/driver.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/linux/hostif.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/apic.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/memtrack.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/driver.o

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/linux/driverLog.o] Error 1

make[3]: *** Waiting for unfinished jobs....

cc1: error: incompatible gcc/plugin versions

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/linux/driver.o] Error 1

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/statVarsVmmon.o

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/linux/hostif.o] Error 1

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/vmx86.o

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/apic.o] Error 1

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/memtrack.o] Error 1

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/driver.o] Error 1

make[3]: *** Waiting for unfinished jobs....

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/statVarsVmmon.o] Error 1

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:278: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only/common/vmx86.o] Error 1

make[2]: *** [Makefile:1597: _module_/var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only] Error 2

make[2]: Leaving directory '/usr/lib/modules/5.2.21-1-MANJARO/build'

make[1]: *** [Makefile:121: vmmon.ko] Error 2

make[1]: Leaving directory '/var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmmon-only'

make: *** [Makefile:13: vmmon.ko] Error 2

make: *** Waiting for unfinished jobs....

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/hub.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/netif.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/userif.o

  CC [M]  /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/bridge.o

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:279: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/hub.o] Error 1

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:279: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/userif.o] Error 1

make[3]: *** [scripts/Makefile.build:279: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/netif.o] Error 1

cc1: error: incompatible gcc/plugin versions

cc1: error: fail to initialize plugin ./scripts/gcc-plugins/structleak_plugin.so

make[3]: *** [scripts/Makefile.build:279: /var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only/bridge.o] Error 1

make[2]: *** [Makefile:1597: _module_/var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only] Error 2

make[2]: Leaving directory '/usr/lib/modules/5.2.21-1-MANJARO/build'

make[1]: *** [Makefile:121: vmnet.ko] Error 2

make[1]: Leaving directory '/var/lib/dkms/vmware-workstation/15.5.0_14665864/build/vmnet-only'

make: *** [Makefile:13: vmnet.ko] Error 2

 

Why is that? Which version of gcc does vmware-workstation expect me to have?

Re:Export to CSV a list of VMs with specific custom attribute values

$
0
0

thanks lucD.

The error that I'm sharing is the error getting shown on the powershell screen. is there some way i can output any errors to a csv file with more information? perhaps with the VM(s) that are causing the problem?

Re:Export to CSV a list of VMs with specific custom attribute values

$
0
0

A screenshot of that error would be more useful than the text dump.
And yes, if you know for which VMs the error occurs, check if these VMs have both Custom Attributes.

Re: NSX-T 2.5 Manager node 100% CPU usage

$
0
0

So even with 32G ram and 8CPU, which is more than "medium" I am still having huge CPU usage.

 

Looking at packet count and the picture in last post, you can see its used 600MB of data for only ~20 minute uptime. And I have no VM's or networks connected to these...

Re: NSX-T 2.5 Manager node 100% CPU usage

$
0
0

So you're running 2 managers (not 3) and you're doing this in a nested vSphere setup?


Re:Export to CSV a list of VMs with specific custom attribute values

$
0
0
attached its the error. its the same error 3 times and ive removed the script patch and custom annotation name due to privacy.

Re: NSX-T 2.5 Manager node 100% CPU usage

$
0
0

daphnissov click picture, its three managers.

 

Yes, its a nested environment, virtualization with exposed hardware for cpu enabled. Isn't that what VMware themself use for their labs in their online classrooms?

 

I know its not the most powerful CPU. But still, an idling NSX-T manager really eating that much CPU?

 

 

Manufacturer HP

Model ProLiant DL380p Gen8

CPU

Logical processors 32

Processor type Intel(R) Xeon(R) CPU E5-2650 0 @ 2.00GHz

Sockets 2

Cores per socket 8

Hyperthreading Enabled

Re: I don't want this version of VMware

$
0
0

Which VMware product? It can’t be vSphere as that’s at 6.7

Re: Vcenter Server 5.5

$
0
0

Just because you kept an old copy does not mean you should be sharing it.

Re:Export to CSV a list of VMs with specific custom attribute values

$
0
0

Ok, 'Unknown error' doesn't give a lot of info

 

Does the error occur only for a limited set of VMs or for all VMs?

Do the VMs for which the error occurs have both Custom Attributes?

Viewing all 231052 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>