Skip to content

Mike Simmons

My Workbench

  • Home
  • LinkedIn

PowerShell Anti-Idle Script

Posted on August 31, 2022September 29, 2022 By Mike No Comments on PowerShell Anti-Idle Script
PowerShell

I developed a PowerShell script to prevent the system from idling, locking or turning off the monitors. It will also ensure team’s idle will not trigger. Save as anti-idle.ps1 and call it via a batch file for simplicity.  Batch – anti-idle.bat @echo off PowerShell – anti-idle.ps1

WSUS MMC Crash Due To XML Invalid Character!

Posted on March 27, 2018March 27, 2018 By Mike No Comments on WSUS MMC Crash Due To XML Invalid Character!
Uncategorized

So today as I was checking on the update status of all the windows computers the WSUS MMC Console would throw the following error (System.Xml.XmlException — ‘’, hexadecimal value 0x16, is an invalid character). Upon googling this issue I came across a technet article which contained a solution and some improvements on the first provided … Read More “WSUS MMC Crash Due To XML Invalid Character!” »

Open Maintenance – Docker & CentOS 7

Posted on March 27, 2018March 27, 2018 By Mike No Comments on Open Maintenance – Docker & CentOS 7
CentOS, Docker

It seems docker and containers are becoming the new default standard for simple, rapid and consistent deployment. I was asked to deploy out open maintenance recently at work and decided to look into the simplest options to deploy it out. I reviewed the open maintenance website and didn’t see any ready made ova images or a simple up to date guide on getting it up and running quickly which lead me to google. I first tried openmaint vm as a search term which lead me to only one result which seemed creditable bitnami which has yet to create an ova or deployment package for it. I then decided to see if someone put together a docker container for it which they did link here. I then decided to see if VMWare can run containers directly, it can but we run 5.5 internally which doesn’t support that feature. I then decided to setup a CentOS box to run the Docker container in our ESXI environment that way. 

Read More “Open Maintenance – Docker & CentOS 7” »

Powershell script to create user home directory and DFS namespace target

Posted on March 16, 2018March 16, 2018 By Mike No Comments on Powershell script to create user home directory and DFS namespace target
Active Directory, PowerShell, Windows

Creating a new users home directory and corresponding DFS namespace target. The script can also force all domain controllers to fully sync up in case you have multiple sites. Sync is enabled by default, however it can be disabled. This powershell script does require WinRM to be enabled for sync to work. You need to have setup the DFS namespace root path already.

Read More “Powershell script to create user home directory and DFS namespace target” »

C# save DataTable to CSV easily

Posted on March 16, 2018March 16, 2018 By Mike No Comments on C# save DataTable to CSV easily
C#, Programming

I find I need to save C# DataTables to CSV files often and as such use the following code:

Read More “C# save DataTable to CSV easily” »

Easily save and load C# classes using XML Serialization

Posted on March 16, 2018March 16, 2018 By Mike No Comments on Easily save and load C# classes using XML Serialization
C#, Programming, XML

These two functions below have saved me a lot of time, you simply create a class with variables inside it and then pass said class to the two functions below:

Read More “Easily save and load C# classes using XML Serialization” »

Graylog extractors for Sophos UTM logs

Posted on March 16, 2018March 16, 2018 By Mike No Comments on Graylog extractors for Sophos UTM logs
GrayLog

I have created nine extractors to get all the Sophos variables I needed to use.

Read More “Graylog extractors for Sophos UTM logs” »

Graylog format AccessList For Windows file events

Posted on March 16, 2018March 16, 2018 By Mike No Comments on Graylog format AccessList For Windows file events
GrayLog

I setup Graylog to collect all the windows event logs including file event logs on the file servers at work. I noticed that the winlogbeat_event_data_AccessList field was not what the event did rather a %%#### code. I decided to build a pipeline to format the winlogbeat_event_data_AccessList field into a new field I designated as AccessList.

Read More “Graylog format AccessList For Windows file events” »

PowerShell exporting data easily from MSSQL into a CSV

Posted on March 16, 2018March 16, 2018 By Mike No Comments on PowerShell exporting data easily from MSSQL into a CSV
MSSQL, PowerShell, Programming, Windows

PowerShell has a module to assist with this, you can find out all the specifics at https://docs.microsoft.com/en-us/sql/powershell/download-sql-server-ps-module. I was asked to pull data and export it to a CSV to save time, which is easy to do with Task Scheduler and PowerShell.

Read More “PowerShell exporting data easily from MSSQL into a CSV” »

PowerShell Tid Bits #1

Posted on July 28, 2017March 16, 2018 By Mike No Comments on PowerShell Tid Bits #1
PowerShell, Programming

The more I use power shell the more I realize you can do just about anything you could do with visual studio and C#. I haven’t found a comprehensive source for all the little differences between C# and powershell but the following are some things to take note of:

Read More “PowerShell Tid Bits #1” »

Posts navigation

1 2 Next

Pages

  • LinkedIn

Recent Posts

  • PowerShell Anti-Idle Script
  • WSUS MMC Crash Due To XML Invalid Character!
  • Open Maintenance – Docker & CentOS 7
  • Powershell script to create user home directory and DFS namespace target
  • C# save DataTable to CSV easily

Recent Comments

    Archives

    • August 2022
    • March 2018
    • July 2017
    • August 2015

    Categories

    • Active Directory
    • C#
    • CentOS
    • Docker
    • GrayLog
    • MSSQL
    • Networking
    • PowerShell
    • Programming
    • Uncategorized
    • Windows
    • XML

    Meta

    • Log in
    • Entries feed
    • Comments feed
    • WordPress.org

    Copyright © 2023 Mike Simmons.

    Theme: Oceanly by ScriptsTown