Reviews

Blog Posts

IT News (sign in to comment or post)

Site Activity

  • # Without CredSSP

    $SAMAccountName = 'MyDOMMyGroup'
    $SID = (New-Object System.Security.Principal.NTAccount($SAMAccountName)).Translate([System.Security.Principal.SecurityIdentifier]).Value
    $ACE = 'Execute'

    $ComputerName_List = @('Host01.mydom.com,Host02.mydom.com')
    Invoke-Command -ComputerName $ComputerName_List -ArgumentList @($SID,$ACE) -ScriptBlock {
        param
        (
            $SID,
            $ACE
        )

        switch ($ACE)
        {
                'Read'
                {
                    $ACE_Str = "(A;;GR;;;{0})" -f $SID
                    break
                }

                'Write'
                {
                    $ACE_Str = "(A;;GW;;;{0})" -f $SID
                    break
                }

                'Execute'
                {
                    $ACE_Str = "(A;;GX;;;{0})" -f $SID
                    break
                }

                'FullControl'
                {
                    $ACE_Str = "(A;;GA;;;{0})" -f $SID
                }
        }

        $ACE_Str = $ACE_Str + 'S:P(AU;FA;GA;;;WD)(AU;SA;GXGW;;;WD)'

        $Name = 'Microsoft.Powershell'
        $SecurityDescriptorSddl_Str = (Get-PSSessionConfiguration -Name $Name -ErrorAction Stop).SecurityDescriptorSddl

        $SecurityDescriptorSddl_Str = $SecurityDescriptorSddl_Str -replace 'S:P(AU;FA;GA;;;WD)(AU;SA;GXGW;;;WD)',$ACE_Str
        Set-PSSessionConfiguration -Name $Name -SecurityDescriptorSddl $SecurityDescriptorSddl_Str -Force -Confirm:$false
        
        Restart-Service WinRM
    }

    <#
    Prefx : O:NSG:BAD:P
    Administrators: (A;;GA;;;BA)
    INTERACTIVE: (A;;GA;;;IU)
    Remote Management Users: (A;;GA;;;RM)
    Sufx : S:P(AU;FA;GA;;;WD)(AU;SA;GXGW;;;WD)
    (A;;GXGW;;;{0})
    (A;;GWGR;;;{0})
    (A;;GXGR;;;{0})
    (A;;GXGW;;;{0})
    #>

  • Import-WinModule Microsoft.PowerShell.Management

     

    fails for me with the mysterious message:

    Method invocation failed because [System.Management.Automation.PSModuleInfo] does not contain a method named 'Where'.

  • Hi Kim,

    sorry i can not do much with your discription. 

    Maybe you send me a mail with your discription and pictures? 

    Yours

    Roland

  • Hi Matt,

    for the recycle bin is the same as inbox 

    You can see the right name of the folder with get-mailboxfolderstatistics -identity "user" | ft folderpath

    I hope it helps?

    Yours

    Roland

  • awesome post! 

     

    one question i have copied and pasted the script as per your instructions, but i continually get a compile error highlighting the text "Run Auto Out of Office?" in the exit script, any idea what i may have wrong?

    many thanks in advance 

  • AldoF became a registered member 13 hours, 42 minutes ago

  • Thank you for the information. Can you add how to do this? - "The better remedy here would be to set an authorization on the recycle bin of the corresponding mailbox instead."

  • Shaik became a registered member 1 day ago

  • Because the two commands are exactly the same...

  • good job

  • It'll be a function of where you call the dialog from.  Some apps (like the ISE) will remember the last folder you used, so, unless you specify a root every time, it will go to your last place.  

    Glad it worked out for you though 🙂  

    David F. 

  • Hi dear,

    Where can i get those pregenrated Powershell scripts.

    is there any commandlets for powershell by solarwinds for Patchmanager.

    kindly please let me know.

  • Thanks David... 🙂

    I have used above code and it is working and I am able to select folder.

    Facing one strange thing. Whenever I work in ISE, the select folder dialogue box went to last open item in windows instead of popping up on current window. But if I use powershell command line, dialogue box popping up and I can select folder.

  • I would suggest you run a script to detach and CDRom and unmount any VMWare tools install

  • Question about disabling alarms. So we are on the same page I am talking about when you right-click a host and left-click disable alarms. 

     

    I can't find a script that will allow me to disable the alarm and then enable the alarm on a per-host basis. Do you by chance have anything?

  • Another question'

     

    How would you combine baselines? For example, Critical Host Patches (Predefined) and Non-Critical Host Patches (Predefined)

  • Can we use Cluster-Shared Volume for a simple shared folder (File Services) and not for Hyper-V as I need to mount a single NTFS drive on 2+ VMs in VMware 6.7+

© 4sysops 2006 - 2020

CONTACT US

Please ask IT administration questions in the forums. Any other messages are welcome.

Sending

Log in with your credentials

or    

Forgot your details?

Create Account