Macs, like any machine, are prone to break down eventually. With continuous use, its efficiency can degrade and the machine may start behaving erratically.
How to Keep a Mac Efficient and Well Maintained—Part 2
This could be a failing physical component such as a logic board, RAM, or an internal fan.
Files may no longer open due to errors in filesystem, search may become slower or irrelevant, apps may start misbehaving and more.
You can minimise both the number and the severity of problems with a maintenance regime.
This tutorial shows you the maintenance steps to follow to keep a Mac efficient and well maintained. Consider these instructions as a set of guidelines to determine your own maintenance regime.
In the first part of the tutorial series, I showed you how to:
- Keep apps up to date
- Remove apps, junk, and unneeded files
In this, the second part of the tutorial series, I’ll show you how to:
- Develop healthy habits while working on the Mac
- Turn off unneeded login items
Develop Healthy Habits While Working
Mac gives you some wonderful tools to help organise your files. When you organise files, you get to your files faster, save time in finding files, and more.
Developing healthy habits while working with a Mac can reduce the need of periodic maintenance. For instance, you can use Automator to clean your desktop or organise the Downloads folder automatically.
Empty the Trash
TheTrashis just another folder residing on the Mac. Moving files or folders to theTrashdoesn’t delete them automatically.
They continue to take up space until you empty theTrashfolder manually usingFinder > Empty Trash.If you delete any files by accident then you can restore them, whilst they’re still located in the Trash folder.
Click theTrashicon on the Dock and scan its contents before you empty them. You can also let the Mac to automatically remove items from Trash that have been there for 30 days. ChooseApple Menu > About This Mac > Storageand clickManage.
In the list on the left, selectRecommendationsand turn onEmpty Trash Automatically.
Restart the Mac
As you keep using a Mac and not turning it off you may find that, over a period of time, the performance slowly degrades. Reasons for this performance degrade could be due to:
- Memory leaks from apps and system processes
- Bugs leading to excess RAM and CPU usage
- Increasing number of virtual memory swap files on hard disk, when the Mac is running low on physical RAM
Anytime you notice that the Mac is not running smoothly, then restart. ClickApple Menuand chooseRestart…
Clean the Desktop and Downloads Folder
Finder brings greater organisational capabilities and has folders for different categories, yet many people keep dozens or hundreds of files on the Desktop for downloaded files, work in progress, and more.
macOS considers every icon on the Desktop as a window …and every window uses certain amount of RAM.
Technically Desktop is yet another folder on the Mac and you can switch off the icon preview for icons inView Optionsbut the point is different.
You can useAutomator and third-party utilitiesto clean up desktop and organise the Downloads folder automatically.
PressCommand-Spaceto launch Spotlight and type in Automator. Create a new Folder Action document to move screenshot from Desktop to a particular folder and scale it to a specific width.
Then, at the top of the window it says,Folder Action receives files and folders added to.
Click where it saysChoose Folderand select the Desktop folder.
On the left side, there is a list of all the available actions. Look forFind Finder Itemsand drag it to the right side of the window to build the workflow.
Change fromAlltoAnyand choose the following parameters
- Namebegins withScreen Shot
- File extensionends withpng
Drag theMove Finder Itemsto the right side of the window. Set theTo:parameter to the folder of your choice.
DragScale Imagesto the right side of the window to conclude the workflow. This workflow will move a screenshot to the designated folder and scale it to 850px.
Using this method you can build folder folder actions to organise the Downloads folder and put files in specific folder.
Unclutter—It’s a paid utility, at $6.99 to help you organise clipboard, files and notes in a single unified panel accessible from menu bar. Swipe downwards with trackpad or scroll wheel to make those panels appear. Clipboard panel shows you the list of clipboard history. Files panel shows you the list of files, drag-and drop files into it without cluttering desktop. Notes panel lets type in quick note for safe keeping.
Hazel—It’s a paid utility, at $32, to monitor folders on a Mac for events that you define—a file you add or modify and initiates actions based on the rules you set, such as moving or renaming a file, adding a label and more. If you’ve just started using Hazel, then we have a number oftutorials on Hazelon ThemeKeeper Tuts+.
Turn Off Login Items
Login items are apps, documents, shared network volumes or other items you wish to automatically open when you start a Mac.
When you install an app, it might ask your permission or offer an optionOpen at Login.Login items removes the friction as it launch your favourite items automatically, but they also make your Mac startup slow, and this is more pronounced with a mechanical hard drive than it is a solid state drive.
Open theUsers & Groupspane of System Preferences. Select the user account from the left sidebar and click theLogin Itemstab. You’ll see the list of items that open every time you log in, and it varies for each individual user account.
To add the item, drag and drop them into the list or click theplus symbolicon to select an item using the file browser.
Click theminus symbolicon to remove an item from the startup or check theHidebox to make the application hidden in the foreground—the item will minimise into the dock.
Although this is a simple way to remove login items, it only does half a job and the reality is much more complicated.
launchd runs other processes in response to condition—on startup, on a fixed schedule or if a certain event occurs. Launchd learns what do by reading .plist files in these locations
/Library/LaunchDaemons/for installed applications
/System/Library/LaunchDaemonsfor macOS native processes
/Library/LaunchAgents/for all users
~/Library/LaunchAgents/for a specific user
/System/Library/LaunchAgents/for macOS only
Items in LaunchDaemons load when the Mac startup and run as the root user. They run in the background without requiring user input and affects the whole system. For exampleScripts for performing maintenance tasks, cupsdfor printing and bluedfor interacting with Bluetooth.
Items in LaunchAgents load when any or particular user logs in and run as that user. They access the graphical user interface and display information which may be useful to you. For example—A calendar app monitors the user calendar and can launch itself when certain events occurs.
In many cases, those items run constantly in the background, sometimes they run at scheduled intervals, and sometimes they run as needed. For instance—a launchd item associated with Time Machine tells it to run once an hour. Until then, the backupd process use no CPU or RAM but when it runs the process can use both.
Like this, you may have some items that you know you don’t need anymore. Perhaps some items get left behind predominantly apps you no longer use or have even uninstalled. You can safely delete those .plist files. Always make a backup before deleting anything. Every item removed from these folders may not make a huge difference in startup, but every little bit helps.
Note, don’t delete any items from System LaunchAgents or LaunchDaemons folders. They can make the Mac unstable or lead to system crashes. It usually begins with
You can monitor these folders automatically withFolder Actions. It link applescripts to folders on the system so if they change, then scripts will run to notify you.
Open theAppleScript Editorapp. ClickPreferences…and checkGeneral > Show script menu in menu bar.
Click theScript Menuand chooseFolder Actions > Enable Folder Actions. Then from the same submenu chooseAttach Script to Folder.
A dialog box will pop-up. Chooseadd – new item alert option
ClickOKand file browser window will open.
username/Library/LaunchAgentsfolder and click theOpenbutton.
Add other LaunchDaemon and LaunchAgents folders wherein you want to apply the action. Now whenever any .plist file gets added to these folders, you will see an alert prompt in the Finder.
In this second tutorial, I’ve shown you some of the ways to maintain a Mac. It’s not necessary to follow all the steps. Consider these instructions as a starting point to make your own maintenance regimen. In the next part of the tutorial series I’ll continue to guide you to make a Mac efficient and well maintained.