F5 Sites
  • F5.com
  • F5 Labs
  • MyF5
  • NGINX
  • Partner Central
  • Education Services Portal (ESP)
Contact
  • Under Attack?
  • F5 Support
  • DevCentral Support
  • F5 Sales
  • NGINX Sales
  • F5 Professional Services
Open Side Menu
Skip to contentBrand Logo
Forums
CrowdSRC
Articles
GroupsEventsSuggestionsHow Do I...?
RegisterSign In
  1. DevCentral
  2. CrowdSRC
  3. CodeShare

BigIP Report Old

Problem this snippet solves: This codeshare has been deprecated due to a hosting platform corruption. I have moved code and conversation to a new record (on the same original URL) https://devcentra...
Updated Dec 08, 2022
Version 2.0
application delivery
devops
iControl
LTM
microsoft powershell with icontrol
Patrik_Jonsson's avatar
Patrik_Jonsson
Icon for MVP rankMVP
Joined January 16, 2009
View Profile
swcherry's avatar
swcherry
Icon for Nimbostratus rankNimbostratus
Jul 16, 2020

  Thanks for replying. I debugged the script as you suggested and there are several "401 Authorization failed" errors in the output. Below is a sample:

 

{"datetime":"2020-07-16 09:52:06","severity":"SUCCESS","message":"Successfully loaded the config file: bigipreportconfig.xml"}

{"datetime":"2020-07-16 09:52:06","severity":"VERBOSE","message":"Starting: PSCommandPath=C:\\inetpub\\bigipreport\\bigipreport.ps1 ConfigurationFile=bigipreportconfig.xml PollLoadBalancer=<device_name_redacted> Location= PSScriptRoot=C:\\inetpub\\bigipreport"}

{"datetime":"2020-07-16 09:52:06","severity":"VERBOSE","message":"Pre-execution checks"}

{"datetime":"2020-07-16 09:52:06","severity":"SUCCESS","message":"Pre execution checks were successful"}

{"datetime":"2020-07-16 09:52:06","severity":"VERBOSE","message":"Enabling TLS1.2"}

{"datetime":"2020-07-16 09:52:06","severity":"VERBOSE","message":"Getting data from <device_name_redacted>"}

Invoke-RestMethod : {"code":401,"message":"Authorization failed: user=https://localhost/mgmt/cm/system/authn/providers/tmos/1f44a60e-11a7-3c51-a49f-82983026b41b/users/3a0d0d04-e904-37f6-9117-726f51919714 resource=/mgmt/tm/sys/global-settings verb=GET uri:http://localhost:8100/mgmt/tm/sys/global-settings referrer:10.4.16.20 sender:10.4.16.20","referer":"10.4.16.20","restOperationId":2944442,"kind":":resterrorresponse"}

At C:\inetpub\bigipreport\bigipreport.ps1:1622 char:17

+ ... $Response = Invoke-RestMethod -SkipCertificateCheck -Headers $Headers ...

+                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ CategoryInfo         : InvalidOperation: (Method: GET, Reques\u2026PowerShell/6.2.3

}:HttpRequestMessage) [Invoke-RestMethod], HttpResponseException

+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeRestMethodCommand

The property 'hostname' cannot be found on this object. Verify that the property exists.

At C:\inetpub\bigipreport\bigipreport.ps1:1623 char:5

+    $BigIPHostname = $Response.hostname

+    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

+ CategoryInfo         : NotSpecified: (:) [], PropertyNotFoundException

+ FullyQualifiedErrorId : PropertyNotFoundStrict

 

Help guide the future of your DevCentral Community!

What tools do you use to collaborate? (1min - anonymous)

ABOUT DEVCENTRAL

DevCentral NewsTechnical ForumTechnical ArticlesTechnical CrowdSRCCommunity GuidelinesDevCentral EULAGet a Developer Lab LicenseBecome a DevCentral MVP

RESOURCES

Product DocumentationWhite PapersGlossaryCustomer StoriesWebinarsFree Online CoursesTraining & Certification

SUPPORT

Manage SubscriptionsProfessional ServicesCreate a Service RequestSoftware DownloadsSupport Portal

PARTNERS

Find a Reseller PartnerTechnology AlliancesBecome an F5 PartnerLogin to Partner Central

©2026 F5, Inc. All rights reserved.
TrademarksPoliciesPrivacyCalifornia PrivacyDo Not Sell My Personal Information