GoGreen PC Tune-Up™
Learn More

Insta-Install™
this is how ssl encrypt our websites
MTNCOMP | List View | Table View | myBlog (1786 Entries)
myBlog Home

Blog


Apple Mac OS terminal sudo ineffective if admin password not set

Apple Mac OS

by Mountain Computers Inc., Publication Date: Friday, June 19, 2020

View Count: 1314, Keywords: Mac, OS, terminal, sudo command, not working, Hashtags: #Mac #OS #terminal #sudocommand #notworking



If you are on a Mac computer and need to us the terminal command to remove some files and directories and need the sudo command, you must set an administrative password or know the root password. For an account that is administrative, then if the password is blank, that will not work. You have to set a password on the administrative account for the sudo command to work.
 
For example, I need to remove some files and folders in my home directory, or maybe the remains of a user account that was removed and their home folder did not remove.
 
1. bring up a terminal command
2. you execute the command "sudo rm -rf {foldername}" and press enter
3. you are prompted for the root or administrative account password and don't have one. you press enter and error access denied.
 
The solution; go to settings and users and group and set the account password on the administrative account you are aware of or using. Then retry your command and it works.
 
more to come...

if you found this article helpful, consider contributing $10, 20 an Andrew Jackson or so..to the author. more authors coming soon
FYI we use paypal or patreon, patreon has 3x the transaction fees, so we don't, not yet.

© 2025 myBlog™ v1.1 All rights reserved. We count views as reads, so let's not over think it.