Trending
  • 7 of the Useful Mac Terminal Commands You Should Know
    7 of the Useful Mac Terminal Commands You Should Know
  • How to Remove a Device From Your iCloud Account Using Your iPhone
    How to Remove a Device From Your iCloud Account Using Your iPhone
  • The Difference Between Intel Core i3, i5, i7 Before Buying Your Next Laptop
    The Difference Between Intel Core i3, i5, i7 Before Buying Your Next Laptop
  • How to Personalize/Customize Your iPad
    How to Personalize/Customize Your iPad
  • How You Can Keep Your WiFi Safe

    How You Can Keep Your WiFi Safe

    Even if having to deal with WiFi security is a real pain for some, it is something that needs to attention. Someone could steal your WiFi and use it for who knows what and cross your fingers that it is not for anything illegal.

    Read more...

  • What You Should Keep in Mind Before Buying a Used Smartphone

    What You Should Keep in Mind Before Buying a Used Smartphone

    As long as the phone works fine and has what you need, who care if it's not this years model. So, you've decided that the best thing you can do is buy a used phone. Before you go phone shopping, there are some things you need to keep in mind before you buy.

    Read more...

  • The Most Effective Ways to Get More Followers on Instagram

    The Most Effective Ways to Get More Followers on Instagram

    Before you give up and think about closing your Instagram account, there are some tips and tricks on how to increase your Instagram followers you should know about. By following these tips,...

    Read more...

  • How to Make a GIF From a Video (Windows, Mac, iOS, Android)

    How to Make a GIF From a Video (Windows, Mac, iOS, Android)

    ver the certain period of time, GIF images have gained so much popularity, and you can see them on the Social Networking websites. In the comments section of a website or your Twitter timeline, GIF is actually an animated image format which is created from different images or videos.

    Read more...

  • How to Take Great Pictures with Your Android Device

    How to Take Great Pictures with Your Android Device

    When was the last time you used a digital camera to take a picture? It's probably been a while, right? Most of us used our smartphone to take a million pictures of our pets or of that beautiful sunset you were lucky enough to see.

    Read more...

  • The Best iPhone 7 Tips and Tricks You're Probably Not Using

    The Best iPhone 7 Tips and Tricks You're Probably Not Using

    iOS offers an endless amount of great features you can enjoy, but you may not be taking advantage of them because you might not even know they exist or are too afraid you'll mess something up by tampering with it.

    Read more...

  • Everything You Sould Know Before Buying an SD Card

    Everything You Sould Know Before Buying an SD Card

    It's almost hard to believe that something so small can cause so many problems, doubts or confusion. For some, how you choose an SD card is of little or no importance while to others it's the most important thing.

    Read more...

How to List User Accounts Using Terminal on Your Mac

How to List User Accounts Using Terminal on Your Mac

4.0/7 rating (2 votes)

User accounts on a Mac can be accessed from the System Preferences panel that you launch using the Apple logo in the top-left corner of your screen. However, sometimes you’ll want to list out all the users on your Mac in a Terminal window. There could be various reasons as to why you want to do this, but if you want to do it, here’s the right way for you.

Terminal does have a command that lets you access the list of the users on your Mac. By executing the command, you’re presenting yourself to all the users that hold an account on your machine. Not only is this account limited to showing regular users, but it’ll also show the system accounts that you normally don’t have access to. Your Mac automatically creates this system accounts for its own use and it doesn’t let you interfere with them.

So, here’s how you can go about finding out all the user accounts on your Mac using a command:

Listing the User Accounts using Terminal on Your Mac

1. Launch Terminal on your Mac. You can either use Spotlight or the Launchpad to find and launch the app.

Listing the User Accounts

2. When Terminal launches, type in the following command into it and hit Enter:

dscl . list /Users

Listing the User Accounts

3. As soon as the command’s executed, you should see all of the users that exist on your system. You’ll notice that there’re a number of accounts in the list that you haven’t created yourself. Those are actually processes and other system stuff.

Listing the User Accounts

If you’d like to only see the actual user accounts as most end-users would, you can exclude the other accounts from showing up in the list using the following command:

dscl . list /Users | grep -v '_'

Listing the User Accounts  

4. You’ll now only see the user accounts on your screen and not any other stuff. You will, however, find some accounts that aren’t yours, but those have been created for some tasks by the OS.

Listing the User Accounts

5. Not only does Terminal let you see all user accounts, but it also shows you other information about those accounts as well. This contains the user’s directories, and so on. 

To access that, enter the following command into Terminal and press Enter.

dscacheutil -q user

Listing the User Accounts 4

6. You now have all the information you want on your Terminal screen.

Listing the User Accounts

So, that’s how you can access the list of all the user accounts on a Mac using a simple command in Terminal.

While you may not always want to use the command only to list users, it’s definitely a great thing to get a list of all the user accounts with a simple command. And as you’ve seen, it lets you see all those hidden accounts that the OS has created on your machine. You would’ve never seen them had you not used the Terminal app.

Terminal also lets you make changes to these user accounts, but that’s out of the scope of this article. It’s possible, though.

Let us know if this helped you reveal all the accounts on your Mac!

Read more like this


Latest

  • How You Can Keep Your WiFi Safe
    How You Can Keep Your WiFi Safe
  • How to Hide Pictures, App Icons and Files on Android
    How to Hide Pictures, App Icons and Files on Android
  • What You Should Keep in Mind Before Buying a Used Smartphone
    What You Should Keep in Mind Before Buying a Used Smartphone
  • 10 Best Backpacks for College Students
    10 Best Backpacks for College Students
  • Top 5+ Best Point and Shoot Digital Camera
    Top 5+ Best Point and Shoot Digital Camera
  • How to Use Face Swap on Snapchat ( Face-Swap Feature )
    How to Use Face Swap on Snapchat ( Face-Swap Feature )

Author

Mahesh Makvana
Mahesh Makvana

Mahesh is a tech enthusiast who loves writing about technology. Mostly, he prefers writing How To posts that help users get the most out of their tech gadgets. While he is not writing a post, he's usually thinking of the next set of posts he could create. You can follow him on Twitter at @maheshhari.

comment

Leave a comment

You are commenting as guest.

Recent Comment

Great article

I run Directory Report as an administrator
That way it can find hidden file
http://www.file-utilities.com

It can...

Allan Man 23. November, 2016 |

This article is best google chorme are install.This extensions are help different email autuomatically introduce to user. This is must...

Tilly Wilson 10. November, 2016 |

Photobucket has been having technical issues for some time and is, in fact, down right now.

Also, you REALLY need a copy editor. Are...

EvenNote 04. November, 2016 |

About Website

OMG!HOWTO is a technology website where we cover the latest from Apple, Facebook, Microsoft and Tips & Tricks. We seek to present fresh news, useful tips, tutorials, applications that the modern technology user will appreciate. OMGHOWTO.COM is powered by Joomla.

0
Shares
0
Shares