2023 Feb 3

Easy Way to Extend the Output in PowerShell

Sometimes it happens, you have a bit more text than expected in the output, and of course, you can format the table/list to include more data, but sometimes it doesn't really work, and you still need to check for the output width to be precise.

Continue reading...

2023 Jan 9

Simple File Search Function

We might need to be able to locate files, and PowerShell might be rather helpful in that regard. Here we also use all the matches where the string is specified between two asterisks, but we can also limit it to whatever we only like.
 

Continue reading...

2023 Jan 8

Get a List of Enabled Users in Group(s)

In case you have an audit, and being asked to provide all the members of the group(s), and have a very specific pattern (like ending with "RW" as a random example), and you are not removing the users from the groups when they leave the company (anything if not everything is possible), you can use the following function (as it is, or add it to your $profile).

Continue reading...

2021 Dec 21

Check Sensitive Groups Membership

In the world of audit and escalated accounts, you will need to have an overview of the privileged groups and members there, this could be a regulator requirement, too. This small script will show how to do this, and have just one file per check with all the groups you need. Of course, it could be applied to any set of groups, no need to limit yourself.

Continue reading...

2021 Dec 19

Checking The Free Space on the Servers

At some point you might want to have the overview of the drives on your Wintel servers, and of course, there are some monitoring tools like Zabbix or SCOM, but in case you don't have them, there is still a room for maneuver. 

Continue reading...

2021 Sep 17

Tips on PowerShell Profile

Extending PowerShell possibilities is a great step beyond the regular usage. For that, we can create the $profile file, which will load every time you start the PowerShell session. You can have a separate profile for each user account, or a generic system one.

Continue reading...

2021 Jun 20

Checking the *Real* Password Expiration Date

If you ever happened to have used ADAC for the users to set up their password policy to be different from the default for your domain, then you might have noticed the net user %username% /domain command will return not the expected value, as it checks the information quite differently. The script below will actually help to determine the real expiry date.

Continue reading...

2021 Jun 13

Remove the User from a Group if They are the Members of Another One

If you need to remove the user from a particular group based on the membership of another, you can do that super easy, barely an inconvenience.

Continue reading...

A Fast Way to Sync All Devices in Intune

This example is used for the cases when you have made some changes to Intune, and want to send the "Sync" signal to all machines in mind. The example is using Windows, as it is the most common OS. You can select any OS you want, just replace Windows with macOS, Android or iOS. Also, you can remove filter at all - that will sync all the devices regardless of the OS.

Continue reading...

Check Users with No Groups by Pattern

Imagine the situation when someone (probably, from Audit) comes to you and asks to provide the list of users (if any) without a particular group (or groups by imaginary pattern). It could happen, so you need to be more or less prepared.

Continue reading...

2021 Jan 4

Copy Files from Git Repository to DFS

You might have a magic opportunity to delegate some stuff to the L1, Junior colleagues etc., also you may need to automate it for yourself. In my current company we are using the on-premise Bitbucket for the VPN repositories, as regardless of the year (2020-2021) you are still expected to have the VPN, and git is a good tool to monitor activities and changes. Also, we are having the DFS servers for people to share their files.

Continue reading...

2020 Sep 28

Creating a Simple Game in Python

Gaming is a great part of a life. Diving into the virtual competition against enemies, puzzles, time is a good way to spend your evening in a cozy environment with a cup of a favorite beverage. Back in 2014 I was keen to learn new stuff, I was younger and more naïve. I could have tried to learn some programming languages ending up with a basic knowledge, zero practice and no real outcome. Python is still pretty good for the sysadmin job, but anyway this post is about the way of having the simple game in your command line.

Continue reading...

UPN Suffix Change for the Required Users

Sometimes you will need to change the UPNs for the users. Either to have the sync with Azure AD or for something else – it's good to be compliant with the 21st century.

Continue reading...

2020 Sep 27

Fresh Start - More to Come (I Guess)

Please read a personal appeal or whatever.

Continue reading...