Feeds:
Posts
Comments

Archive for July, 2018

by Tom Nelson

The Mac, and for that matter most computing platforms, are just chock full of daemons. Daemons, not to be confused with demons, are usually small programs that run in the background with no direct interaction with the computer user. They are often used to implement or help provide a service that operating systems or applications need.

The word daemon comes from an ancient Greek belief, and is used to describe a supernatural being that works on tasks between the gods and man. If we replace man with computer user, and gods with the operating system or applications, we get a reasonable idea of what all these Mac daemons are doing: performing repetitive tasks that provide a service to the operating system, an app, or the user.

Activity Monitor and Daemons
Daemons have no visible interface; they run in the background and are usually independent of other apps and programs. That makes them hard for the user to directly interact with, or even know they’re present. But without them, your Mac would likely grind to a halt or freeze up, possibly without even displaying the usual spinning beach ball of doom.

For the most part, daemons should be left alone; they’re perfectly happy performing their assigned tasks. But if you’re curious, you can use Activity Monitor, an app included with the Mac, to see how the various daemons, and other programs that are running, are making use of your Mac’s resources.

In this example, we’re going to use Activity Monitor to look at what two common Mac daemons are up to: “cfprefsd” and “cloudd.” We chose these two daemons because there have been a few questions floating around the Internet about what they do, as well as questions about these daemons using excessive resources.

You may notice that our two daemons have names that end with a “d.” This is a developer convention, where all daemons’ names should end with a “d.” Just as important, the rest of the daemon name should loosely describe its function. If we apply this developer logic to our two example daemons we come up with:

cfprefsd: A background process (a daemon because of the d at the end of the name) having something to do with cfprefs. Scratching our heads a bit, we can guess that this daemon has something to do with preferences, and if we knew a bit more about Mac development, we could guess the cf stood for Core Foundation.

Using the “man” command in Terminal allows you to see a description of what the daemon’s function is. [Press the “q” key to quit from the man page.] Screen shot © Coyote Moon, Inc.

Actually, we cheated a bit and used the Terminal app to tell us what cfprefsd was. You can use this trick with most of the daemons that are spawned by the operating system to discover what function they serve.

Launch Terminal, located at /Applications/Utilities, and enter the following at the Terminal prompt:

man cfprefsd

Terminal will tell us that, “cfprefsd provides preference services for the CFPreferences and NSUserDefaults APIs.” If we wanted to find out more, we could look up CFPreferences and NSUserDefaults in Apple Developer documentation. Essentially, cfprefsd helps an app or the system to read or write to preference files. When you open an app and change one of its preferences, it’s likely that cfprefsd is the daemon being asked to make the changes to the app’s preference file.

cloudd: A daemon having something to do with macOS cloud services. A little more investigating using Terminal and the technique we outlined above tells us that this is the daemon used by CloudKit, a developer’s API used to transfer data between an app and Apple’s iCloud service.

To check on this daemon’s activity, launch Activity Monitor, located at /Applications/Utilities.

When the Activity Monitor window opens, we’re going to be interested in the resources each daemon is making use of.

In the Activity Monitor window, select the CPU button in the toolbar.

You’ll see a long list of processes running on your Mac. You may notice a few daemons, processes whose names end with d, present in the list. But you probably won’t see cfprefsd or cloudd unless you scroll around a bit to find them. An easy way to see each daemon is to enter one of their names in the Search field in the top right corner of the Activity Monitor window.

For this example, enter cfprefsd in the search field.

Activity Monitor will list any matching process names that are running. You may see multiple daemons with the same name, indicating that multiple users (system, user, or other apps and processes) are making use of the daemon. In my case, I have three copies of the cfprefsd daemon running; one that my logged-in user is using, one the root user is using, and one that locationd (another daemon) is using.

Use the Activity Monitor search field to isolate the daemon you are looking for. Screen shot © Coyote Moon, Inc.

The most important columns in Activity Monitor to examine are the %CPU and Threads columns. In this example, there is 0 CPU being used by any of the cfprefsd daemons, and only two threads in use.

If the %CPU or Threads count were high, and stayed high for a long period, that could indicate a problem with the daemon, or more likely, the app or process that is using it.

Select the Memory button in the Activity Monitor window.

Daemons generally do not use a great deal of memory for long periods of time. They can certainly need memory resources while actively performing their tasks, but usually for short durations. If you see a large amount of memory in use by a daemon, and it stays that way for a long period of time, you may have an issue with the app or process that is using the daemon.

Clear Activity Monitor’s search field to see the full list of active processes. Or, you can enter the name cloudd to view the resources being used to support iCloud.

Read more on Rocket Yard, The MacSales.com Blog

Advertisements

Read Full Post »

by Tom Nelson

Disk Utility, the macOS Swiss Army knife for working with disks and storage volumes, may have a few blades missing, especially when it comes to working with unformatted drives and unused space on a disk or storage volume.

In versions of Disk Utility that came with OS X Yosemite and earlier, you could enable hidden debug modes in the Disk Utility app that allowed you to see and interact with all the space on a disk, including hidden elements, such as the Recovery volume or the secret EFI partitions.

