Windows IT Pro is the leading independent community for IT professionals deploying Microsoft Windows server and client applications and technologies.
  
  
  Advanced Search 


June 19, 2003

Scripting Administrative Tasks

RSS
Subscribe to Windows IT Pro | See More Systems Administration Articles Here | Reprints | Or get the Monthly Online Pass—only $5.95 a month!

Every so often, I offer a trick or routine for using batch files that makes a user's or administrator's life easier. I'm always astounded by the reader reaction to these articles: Usually, reader email pours in, asking for more details about how to use batch files and where to find more information about batch files. Having started in computers before the introduction of MS-DOS, and having worked through MD-DOS's permutations, I find throwing batch files together to be second nature.

Windows server administrators often spend a fair amount of time creating logon scripts for users. Windows Script Host (WSH) has been available for several years, and many administrators have learned how to write scripts in VBScript. Despite the obvious advantages of scripting and of using command-line tools in scripts, Windows hasn't given administrators the ability to completely script administrative tasks because many utilities require interaction with the GUI. This deficiency is one of the biggest knocks that Windows servers have taken from critics, particular the critics with UNIX backgrounds. In UNIX, all necessary tools can be scripted, and scripting administrative tasks is part of the UNIX systems administrator's daily routine.

Microsoft finally took heed of this administrative necessity with the release of Windows XP Professional on the client side and Windows Server 2003 on the server side. In these OSs, you can run all the administrative command-line tools from a script. You can call these administrative tools from the command line, from batch files running within the command interpreter, from logon scripts, and from WSH scripts. More than 175 command-line tools are available in the latest versions of Windows, and more than 30 of these tools are new to these OSs. You can find a wealth of information about the tools, including simple tutorials about how to use them in scripts, by launching the Help and Support Center (HSC) and searching for "Command Line Tools" within the HSC search parameters.

Although using the new command-line tools to automate administrative tasks can greatly simplify a systems administrator's life, one major problem exists: All the computers on which you want to run administrative scripts need to be running Windows 2003 or XP. Few administrators have computing environments that are so simple, and spending time automating your administrative tasks for a small percentage of the computers you need to support is hard to justify from both a time and a cost perspective.

Fortunately for systems administrators, third-party software vendors offer a variety of scripting solutions, ranging from enhanced batch languages to complete UNIX-style command shells. Such solutions can give administrators the ability to quickly, securely, and easily build scripts that automate complex or repetitive administrative tasks that would otherwise require direct interaction with every computer for which they're responsible. The scripting enhancements in Windows 2003 and XP don't make these third-party tools obsolete; if anything, the fact that Microsoft has acknowledged the need for improved command-line capabilities validates the intentions of third-party developers. Plus, Windows 2003's and XP's scripting enhancements are brand new, whereas many of the third-party tools have years of development behind them, some reaching back to the days when UNIX was the primary network OS. These vendors have had the opportunity not only to optimize their tools for the Windows environment but also to apply the lessons learned from years of use in other enterprise OSs. Thus, these vendors can provide the Windows systems administrator with well-designed and well-tested tools that can deliver real benefits. In addition, these tools let you create scripts that run across multiple versions of the Windows OSs, and that in many cases don't require specific OS capabilities.

If you haven't looked at the new Windows 2003 and XP command-line tools, sit down and at least examine the information provided within the OS about these tools. If you already understand the value of these tools, it's well past time you began looking at third-party enhancements.


More About High-Resolution Monitors

Regarding last week's column, dozens of readers have written to me asking about the results of my search for a high-resolution monitor. Have no fear: I'll report the finalists I've identified and the choice I make (and the reasons behind it) in a future edition of this column. Given these monitors' prices, I'm not rushing my decision.

End of Article



Reader Comments
Nothing

lurims September 03, 2004


You must be a registered user or online subscriber to comment on this article. Please log on before posting a comment. Are you a new visitor? Register now




Top Viewed ArticlesView all articles
2009 Windows IT Pro Editors' Best and Community Choice Awards

Picking a favorite product from an impressive crowd of competitive offerings is never an easy task, and such was the case with our Editors' Best and Community Choice awards this year. ...

Command Prompt Tricks

One reader shares his tip for setting up the command prompt to reflect a remote path. ...

WinInfo Short Takes: Week of November 23, 2009

An often irreverent look at some of the week's other news, including some post-PDC some soul searching, a Google Chrome OS announcement and a Microsoft response, Windows 7 off to a supposedly strong start, the Jonas Brothers and Xbox 360, and so much more ...


Scripting Whitepapers From Development to Production: Streamlining SharePoint Deployment with DocAve Deployment Manager

Related Events Configuration Manager SP1 and R2 Overview

Don't Miss Windows Server 2008 Virtual Event

Successful SharePoint 2007 Deployment and Administration – Truly Centralizing Your SharePoint Back-End Management

Check out our list of Free Email Newsletters!

Scripting eBooks Keeping Your Business Safe from Attack: Encryption and Certificate Services

Best Practices for Managing Linux and UNIX Servers

Building an Effective Reporting System

Related Scripting Resources Introducing Left-Brain.com, the online IT bookstore
Looking for books, CDs, toolkits, eBooks? Prime your mind at Left-Brain.com

Discover Windows IT Pro eLearning Series!
Clear & detailed technical information and helpful how-to's, all in our trademark no-nonsense format


Windows IT Pro Home Register FAQ for Windows WinInfo News
Europe Edition About Us Contact Us/Customer Service Media Kit Affiliates / Licensing  
SQL Server Magazine Office & SharePoint Pro DevProConnections IT Job Hound
Left-Brain.com Technology Resource Directory asp.netPRO ITTV Windows SuperSite 
 
 Windows IT Pro is a Division of Penton Media Inc.
 © 2009 Penton Media, Inc. Terms of Use | Privacy Statement