vmware / govmomi

Go library for the VMware vSphere API
Apache License 2.0
2.3k stars 911 forks source link

invalid memory address or nil pointer dereference when adding local user to group #2013

Closed apalcloud closed 4 years ago

apalcloud commented 4 years ago

It seems govc doesn't support to add a local user account to the sso group. But VMW allows me to do this through vSphere Client GUI.

govc sso.group.update -a

panic: runtime error: invalid memory address or nil pointer dereference [signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0xd7f1d4] goroutine 1 [running]: github.com/vmware/govmomi/govc/sso/group.(*update).Run.func1(0xc0004aa000, 0xc000402a80, 0x142e720) /home/vmware/src/github.com/vmware/govmomi/govc/sso/group/update.go:79 +0x254 github.com/vmware/govmomi/govc/sso.WithClient(0x1442b60, 0xc0000b2010, 0xc0000a5ad0, 0xc000163df8, 0x0, 0x0) /home/vmware/src/github.com/vmware/govmomi/govc/sso/client.go:79 +0x37d github.com/vmware/govmomi/govc/sso/group.(*update).Run(0xc00009a740, 0x1442b60, 0xc0000b2010, 0xc0000d26c0, 0x0, 0x0) /home/vmware/src/github.com/vmware/govmomi/govc/sso/group/update.go:66 +0xcd github.com/vmware/govmomi/govc/cli.Run(0xc0000c0010, 0x4, 0x4, 0xc00009c058) /home/vmware/src/github.com/vmware/govmomi/govc/cli/command.go:165 +0x56e main.main() /home/vmware/src/github.com/vmware/govmomi/govc/main.go:97 +0x64

apalcloud commented 4 years ago

It's govc 0.22.1

dougm commented 4 years ago

Duplicate of #1861 0.23 will happen soon, you can also use the prelease in the meantime.

apalcloud commented 4 years ago

@dougm could you please point me to the URL to download the prelease version?

dougm commented 4 years ago

https://github.com/vmware/govmomi/releases/tag/prerelease-v0.22.1-247-g770fcba2

Name is confusing, but its the current tag + delta

apalcloud commented 4 years ago

Thanks!

On Thu, Jun 11, 2020 at 3:39 PM Doug MacEachern notifications@github.com wrote:

https://github.com/vmware/govmomi/releases/tag/prerelease-v0.22.1-247-g770fcba2

Name is confusing, but its the current tag + delta

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/vmware/govmomi/issues/2013#issuecomment-642940623, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB22UFF4YXBPGVRTE6CFYNDRWFFHPANCNFSM4N3YBFEQ .