Tuesday, November 22, 2011

NET LOCALGROUP To Find Group Members from All Local Groups

For those like myself who are working with Windows 2000 servers, there aren't many choices when it comes to extracting local user and group information.  There is no DS commands and if you're only using a member server then there's no AD-related tools either.  As such, I manipulated the FOR and NET LOCALGROUP commands to create an output file which I can feed into a text cleaning program like PowerShell.  Use this command (from CMD.EXE) to create a file with all local groups and members thereof:

c:>FOR /F "delims=*" %X IN ('NET LOCALGROUP') DO NET LOCALGROUP %X >>GROUPLIST.TXT

The NET command in the parentheses produces a list of all local groups on the server.  The FOR command grabs each group, strips the * from the front of the group name output, and processes it as a variable in another NET LOCALGROUP command.  The result is added to a GROUPLIST.TXT file.  If you accidentally use one > then only one list, the last processed list, will be in your file.  The double > allows the file to receive additions without overwriting the existing data.

OWSADM Reference Spreadsheet

It was a big struggle to find a document that completely overviews OWSADM.EXE  but I found one.  Parts of it are in French but it's worth it's (virtual) weight in gold as it gives all arguments and explanations thereof.  I'm going to place keywords in this blog post so those searching for this document will be able to find it.  Here goes the keywords:





AccountTracking, AllowExecutableScripts, Authoring, CacheMaxDocMeta, CacheMaxImage, CacheMaxInclude, CacheMaxIncludeSize, CacheMinDocMeta, CheckRolesConfig, CheckUserAccess, CompletionChar, ComplexPasswords, DatabaseServer, DBCacheAgingInSeconds, DBCacheListsMax, DBCacheProjectsMax, DBCacheUserInfoMax, Debug, DisableAutoImgSizeExts, DisableMetaTagStore, DiscussionsExpiry, DontAutoRestartTimer, EnableDiscussions, EnableNotifications, EnableRulesScript, EnableVTIDebug, FolderSubscriptions, GlobalRightsMask, ImageMapFormat, ImageMapURLPrefix, Job-doc-events, ListLockLatency, ListSystemDSNs, LocalDiscussionsOnly, LocalNTAccountsOnly, LogFileFormat, LogFileLocation. Logging, LogInitialSourceControlErrors, LogRollover, MailCharSet, MailEncoding, MailReplyTo, MailSender, MaxFormContentLength, MaxThreadsCount, MaxUploadContentLength, MinThreadsCount, NewItemDisplayCutoff, NoAbsoluteFileResults, NoClientImageMaps, NoExecutableCgiUpload, NoIndexServer, NoMachineGroups, NoMarkScriptable, NoRolesSupport, NoSaveResultsPipeTo, NoSaveResultsToAbsoluteFile, PreserveTagCase, PrivateBrowsable, PrivateDirUMask , PublishMetainfoKeys, ReformatHtml, RemoveAnonymousAuthoring, RepairDB, RequestQueueSize, RequireSSL, RestrictAccountVisibility , RestrictIISUsersAndGroups, RunTimeFileExtensions, ScriptLanguage, SendMailCommand, SMTPHost, TextMemory, ThreadTimeout, TightenSecurity, UpperCaseTags, UsageAnalysisLogExpiry, UsageFullDaysOnly , UsageSendMailTo, UsageServerURLs, ValidateServicesCnf, WECCtlFlags