In this Rocket Yard article, we’re going to look at how to enable Disk Utility to view and work with the types of disk spaces you’re likely to encounter, including:

We’ll also demonstrate how to use Terminal to access the remaining hidden disk structures that Disk Utility can’t view directly, including:

  • Recovery volumes
  • EFI volumes
  • Preboot and Boot volumes

Selecting the Initialize button will open Disk Utility, but the disk may not show up if the apps view settings are in the default settings. Screen shot © Coyote Moon, Inc.

Using Disk Utility to Access All Devices
Disk Utility is configured by default to only show formatted volumes. This makes using Disk Utility with existing volumes an easy task since there are only a few, and sometimes only one, volumes displayed, cutting down on what could be an overwhelming list of disks, containers, volumes, RAID slices, etc.

The disadvantage, however, is that it can make it difficult to work with new unformatted disks you may be using for the first time. This includes working with unformatted drives as well as unformatted USB flash drives.

Tip: When we speak of unformatted drives, we’re including any disk that uses a format that your Mac can’t natively work with.

Disk Utility lets you pick which display mode to work in: Volumes only, All Devices, or only a selected drive. You can switch between them at any time, and Disk Utility will update the display immediately; no need to close and reopen the Disk Utility app or restart your Mac.

Show All Devices
This setting will display all storage devices connected directly to your Mac. In addition to each device being displayed, a hierarchical listing will show how each device is organized, i.e., how many containers, partitions, or volumes each device contains. Absent from the hierarchical view will be any of the items Apple has decided to hide from the end user, such as EFI volumes and Recovery volumes.

When Disk Utility’s view option is set to Show All Devices even unformatted devices will be present in the sidebar, such as the highlighted USB flash drive that needs to be formatted. Screen shot © Coyote Moon, Inc.

From the Disk Utility toolbar, click the View button, and then select the Show All Devices item from the dropdown menu. You can also select Show All Devices from Disk Utility’s View menu.

The Sidebar will change to display all locally connected devices, presented in a hierarchical view starting with the physical device, than any containers and volumes the device may have been partitioned into.

Hide the Sidebar
For the ultimate in simplicity, you can choose to hide the sidebar and remove any listings of devices or volumes from view.

From the Disk Utility toolbar, click the View button and select the Hide Sidebar item in the dropdown menu. You can also select Hide Sidebar from Disk Utility’s View menu.

The sidebar will close, and the last selected item in the sidebar will become the only item listed in the Disk Utility window.

Read more on Rocket Yard, The MacSales.com Blog

Read Full Post »

by Tom Nelson

In a bit of a surprise move, Apple unveiled new 13-inch and 15-inch MacBook Pros on Thursday, July 12. The surprising bit is the hush-hush update occurring just over a month after the annual WWDC event, where new products aimed at developers and pro users are usually revealed. This has us wondering why the new 2018 MacBook Pros weren’t part of the WWDC keynote event.

While they didn’t make the keynote, they do pack quite a wallop over earlier models of the MacBook Pro, especially the 15-inch model, which we’ll look at in detail here.

15-inch MacBook Pro (2018)
Before we get too far ahead of ourselves, I want to point out that this isn’t an in-depth review of the 2018 15-inch MacBook Pro. Instead, we’re looking at the specs and how they compare, and what kind of improvements and changes the new MacBook Pro models bring.

First off, the 2018 MacBook Pro isn’t a typical speed bump update. Instead, it brings new features and benefits to those lucky enough to be upgrading at this time. Instead of just dropping in a slightly faster processor, or perhaps a different battery, Apple added a number of new features and capabilities.

Eighth-generation Intel Core i7 and i9 Processors
The 15-inch MacBook Pro leaps from quad-core i7 processors to new six-core i7 and i9 Intel processors in the Coffee Lake family. The Coffee Lake processors have a good deal going for them beyond just two extra cores. Both the i7 and i9 processors support hyper-threading, allowing two threads to run concurrently on each core for a total of 12 active threads. Level 3 caches have also been increased to 9 MB for i7-equipped MacBook Pros, and 12 MB for i9-equipped MacBook Pros.

Eighth generation Intel Core i5, i7, and i9 processors used in the new MacBook Pro product family. Image courtesy of Intel.

The increase in level 3 caches should speed up overall performance, especially when instructions or data are being shared between cores.

The Coffee Lake processor equipped MacBook Pros are offered in speeds of:

  • i7: 2.2 GHz with Turbo Boost speed of 4.1 GHz
  • I7: 2.6 GHz with Turbo Boost speed of 4.3 GHz
  • i9: 2.9 GHz processor with Turbo Boost speed of 4.8 GHz

Sharp-eyed readers may notice that the 2017 models of the 15-inch MacBook Pro had slightly faster base processor speeds, clocking in at 2.8 GHz and 2.9 GHz. But the earlier generation i7 Kaby Lake processors had smaller level 3 caches, two fewer cores, and slower memory architecture than what is present in the new Coffee Lake models.

