PowerShell to Manage thumbnail Cache databases used by file Explorer

So I have seen some issues with thumbnails in 1809 Enterprise edition. When I am aggravated with them I clip them. it’s just good hygiene. lol   so here is a telltale script that does just that. <# Thumbnail Issue -kill explorer tasks -Remove Thumbnail databases -restart explorer #> #-kill explorer tasks write-host “stopping theContinue reading “PowerShell to Manage thumbnail Cache databases used by file Explorer”

User Back up function or Script

  First I want to point out the $home variable for individual self initiated back ups. so if you wanted to back up specifics to the current logged in user $home is Sufficient, even if you have DFS / or SMB redirected home folders. if you are backing up all users you need to alsoContinue reading “User Back up function or Script”

AWS/GoogleCloud and harnessing PowerShell (One Shell to rule them all)

Heads up….. The cloud is ready. There is alot of fun to be had with different Platforms and PowerShell grew up on the mean streets of scrutiny, much like myslef and we are much alike in our flexibility to adapt and automate anything, although I am sure PowerShell probably doesn’t need me as much asContinue reading “AWS/GoogleCloud and harnessing PowerShell (One Shell to rule them all)”

Using a series of numbers to loop through an object or process.

I wanted to share this to help people that have to build scripts that parse/writes tons of files. I always use the numbers depending on scale like the following. 1..17 | |foreach-object {Write-Output “User$_”} another example if you need files: $objectarray=@() 1..17 | |foreach-object {new-object psobject  -property @{ name=”User$_”} Well depending on the task youContinue reading “Using a series of numbers to loop through an object or process.”

Learning when and “Where”.

learning your way around the shell is really important. the “where-Object” is like the GPS of the pipeline and to elaborate on the pipeline a little is a one way train to get you to the solution you need. here is an example. I set this to select the first one to help trim theContinue reading “Learning when and “Where”.”

PowerShell Get-TimeMachine?!

Well, I know what you’re thinking, it is just click bait. But I want to assure you it is possible. You could create this into a function but the magic is in the details of this one. “New-TimeSpan” is a tool that has existed since 2.0 and before you start-sleep ever again, consider the possibilitiesContinue reading “PowerShell Get-TimeMachine?!”

Writing Functions in PowerShell

I would like to propose we should all function as adults at some point in life. maybe not 24 hours a day but enough to take care of ourselves. PowerShell is an area that need you to be functioning to preserve your sanity and time, I will cover simple & advanced functions. A function canContinue reading “Writing Functions in PowerShell”

Troubleshooting Desktop Issues with Get-Eventlog

in the event you need to check your computer events to track down issues with your machine I must implore you to use “get-EventLog”   use this to your advantage to pinpoint issues.   in the image I used : Get-EventLog -LogName system -Newest 1 -EntryType Error | Format-List   mainly to for word wrapContinue reading “Troubleshooting Desktop Issues with Get-Eventlog”

Audit Objects in your Domain(s) using switch statements in PowerShell

I find it important to figure out who and what is in your active directory OUs get-aduser $TargetedUser What about groups, and computers? get-adobject $targetObject this includes users, groups, and computers. here is a switch that will report differently based on object class property that gets returned. get-adobject -filter *| foreach-object{ Switch($_.Objectclass) { User{ write-hostContinue reading “Audit Objects in your Domain(s) using switch statements in PowerShell”