Folder Comparison from multiple servers
I need to compare folders from multiple servers which do not have direct connection so i was trying to generate a text file with command dir /b /s >c:\server1.txt and feed them to script to compare....
View ArticleScript to delete non-active profiles
Hey all, I'm trying to cobble together a script that will delete non-active profiles, and here's what I have so far:$userfolders = gci c:\users\ | select-object name $qwinsta = get-rdpsession...
View ArticleServer health check script
I am looking for a powershell script to check the following and copy the output to a text file or html file. Can some one please help with the same? Appreciate all your help1. Check if Windows is...
View ArticleI am running a Script in task scheduler and need powershell to run as admin
I am running a script that I know for a fact works when I run it in an administrator window. When I run it without being elevated it doesn't work. I added this into a task to run everyday at 11:00 but...
View Articlepowershell win32_networkadapterconfiguration -filter WINSPrimaryServer?
If this is the incorrect place to post this question, I appologize in advance and if you could let me know where is a better place to post this question I would greatly apprecicate it.The end goal here...
View ArticlePower Shell help required for Windows Server
Hi, Need powershell script help !! I have 100+ servers, I wanted to findout, How many IP addresses are registered in DNS for respective hostname, I wanted to findout below parameters for each...
View ArticleHow to disable/uncheck IPv6 in network adapter properties
Hi,I need to programmtically disable/uncheck IPv6 during all Windows 7 deployments. Does anyone know where to find this in the registry or is there a Microsoft utility you can can use to achieve...
View Articlevbs script called from a service cannot execute certain commands
We have a service, running as domain admin user on Win Svr 2008 std ed, that must execute vb scripts. The scripts execute, but calls to SETX.exe using Shell.Run fail to set environment variables....
View ArticleHow to delete Windows user profile with PowerShell?
Helo, guys!I need to be able to delete all user's profiles on all workstations in case of emergency. I have read similiar topics, but don't think it's suitable for me, so I need some help.All...
View ArticleUsing get-printer & get-printerdriver together in a script
Hi, Can someone help me find a way wherein I can user both the commands together, because I am getting all the information from get-printer but when it comes to printer driver version , i have to use...
View ArticleAdding printer from print server
Hi All, We are migrating to a new print server, and i am writing a script to detect a users installed printers, change the server name and re add the printers (and also set the default printer). This...
View Articlebulk licence activation, office professional plus for faculty
Hi, to allI was sent here from the office365 community forums.I hope someone can help...I need a way to assign / activate office 365 licences to all the users on a specific domain in our...
View Article[Newbie] Script output
Can anyone help me out to get the output on two rows in excel.for /f "skip=3" %i in ('qfarm /load') do quser /server:%i | find /i /c "Active" && echo %i >> "c:\Temp\server.csv"I can get...
View ArticleListing RemotePowershell Sessions
HI, I'm just getting back into powershell, and just wanted to understand where this script is going wrong. It's do with the arguments in the script, and I was looking for some guidence on how to...
View ArticleUsing Get-ADUser with ValidateScript
Hello, I'm trying to add parameter validation to a function that creates a new user using properties from a model user. Obviously the model user should exist, the new user should not. I can't seem to...
View ArticleSQL stored procedure execution takes 5x as long using PS 3.0
I have a stored procedure that populates some reporting table, does not return any results, and is very expensive. However it completes in 5 minutes when executed using SSMS. When the same stored...
View ArticleHow to obtain just the value of an atribute
Hello,I have a quick question. I am trying to use orchestrator to move a computer object based on its computer. I am going to do this by keeping a SQL db that orchestrator will query and return the...
View ArticleCheck if new computer account is running XP
I need to check if a new computer account created in AD is running XP -- we do not put SCOM agents on clients. I have created a SCOM 2012 R2 monitor that raises an alert when Security Log Event ID 4741...
View ArticleNeed help getting disk partition offset values
I'm currently having an issue getting the individual values for starting offset for each disk partition. For example, using...get-wmiobject -class win32_diskpartition | select-object -expand...
View ArticleNeed a script that Checks to see if a defined service account has admin...
Need a script that checks to see if a defined service account (not current user) has admin privileges on a local server. the account may be nested in other groups that have admin access.
View Article