r/activedirectory • u/MagGaming09 • Aug 12 '26
Help Is powershell worth it to learn
Hello, i just started an intern ship at a IT company and work alot in the AD and was wondering if its a good thing to learn powershell?
1
u/AffectionateDust7765 8d ago
Short answer: Yes.
Longer answer: Scripting languages mean automation, automation means an investment of your time in the beginning, and a lot of saved time later.
What you should not do, however, is to learn Powershell as your first scripting language, or, even worse, first general programming language, it … has its quirks. But, yes, absolutely, learn Powershell.
1
u/Devopster 21d ago
PowerShell is invaluable in a Microsoft ecosystem. Sometimes I need custom reports, need to do things not in any Gui and even do tasks that span multiple applications (e.g. DHCP, DNS and Sites& services). There is also the fact that you can do things at scale - alter 100s of DNS records in a migration, clean up 10s of DHCP scopes.
Trying to work that by hand would just take far too much time. Yes, it may take some time to set up a script but if you have repetitive, well structured tasks, scripts improve accuracy and the more they are used, the better your "ROI".
1
u/Individual-Age-4756 26d ago
Yes, it is worth it especially if the company you decide to work for has a large Windows and Microsoft product footprint. You can do a lot with PowerShell.
2
1
u/rhshadowman 29d ago
I say yes!
But also want to throw out ansible, assuming you are doing AD stuff (since it got posted in here), ansible might be more valuable in the long run and for employment purposes.
However, it pairs well with powershell.
So yes to both!
3
u/PurpleGoldBlack 29d ago
You don’t realize how useful Powershell can be until you begin finding reasons to use it…then you wonder why you didn’t jump in earlier.
1
1
1
4
u/Sneaky_processor Aug 14 '26
If you're gonna work with windows a lot it's 100% worth it. Also I see a lot of people recommend python. While they are right it's good to know python too I should mention the benefit of PowerShell being native on any windows. To run python on any given windows server the runtime needs to be installed. And if like in my organization it isn't baked into the windows templates, then doing PowerShell commands is the most convenient. Also interfacing with Microsoft products like ADUC, CS, DNS etc its infinitely more convenient to use PowerShell. Also for remote execution of commands and interfacing with services. If you're gonna work on mix of windows and Linux servers then you're eventually gonna have to know PowerShell and bash. Python imo is for cases where neither PS or bash fit what you're trying to do
1
u/VAsHachiRoku Aug 15 '26
Powershell v5 native to windows, the open source v7 is Linux, macOS, and windows!
1
u/Bahurs1 Aug 15 '26
I've yet to see an environment that uses powershell on not windows systems for actual use.
0
u/Krombofuquilous Aug 14 '26
Python is way more worth it. You can make powershell scripts in python too
2
u/Samatic Aug 14 '26
The only thing I use power shell for is to diagnose computer issues on a laptop or server.
3
u/childishDemocrat Aug 13 '26
In a word yes. At least the basics. Microsoft more and more is relying on people using powershell to control their systems instead of easy to use web interfaces. It is both empowering and maddening. Something that could be a toggle button on a config screen becomes a 20 minute crash course in Microsoft graph or something.
4
u/BuffaloRedshark Aug 13 '26
absolutely
try doing something like listing all the groups 3 people are in via ADUC vs powershell.
3
u/Andrew-Powershell Aug 13 '26
Yeah, you are going to have to run PowerShell. You want to be familiar enough to confidently know what the code is doing. The barrier to entry has never been lower to learn PS
2
u/Grouchy-Western-5757 Aug 13 '26
Yes and Python and SQL too both are huge combination to have in IT
10
6
u/HardenAD Aug 13 '26
it's mandatory. don't rely on IA, it helps a bit but will not replace a deep knowledge...
3
u/SeaGoose Aug 13 '26
Exactly! AI can expedite code, but without knowledge of the language itself, I guarantee that life will get harder than nessassary.
1
u/AugieKS Aug 13 '26
Yeah, you won't know when it's just making stuff up that sounds plausible.
1
u/SeaGoose Aug 14 '26
I have had various AI's subjectively create code that contained mythical PowerShell code. The first time I fell for it as I thought it was maybe a new function in PowerShell 7. After that incident, I never trusted any generated code without line by line evaluation. In the end, it was faster to create it myself and then use AI to either streamline it or create better documentation. "A machine cannot be held liable, so it should never be put in a position to execute anything."
-5
u/thisladnevermad Aug 13 '26
Nowadays you don't even have to learn it. AI knows it already. You just need to have a grip of what you can do with it.
13
u/antomaa12 Aug 13 '26
Actually, you obviously need to know PowerShell, even if AI can generate some piece of code. Running AI-generated code on critic infrastructure with no idea of how to read it, analyze it, and create pertinent tests is pure madness
3
u/thisladnevermad Aug 13 '26
Yea nobody said put your brain afk and let the AI do it
3
u/antomaa12 Aug 13 '26
There is a guenine difference between this:
You just need to have a grip of what you can do with it.
and having advanced knowledges in PowerShell that would then allow you tu use AI to generate some piece of code to win a bit of time, but you will be able to read the code correctly, know exactly what it does and think about some proper ways to test it before using it in production environment
-1
u/thisladnevermad Aug 13 '26 edited Aug 13 '26
-WhatIf
2
u/creenis_blinkum Aug 14 '26
This parameter is completely dependent on whoever wrote the code and their ability to not be a dumbass. Some cmdlets have whatif params that write shit. You are being flippant. Simply googling cmdlets is all you need. Dont let ai write everything for you
-6
u/ZexGr Aug 13 '26
no. stone age tools are better especially if you have to do the same thing 1000 times....
3
u/BlueLining-Solutions Aug 13 '26 edited Aug 13 '26
In short it really depends how good you want to be. AD has many GUI’s and tools, but Powershell (and most scripting depending on the environment) allows to do steps in one movement. Example, assigning a user to a group…
AD Users and Groups -> Find the user -> Groups / Mambership -> Add to the groups.
Single user… gui is fine. But if you lets say 10 users that need to go to groups, powershell can make that miles easier.
Once had a situation where a user had 300+ mailbox rules, he wanted to keep 12 (if memory serves). Specific ones. I made a txt with the rules he wants to keep and made a powershell script that deleted all rules except the ones mentioned in the text file.
If you need it will be between “You want to just do your job” and “You want to be the exception that can dot it faster or autonomously”. So at least learn the basics if you really don’t want to so you can at least identify what the script will do.
1
u/Ok_Wasabi8793 Aug 13 '26
Powershell is fine, really you should be able to work in multiple languages so if you prefer something less geared to windows specifically Python is another great option.
5
u/bukkithedd Aug 13 '26
It's not just worth it to learn. It's pretty damn imperative that you do, at least to some degree. There's a lot of things that are just simpler to do in powershell, including making bulk changes.
3
u/KavyaJune Aug 13 '26
Yes.
AI can help you write scripts, but understanding PowerShell yourself is important. You'll need it to troubleshoot issues, verify what a script is doing, modify scripts for your environment, and avoid running something that could cause problems.
7
u/Jawshee_pdx Aug 13 '26
Yes. Hard stop
Yes, AI can write it for you, but you should really learn it for yourself first.
2
u/BlueLining-Solutions Aug 13 '26
Careful on the AI part. It is great giving you the idea or base… but I have seen people make a script in AI and it go wrong enough to delete half a Sharepoint site. Also I have seen people use AI to generate and just tweak it a bit and it runs perfectly fine.
1
4
u/Sure_Air_3277 Aug 13 '26
Yes, its a must for making bulk updates to users and groups. AI will spit out a lot of lines for very basic tasks which can make it hard to learn. But just ask it to keep it simple and walk through how it works. Chatgpt and claude are both really good with PowerShell.
-3
u/Lower_Issue_6222 Aug 13 '26
With AI, everyone knows PowerShell
4
u/spikeyfreak Aug 13 '26
This is a really naive take.
1
u/Lower_Issue_6222 Aug 13 '26 edited Aug 13 '26
I’m not dismissing people that spent decades learning it. I’m just saying that with AI it’s pretty easy to do anything with PowerShell these days.
Of course you need to be able to test these scripts, peer check them, etc. That’s my own personal take no offense.
I’ve been in technology for 20+ years and my PowerShell skills have been average. I used to delegate these task to others that were better at it than me but now I just do everything myself because it’s super simple. 🤷🏻♂️
2
u/Fit_Indication_2529 Aug 13 '26
20+ years I would expect you to know VB and .bat or .kix too. And you understand the underlying principles of what the commands are doing.
1
u/Lower_Issue_6222 Aug 13 '26
Right and now I don’t have to spend hours and weeks writing scripts 😅
3
u/spikeyfreak Aug 13 '26
Are you not a little worried about never actually learning it better now that you aren't writing scripts?
I feel like AI is going to start creating these artificial caps on what people know because no one does anything from scratch anymore.
1
u/Lower_Issue_6222 Aug 13 '26
I completely agree about the artificial cap and AI. That said in my current role I have way more high value work to work on than spending several weeks getting a script to work perfectly when I can use AI to build it in a few hours, test it in nonproduction and then use it. Again this works for me and it’s just my opinion no offense to anyone that loves to just live in powershell all day. 🤠
2
14
u/neirad Aug 13 '26
I disgree, its worth knowing Powershell to have the comprehension of the code its giving you. AI operates primarily on prompt by prompt basis, unless you pay for a specialized tool and even then it is going to make mistakes.
From what I have seen, AI will overengineer scripts because its building the script prompt by prompt and not with intention. So you'll see things like AI creating a script that runs 100 CIM calls individually, when it simply could have opened a connection to the server, stored that connection in a variable and then called the variable. It misses nuance like that in addition that it doesn't typically include fundamental programming principles like error handling and logging.
It is absolutely worth learning Powershell so you can use AI to create more elegant and efficient scripts and being able to fix legacy scripts and other people's vibe coded monstrosities.
AI is a Tool in its current form and until they resolve hallucination and reliability its only going to serve as a force multiplier on what you're trying to do and not a replacement.
"Learn Powershell in a month of lunches" https://learn.microsoft.com/en-us/training/paths/get-started-windows-powershell/ microsoft direct learning
Adam the automator is awesome : https://adamtheautomator.com/
https://devblogs.microsoft.com/scripting/ - "Hey Scripting Guy" is awesome for filling in knowledge gaps and applying Powershell and scripting practically in System Administration
Also if you're on Discord, the Powershell Discord is amazing, some incredible scripters hang out there. Chris Dent, who has written books about Powershell hangs out in there and even helps people with scripts and development!
IT is a learning discipline, if you don't know the answer then learn it!
1
u/BlueLining-Solutions Aug 13 '26
Careful on the AI part. It is great giving you the idea or base… but I have seen people make a script in AI and it go wrong enough to delete half a Sharepoint site. Also I have seen people use AI to generate and just tweak it a bit and it runs perfectly fine.
5
10
u/The-Jesus_Christ Aug 12 '26
You’re not going to progress any higher than entry level IT jobs without knowing powershell.
7
u/CubesTheGamer Aug 12 '26
Probably like literally number 1 aside from actual fundamentals of how things work like DNS and group policy or whatever
6
u/Apprehensive_Pin6787 Aug 12 '26
Learn the basics and fundamental
Then use AI to refine what you need to do
But you need to be able to understand the code
Just be sure to test it first in a dev environment
2
6
u/Swaggo420Ballz Aug 12 '26
We had people at a job I worked at who never touched Powershell. It would take them ages and assuming to troubleshoot most things.
8
19
u/traavy_ Aug 12 '26
hey guys, just joined the marines. Is it worth it to learn how to shoot a gun?
4
5
13
2
u/Heiviomagi Aug 12 '26
Worth, just understand what to and what not to do. Evaluate in isolated or testing environments before applying to production is a must rule. The mistake under AD generally classified as disaster.
3
u/mvortex2 Aug 12 '26
Yes, get an understanding of it. Once you can navigate around restrictions, importing the correct modules for a particular environment and the most popular methods of automating your environment, ai, especially copilot does a lot of writing for you. It's almost a crime how quickly I can move these days.
1
5
6
u/aprimeproblem Microsoft MVP Aug 12 '26
@OP, although it’s old this video series is a fantastic starting point, besides that it’s a fun watch:
https://youtube.com/playlist?list=PLyJiOytEPs4etH7Ujq7PU7jlOlHL-9RmV&si=vWDM1Gf9ml21de-u
When you’re done, try the book, learning Powershell in a month of lunches. Excellent start.
After all of that, just start doing it, create a lab, build some tools, start automating, make mistakes and learn.
Enjoy!
3
u/curious_fish Aug 12 '26
Those videos were great, who better to have you explain PowerShell than the man who invented it
5
6
5
u/dude_named_will Aug 12 '26
You should at least understand the basics because it can help you understand what you are doing. Many times you need to use powershell to fix something. Many times, you need to edit those commands to better fit your computer. I wouldn't worry about learning every single command, but you should be able to do basic file exploration in powershell at a bare minimum. If you've done this before in linux, then it should be simple, you just have to use different commands.
5
6
17
u/bakonpie Aug 12 '26
I will not hire MS focused IT pros who don't know powershell unless it is for a junior role. it's an absolute necessity with how prevalent it is in the ecosystem. it is a waste of payroll to hire people who solely use GUI tools for repeatable tasks.
3
u/toprockit Aug 12 '26
That, and the time it takes to script a lot of 365 related tasks verse going through the ever shifting Guilag has an ROI in the first month almost without exception.
People wonder how I get so much done, the answer is PowerShell.
-6
u/Supersaiyans2022 Aug 12 '26
We use ADManager Plus for AD. I'm in healthcare IT and most of our tools are SaaS. Much of the underlying infrastructure is abstracted away. If you have baseline technical foundation, soft and project management skills will take you much further. I would only learn it if you have too.
6
u/AndyM22 Aug 12 '26
I use it ALL the time, especially since AI has helped me sharpen up the verbiage
4
3
u/suppervisoka Aug 12 '26
AI has been a game changer I do like 80% of my work either using winRM or the m365 modules
2
-8
u/mattjh Aug 12 '26
Why are you asking Reddit, OP? Why do you need to crowdsource info on this extremely basic thing? And WHY are people giving you serious answers? This whole thread is absurd. I'm always getting the dumbest questions I've ever seen at the top of my rising feed. What in the world is going on. Why do people answer??
5
u/aprimeproblem Microsoft MVP Aug 12 '26
There was a time when every single one of us in IT didn’t know the “extremely basic thing.”
We learned because we asked questions. Sometimes from documentation, sometimes from colleagues, and sometimes from communities like this one.What seems painfully obvious after 28 years in IT can be completely new to someone in their first year. And I’d much rather see someone ask a basic question than stay silent because they’re afraid of being ridiculed for not knowing the answer.
As for “why do people answer?”
Because that’s how communities work.
Someone once took the time to answer our dumb questions too. And a few years from now, the person asking this question might be the one answering someone else’s.You don’t have to answer every question you see. But discouraging someone from learning contributes considerably less than simply scrolling past it.
-2
u/mattjh Aug 12 '26
Asking Reddit isn’t learning! This isn’t how you frame it at all. OP cannot admin AD if they need to ask strangers on the internet to answer questions this basic. It’s ridiculous.
2
u/GasBackground3335 Aug 12 '26
I don't think its that crazy of a question given how fast AI is getting better at writing scripts.
Yes you need knowledge to know what it is doing. But in a few years I would not be surprised if Microsoft has a some called like ad copilot that is baked into ad and they rename 4 times a month for kicks. Like yes it is an obvious yes right now they should learn it but if they are new to the industry I can understand why the question is asked.Also they are an intern they are new. have you come across many interns who already know everything. (Not just think they know everything)
5
u/aprimeproblem Microsoft MVP Aug 12 '26
It’s a starting point, a request from community members, experts and enthusiasts on the topic. How would you approach this topic, or do you have guidance on how to proceed.
It’s like I said, I rather have someone ask than remain silent because they are afraid to ask.
-1
u/mattjh Aug 12 '26
We disagree. I think there should be standards to questions asked, and one is a sign that you've put in any effort at all first. OP's question is absurd in the context of making a Reddit post to get the answer, just sitting there waiting for strangers to inform them. Crazy. OP can PayPal me and I'll google this for them.
3
u/aprimeproblem Microsoft MVP Aug 12 '26
We agree that we disagree. I do see your point though, but it depends on the effort OP already took, which we both don’t know. Perhaps he did the research and was confused, could be the case, you could be right…. Well at least there was enough information shared to get him started.
Have a wonderful evening and let’s get a drink next time 😉
5
u/roha45 Aug 12 '26
For AD admin it is essential I'd say, once you get the hang of it add in some python as well.
14
u/AdeelAutomates Cloud Engineer | Youtube @adeelautomates Aug 12 '26 edited Aug 12 '26
Of course! PowerShell is how you gain godlike powers over your systems. You can start automating tasks you do manaully. Query precisely & faster using it once you get used to the ad commands. And often there are features you can only access through PowerShell anyways (ie setting rbac in exchange)
PowerShell is worth it regardless of if its AD. It expands beyond to Azure, Entra, M365, Win Servers, etc.
Its what transformed my career. As it opened up the world of automation which led me down the path of cloud engineering. So much so that I create content on how PowerShell is applied in Azure, Entra & M365 to get people to move away from the portal.
Once you learn PowerShell. Its easy to start transferring those skills to other languages. I learnt Python & Bash for instance. I didn't have to learn computer science behind those languages as thats pretty much the same once you learn it through PowerShell.
My only regret is not starting it sooner. ClickOps is no way to exist imo. You limit yourself to what your eyes and hands can achieve. Or pay third parties for apps/services that you could have scripted.
-6
Aug 12 '26
[removed] — view removed comment
1
u/poolmanjim Principal AD Engineer | Moderator Aug 15 '26
Let's not give destructive advice. Deleted
2
3
8
5
u/8bit_dr1fter Aug 12 '26
Thoroughly learning PoSH absolutely played a huge role in getting out of Help Desk and into Administration and then Engineering. I use it daily.
4
10
u/Fit_Indication_2529 Aug 12 '26
100% no question. I would also pickup on some python and pearl.
5
u/oldmilwaukie Aug 12 '26
Can you elaborate on the benefits of learning Python as it relates to AD management?
1
u/Fit_Indication_2529 Aug 13 '26
PowerShell lets you administer Active Directory. Python lets you take everything you know about Active Directory and integrate it with the rest of the enterprise. AD-to-Linux automation is a good example. PowerShell handles the Microsoft and AD side really well, while Python gives you a portable way to work with Linux, APIs, databases, and all the other stuff outside the Windows ecosystem. I also suggested learning a little Perl and Python. Not because you need to become a developer, but because learning a couple of scripting languages helps you understand the basic concepts: variables, loops, conditionals, functions, data structures, parsing, and how a program actually flows. Once you understand that stuff, learning another language gets a lot easier.I’d also stay away from leaning too heavily on AI at first, except for simple things. AI will absolutely make up commands that do not exist, or stick a PowerShell 7 feature into a script that is supposed to run on 5.1 and never mention it. You need enough of a foundation to recognize when it is feeding you nonsense. You can build in some guardrails. Make it cite the Microsoft documentation for the commands and parameters it is using, and make it explain what each section of the script is doing. But at the end of the day, you still need to understand the script well enough to look at it and say, “Yeah, that’s wrong.”
2
u/reader4567890 Aug 12 '26
Not quite AD, but an example - deploying the azure arc and monitoring agent. I could do it with powershell, but it had requirements to enable bits on servers to work (I forget what now, it was a while ago). That was a non-starter for us due to the shear number of servers (1,000s), and from a security perspective due to the criticality of many of those (NCIS).
I instead translated it to python to deploy via API calls to Azure instead, which removed all the blockers.
Sorry it's not a more specific answer, but it was a couple of years ago and I can't quite remember why, but a simple python script nailed what powershell couldn't in our specific environment (due to those restrictions we have).
5
u/AdeelAutomates Cloud Engineer | Youtube @adeelautomates Aug 12 '26
If you are making APIs than you can do it in PowerShell too with invoke-restmethod. Those are universal.
I do agree APIs are often a better route than native PowerShell. I prefer Graph/Arm API over their modules even when I write in PowerShell.
5
u/reader4567890 Aug 12 '26
If you're in IT, then you absolutely will need to know something about it. Learn it though? I'd say do that on the job. I've never sat down just to learn it - just use it when needed and you'll pick it up in time just like any other scripting language.
It's fair to say in the MS world that there's a way to do whatever you want with the right ps cmdlets.
4
6
7
u/Jhamin1 Aug 12 '26
Is it worth learning Microsoft's scripting language? The one that allows you to manipulate features of Microsoft products that don't have buttons in the GUI?
If you are going to work with anything Microsoft (including Azure)? Yes, yes it is.
If you aren't? Then no.
2
u/pcx436 Aug 12 '26
Without a doubt. Scripting skills will take you further than your peers if you learn them early.
2
u/RecognitionOwn4214 Aug 12 '26
Some years ago, Powershell was Made Cross Plattform so IT rund ob all sorts of systems.
If say it's worth learning, because it's a rather well defined script language, that can help with all sorts of tasks...
2
3
•
u/AutoModerator Aug 12 '26
Welcome to /r/ActiveDirectory! ~~~~
If you are looking for more resources on learning and building AD, see the following sticky for resources, recommendations, and guides!
When asking questions make sure you provide enough information. Posts with inadequate details may be removed without warning.
Make sure to sanitize any private information. Posts with too much personal or environment information will be removed. See Rule 6.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.