After a database has been restored, users may become orphaned, or disconnected, from the database. You will see an entry for the user in the […]
Continue readingAuthor: kevin
Query Table Sizes from a SQL Database
I pulled apart a few stored procedures and ended up with this code. Very nice way to query the row count and size for each […]
Continue readingFind string within files on a Linux Server
This is a very useful bit of code, used to search within files on a Linux server. Replace the . after find to search within […]
Continue readingRecursively count the number of files on a Linux server
Simple script to recursively count the number of files on a Linux server. ls -laR | wc -l How this works: ls (lists folder contents), […]
Continue readingVBScript and WMI to stop and restart a running service
Option Explicit Dim objWMIService, objItem, objService Dim colListOfServices, strComputer, strService, intSleep strComputer = “.” intSleep = 15000 WScript.Echo “Click OK to begin” ‘On Error Resume […]
Continue readingSimple MySQL Database Backup
Another simple backup script. This script builds on the rsync file backup to allow daily, monthly, and yearly incremental MySQL database backups. The backup will […]
Continue readingSimple rsync Backup
This is a simple rsync backup that creates daily, monthly, and yearly incremental backups. This type of script would allow for recovery of just about […]
Continue readingQuery a List of Servers from Active Directory
I needed a list of all servers listed in AD. There are many scripts out there that do this, but they didn’t quite fit my […]
Continue readingSQL Server CPU Utilization
Some helpful SQL stats from this article. — From the SQL Server Performance Dashboard (sys.dm_os_ring_buffers) — Query CPU utilization for each four minute intervals declare […]
Continue readingList all Documents in SharePoint
I’ve used these queries for years, they come in handy when planning growth or a migration. A quick Google search will find many more queries […]
Continue reading