A Get-ItemProperty Fail Regarding IIS

This topic contains 2 replies, has 2 voices, and was last updated by Profile photo of Josh Castillo Josh Castillo 8 months, 1 week ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #34034
    Profile photo of Josh Castillo
    Josh Castillo
    Participant

    So I'm going through "Learn IIS In A Month of Lunches" and I get to setting the recycling time. I first read the command: Get-ItemProperty -Path IIS:\AppPools\DefaultAppPool -Name recycling.PeriodicRestart.time

    And then I do the next logical thing. I do a Get-ItemProperty on the path and thats where everything falls apart. The item property that I just modified is not there. Yes, it is NOT there. Nor are items like recycling.PeriodicRestart.schedule.collection

    Really? I don't swear often, but this made me want to swear. What is the point of Get-ItemProperty if you don't list everything that is there.

    Anybody have insight on this phenomenon?

    #34045
    Profile photo of Dave Wyatt
    Dave Wyatt
    Moderator

    Honestly, the whole IIS provider and module is kind of a failure. Instead of giving us any sort of reasonable abstraction, they just basically threw the structure of the underlying XML file in your face. That "recycling.PeriodicRestart.time" name is really just part of an XML element path under the default app pool node of a config file.

    #34114
    Profile photo of Josh Castillo
    Josh Castillo
    Participant

    I new there was something going on there. I'm getting to know IIS and having a PowerShell background you expect discoverability, not this. Its like the IIS team checked a box and called it a day... End rant.

    Thanks for confirming that, it was driving me nuts.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.