With the processor and memory architecture upgrades in the new 2018 MacBook Pro, Apple claims a 70 percent increase in performance. We haven’t been able to put the new MacBook Pros through any benchmarks, but a quick perusal of the GeekBench Benchmarks shows an i9-equipped 2018 MacBook Pro with a 5289 Single-Core score and a 22201 Multi-Core score. Compared to a 2017 2.9 Ghz i7 model with a Multi-Core score of 15252, that works out to just a bit more than a 68.69 percent improvement, at least in artificial benchmarks. Real-world usage will be quite a bit different, but the performance increases in the benchmarks are impressive.

Read more on Rocket Yard, The MacSales.com Blog

Read Full Post »

by Tom Nelson

You may not have heard of rsync; it’s a file transfer and synchronization program that’s often used to create elaborate and complex backup systems.

Written for Unix operating systems, rsync is included with the Mac and can be accessed directly from Terminal, or used within a number of scripting languages.

The rsync program has a number of features that make it a good candidate for building local, as well as remote, backup, archiving, and synchronization systems. It can also be used for basic file copying, and for maintaining file synchronization between one or more folders, either locally or with a remote system (think cloud-based storage, as an example).

In this Rocket Yard Guide, we’re going to concentrate on using rsync locally. If you wish to use rsync with a remote system, you’ll need to ensure that both the local system and the remote system have rsync installed.

If you’re looking for a copy of rsync to install on a system other than a Mac, or you’re just interested in discovering more about this versatile app, you can check out the rsync website.

Before we get into details about using rsync on the Mac, a note about versions. The version of rsync that’s distributed with the Mac tends to lag behind the current version available on the rsync website. The Mac version has been at 2.6.9 for a number of years, while the current version is at 3.1.3 (as of January, 2018). You should have no problems using the older Mac version with remote platforms that have one of the newer versions installed, but going the other direction could have unexpected results. Always check version compatibility when using rsync with remote systems.

Using Rsync
The Terminal app is used to invoke rsync and its various commands. If you’re new to using the Terminal app, check out the Rocket Yard series Tech 101: Introduction to the Mac’s Terminal App.

Rsync uses a simple structure for issuing commands:

rsync -options theSourceDirectory theDestinationDirectory
While the number of options can get long, the format is always the same; the rsync command followed by any optional switches, then the source directory followed by the destination directory.

The rsync -r command copied all the files on my Desktop to my USB flash drive named DocsBackup. Notice that the time stamp on all the copied files is set to the current date. Screen shot © Coyote Moon, Inc.

Let’s look at a basic rsync command that will copy a directory and all sub-directories it may contain. To tell rsync we want all the files and folders, including everything in subdirectories, we include the -r option. In the Terminal app, enter:

rsync -r /Users/tnelson/Desktop /Volumes/DocsBackup

(Replace tnelson with your user name, and DocsBackup with your desired target for the copy.)

In this example, my messy Desktop folderand its contents will be copied to a USB flash drivenamed DocsBackup. After the command is executed by hitting the return or enter key, the DocsBackup flash drive will have a new folder named Desktop, with all of my Desktop content.

If you want to copy only the contents of the Desktop, and not the parent folder named Desktop, you would add a forward slash after the directory named Desktop, like this:

rsync -r /Users/tnelson/Desktop/ /Volumes/DocsBackup

Read more on Rocket Yard, The MacSales.com Blog

Read Full Post »

by Tom Nelson

With the release of macOS Mojave Public Beta, we went hunting for features that might be hiding amongst all the changes to the OS. What we found were some nifty capabilities hiding, for the most part, in plain sight.

Even more features are expected to show up over time as more users work with the macOS Mojave beta, but for now, here are our top 6 hidden features of macOS Mojave.

Oh, and one quick note. Since Mojave is still in beta at the time of the original publication of this article, some of the features may have slightly changed or even be missing once the full release of Mojave sees the light of day later this fall. When the fall release occurs, we’ll check to see if any of the features need to be updated.

Recent Apps in Dock
The Dock gets a new organizational tool; it can show three of the most recent apps you’ve used in a special area of the Dock. This new feature is located after the Apps section of the Dock, and before the Documents and Trash section of the Dock.

A new section of the Dock is reserved for displaying up to three recently used apps. Screen shot © Coyote Moon, Inc.

If this seems similar to the Recent Applications Stack that you can create in the Dock, it is, but with a few differences. First, the recent apps aren’t displayed in a stack but as individual icons in the Dock. Second, only apps that don’t already have a home in the Dock are displayed. This prevents duplicate apps from showing up in your Dock.

The recent apps section of the Dock has very basic controls you can set:

Launch System Preferences by clicking its icon in the Dock, or by selecting System Preferences from the Apple menu.

Select the Dock preference pane.

Place a checkmark in the box labeled, “Show recent applications in Dock to enable the feature or remove the checkmark to turn off the feature and reclaim the Dock space.”

The Dock preference pane includes a checkbox to enable or disable the option to Show recent applications in DockScreen shot © Coyote Moon, Inc.

Currently, the recent apps Dock section is limited to three apps; it would be nice to have the ability to set how many can be seen.

Read more on Rocket Yard, The MacSales.com Blog

Read Full Post »