Home > Apple Silicon, Mac administration, macOS, Rosetta 2, Scripting > Installing Rosetta 2 on Apple Silicon Macs

Installing Rosetta 2 on Apple Silicon Macs

With Apple now officially selling Apple Silicon Macs, there’s a design decision which Apple made with macOS Big Sur that may affect various Mac environments:

At this time, macOS Big Sur does not install Rosetta 2 by default on Apple Silicon Macs.

Rosetta 2 is Apple’s software solution for aiding in the transition from Macs running on Intel processors to Macs running on Apple Silicon processors. It allows most Intel apps to run on Apple Silicon without issues, which provides time for vendors to update their software to a Universal build which can run on both Intel and Apple Silicon.

Without Rosetta 2 installed, Intel apps do not run on Apple Silicon. So for those folks who need Rosetta 2, how to install it? For more details, please see below the jump.

You can install Rosetta 2 on Apple Silicon Macs using the softwareupdate command. To install Rosetta 2, run the following command with root privileges:

/usr/sbin/softwareupdate --install-rosetta

Installing this way will cause an interactive prompt to appear, asking you to agree to the Rosetta 2 license. If you want to perform a non-interactive install, please run the following command with root privileges to install Rosetta 2 and agree to the license in advance:

/usr/sbin/softwareupdate --install-rosetta --agree-to-license

Having the the non-interactive method for installing Rosetta 2 available makes it easier to script the installation process. My colleague Graham Gilbert has written a script for handling this process and discussed it here:

https://grahamgilbert.com/blog/2020/11/13/installing-rosetta-2-on-apple-silicon-macs/

I’ve written a similar script to Graham’s, which is available below and from the following address on GitHub:

https://github.com/rtrouton/rtrouton_scripts/tree/master/rtrouton_scripts/install_rosetta_on_apple_silicon


