The reason I decided to write about lightening system administrators’ workload is simple: it’s the future. Sure, there are no flying cars or teleporters, (yet!) but we do have self-driving vehicles and hoverboards! And because it’s the future, I strongly believe that people should not be doing repetitive tasks; instead, we should let the robots do it.
Now, when I say “robot,” that does not mean a humanoid machine sitting at my desk. I’m actually talking about the machine I’m hitting with my fingers to make it do stuff. The machine that can go hours on end, with no food or need for rest. Computers.
In my previous post, I talked about repetitive tasks and some ways to perform them, but those were one-off tasks. What about the tasks that you have to perform daily, weekly, monthly, or even yearly? Tasks that you have been doing so long and so frequently that you can do them in your sleep. Tasks that consume your time and energy. There has to be a better way, and fortunately, there is.
But before you venture into automating tasks, there is basic knowledge you need to possess. Let’s briefly go over what you need to get started:
Understanding how to write scripting code, or really just possessing any programming knowledge, is immensely helpful in creating automated tasks. When starting this journey, you’ll soon realize that knowing your way around your Visual Basic (VB) scripts or batch files will go a long way. If you are a Microsoft System Administrator just starting to learn scripting, I recommend PowerShell, a powerful scripting language based on Microsoft’s .NET framework.
It is very important to have centralized management for your scripts or commands. It seems easy to configure tasks using Microsoft’s Task Scheduler, but if any changes need to be made to the schedule or the scripts being run, it can become a nightmare.
Determining which tool to use for managing scripts will require a bit of research on your part. Here are some things to consider when choosing a system:
- Do we manage Windows Servers as well as Linux Servers?
- How big is my infrastructure? 10-100 servers? 100-1000? 1000-10000?
- What is my budget, if any?
- Do I want to manage anything besides servers, such as switches or firewalls?
- Do I mind spending a lot of time configuring the system?
All these questions will be fundamental when deciding what system to use.
I have written about one of the systems out there before: Microsoft System Center 2012. This powerful tool can automate server configuration, server deployments, server monitoring, diagnostics, recovery tasks, recurring tasks, etc. This is only one of the many great systems out there, and since most of them have free trial periods, you can try them out to determine which one is right for you.
Are You Ready to Automate?
The next logical question to ask is: What should I be automating? As I mentioned before, any recurring task should be automated. I can’t be clearer than that. If you need some examples though, here they are:
Windows Server Disk Defragmentation
Over time, the data on Windows drives has the habit of fragmenting. Depending on the amount of fragmentation, your servers will experience some performance issues. Performing disk defragmentation (which is often referred to as a “defrag”) will resolve this issue and ensure that your servers run efficiently. A defragmentation task can be scheduled on the servers themselves, but we want to reduce work, not increase it.
Any centralized task manager and a quick script will make it possible to run a defrag either proactively or reactively. Scheduling regular defrags will ensure that this issue won't affect your servers’ performance.
It’s important to keep the operating systems on your servers updated and regularly install patches as they are released. Tools like Windows Server Update Services (WSUS) can provide a centralized way to deploy updates, but you still need to configure the schedule for when these updates are applied on every server. This is an easy task with servers on a domain, but it’s not so easy otherwise. A centralized solution such as System Center Configuration Manager will ensure that only the updates that you specifically deploy will be installed. This means no more random reboots, which is a pretty big deal when you want to ensure the most possible uptime for your servers.
Windows Disk Cleanup
Over time, servers get full of junk. This happens because a lot of stuff is going on all the time. The server is regularly saving information like IIS logs, Windows Updates, error reports, thumbnails… the list goes on. All these items take up valuable space on your server.
A centralized task solution will be able to monitor the disk utilization of your servers and run tools specifically crafted to delete files that are no longer needed. This will ensure that your servers continue to perform efficiently.
These are only a few examples of items that can be tackled by automation. Literally every single action you perform more than once can be scripted and scheduled; all you need is a bit of imagination. Do you want to know more about how to create and configure automated tasks and reduce the amount of repetitive work you have to do? Please contact us to speak to a Hosting Engineer, or feel free to leave a question in the comments below.