#!/bin/bash
# Installs Rosetta as needed on Apple Silicon Macs.
exitcode=0
# Determine OS version
# Save current IFS state
OLDIFS=$IFS
IFS='.' read osvers_major osvers_minor osvers_dot_version <<< "$(/usr/bin/sw_vers -productVersion)"
# restore IFS to previous state
IFS=$OLDIFS
# Check to see if the Mac is reporting itself as running macOS 11
if [[ ${osvers_major} -ge 11 ]]; then
# Check to see if the Mac needs Rosetta installed by testing the processor
processor=$(/usr/sbin/sysctl -n machdep.cpu.brand_string | grep -o "Intel")
if [[ -n "$processor" ]]; then
echo "$processor processor installed. No need to install Rosetta."
else
# Check for Rosetta "oahd" process. If not found,
# perform a non-interactive install of Rosetta.
if /usr/bin/pgrep oahd >/dev/null 2>&1; then
echo "Rosetta is already installed and running. Nothing to do."
else
/usr/sbin/softwareupdate –install-rosetta –agree-to-license
if [[ $? -eq 0 ]]; then
echo "Rosetta has been successfully installed."
else
echo "Rosetta installation failed!"
exitcode=1
fi
fi
fi
else
echo "Mac is running macOS $osvers_major.$osvers_minor.$osvers_dot_version."
echo "No need to install Rosetta on this version of macOS."
fi
exit $exitcode

  1. Jano
    November 19, 2020 at 9:49 am

    This is not needed. The first time you run an Intel-compiled app the Mac will prompt you to install Rosetta. Basically it does what your Terminal-command told it to do.

    • November 20, 2020 at 4:44 am

      It is needed, it allows you to install Rosetta ahead of a staff member in your organisation needing the app they’re using. If they run it they would most likely need admin rights, which not all orgs give.

      • Jano
        November 20, 2020 at 8:22 am

        Yeah, I can see it being useful for admins but you could also just launch any Intel-compiled app and use that to get to the prompt to install Rosetta. So no, it’s not needed but some might find using Terminal easier.

        That’s fine but this post makes it sounds like all users have to do this to install Rosetta. Since this post is the second result I get from DuckDuckGo when searching for “installing rosetta 2” I think it could be misleading average users who will land here.

    • J
      December 1, 2020 at 9:41 pm

      The target audience for this blog are administrators who manage large numbers of Apple devices as their profession (such as the author, Rich Trouton). If you are an end user, then this isn’t really directed to you and you are correct that an end user does not need this method (though obviously this method will work for end users as well). However, system administrators who may have hundreds or thousands of Macs potentially spread globally, may very well need a method to automate the process and eliminate the prerequisite of user interaction. So the “need” in this case, is based on the concerns of the audience, not the requirements to enable Rosetta 2.

      • Jano
        December 4, 2020 at 9:33 am

        Look, I get it. An admin for our organisation sent me the link to this article assuming this was the only way to install Rosetta. I’m testing our apps for him on AS.

        To me it wasn’t immediately clear that this blog is aimed at admins so all I’m saying is that non-administrators might land here via search engines and might not realise that this method is only needed for admins but not for average users.

      • Deepak
        April 17, 2021 at 4:23 pm

        I disagree with Jano, I was trying Salesforce data loader to run in M1 but it won’t and it did not ask me to install Rosetta. I had to manually install it and then the app loaded. Thanks to this Article. FYI i am not a admin.

    • callunairis
      August 30, 2021 at 12:07 am

      Disagree with you: I’m not an admin. My mac didn’t prompt me to install Rosetta; thanks to this post I was able to install it manually.

  2. mbinkley
    December 2, 2020 at 6:49 pm

    Any thoughts on how you might be able to package this as a payload-free package to use during setup?

    All of the normal tools I usually use end up compiling the package as an Intel package and require Rosetta to run which defeats the purpose when you are trying to use that package to install Rosetta.

  3. JC
    December 3, 2020 at 10:57 pm

    This worked perfectly with my Jamf server. Great work and always perfect timing with your posts!

  4. MChit
    December 15, 2020 at 7:45 am

    This script worked well with our Jamf cloud instance. The script was deployed as the first payload in a test DEP workflow using DEPNotify. Thank you for working on this!

  5. December 17, 2020 at 4:16 pm

    MChit, any chance you would be willing to help me out? I have been having a lot of issues getting Rosetta 2 installed and ten launching DEP Notify

  6. boni
    December 21, 2020 at 5:43 pm

    any idease how to uninstall Rosetta 2

  7. anwar
    December 30, 2020 at 1:48 am

    Hello I am new to the Mac mini. I recently received the newest version dec. 2020. Upon registration and activation I was offered a Big Sur upgrade. I did the upgrade first before trying anything else. Big Sur upgrade completed and working. Began to try and install and use app / programs. I was prompted to download Rosetta as listed above. I constantly get this error please try again message, no matter how many apps I try. I tried the terminal method. I was able to initiate and accept terms. I then begin download and get error. here is the message.

    Last login: Tue Dec 29 17:16:41 on console
    ~ % /usr/sbin/softwareupdate –install-rosetta
    I have read and agree to the terms of the software license agreement. A list of Apple SLAs may be found here: http://www.apple.com/legal/sla/
    Type A and press return to agree: a
    2020-12-29 17:38:00.995 softwareupdate[771:17454] Package Authoring Error: 001-86594: Package reference com.apple.pkg.RosettaUpdateAuto is missing installKBytes attribute
    Install failed with error: An error has occurred. Please try again later.%

    This is my first day of use and quit frustrating not to be able to use anything because rosetta won’t download.

    can you help?

    Thanks

    • Reece
      January 21, 2021 at 12:01 am

      did you ever get this figured out? Mine is doing the same thing.

      • ed
        June 12, 2021 at 4:59 pm

        same problem here. ever find a solution?

  8. Tchad Rogers
    January 1, 2021 at 3:08 am

    This worked great in our Jamf instance. Our Antivirus is not yet a universal binary, so Rosetta is needed before the AV is installed… we put this script before the AV install, and voilà!

    I did have to change one line:

    –install-rosetta –agree-to-license

    became

    -–install-rosetta -–agree-to-license

    Somewhere along the copy-paste route, the two dashes were converted into one and the script would fail.

    • January 26, 2021 at 8:45 pm

      Thank you! I was trying the script today and had the same thing happen to me. I guess I need to proofread better!

    • William Awuku
      March 2, 2022 at 5:29 pm

      The same thing happened with my deployment, but after changing that line it worked like magic.

  9. Professor
    May 1, 2021 at 7:03 pm

    Is there a way to uninstall

  10. Ari
    June 28, 2021 at 6:38 pm

    Any way to unisitall it? Thanks

  11. July 12, 2021 at 9:38 pm

    Quick heads up. I borrowed this and found that it wouldn’t work on 11.4 machines. I did some digging and have found that com.apple.oahd.plist is included with the OS by default… at least for 11.3.x whatever I got when the last batch arrived. I had to remove the check against this. FWIW.

  12. Peet
    July 28, 2021 at 11:28 am

    As @Chris Hafner says, com.apple.oahd.plist as of macOS 11.4 seems to live here:
    /System/Library/LaunchDaemons/
    I added a kludgy OR condition to line 33 to check that location as well

    • Daniel Ross
      September 22, 2021 at 7:56 pm

      @peet can you share how you did this? I’m still new to scripting and were finding that the script that Rich made is failing on 11.4 -> 11.6

  13. Camilo Cuna
    September 24, 2021 at 8:06 am

    Thank you so mch

  14. malanguisjessamay@gmail.com
    January 23, 2022 at 1:39 am

    hi. I tried copying the code /usr/sbin/softwareupdate –install-rosetta –agree-to-license to my terminal and it says that “Rosetta 2 update is not available”. what should I do next? Thank you.

  15. July 4, 2022 at 12:13 pm

    Getting below error as like

    Script : used above one.

    Script result: By using the agreetolicense option, you are agreeing that you have run this tool with the license only option and have read and agreed to the terms.
    If you do not agree, press CTRL-C and cancel this process immediately.

    Rosetta 2 update is not available
    Rosetta installation failed!

  16. p
    October 14, 2022 at 5:23 pm

    Thanks for this, the normal method did not work for me but this did.

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: