(I originally posted this on apple.stackexchange but then I found this one which is probably a better place)

I have a big problem. I've freshly installed mac os and was setting up my terminal. I installed iTerm, zsh and oh-my-zsh (following this tutorial, basically: https://medium.com/ayuth/iterm2-zsh-oh-my-zsh-the-most-power-full-of-terminal-on-macos-bdb2823fb04c)

After installing oh-my-zsh, I got this error message (this is just a random question showing that same error message):


I remember that the fix to this was running the suggested command (I've done this a few years ago):

compaudit | xargs chmod g-w,o-w

I think that was the last thing I did. Now every time I start a terminal (either Mac OS' Terminal or iTerm, doesn't matter) it gets stuck at "login" with a blank screen. I don't get any input prompt.

Even worse, I can't even shut down the mac anymore. When I click on shut down or restart, every app is closed and I see my wallpaper and nothing happens. I have to kill it via the power button.

After restarting, the terminal works perfectly again until I close it with CMD-q. Once I reopen it, it's stuck again at "login".

I've looked everywhere and can't find a solution.

I've seen this question (https://apple.stackexchange.com/questions/267668/terminal-login-hangs) but it didn't help. I tried almost everything proposed there.

I would greatly appreciate any help or thoughts on this.

Also, it works when I boot into safe mode. There, everything is fine.

2 Answers 2


Without being able to reproduce your issue, I cannot assert that this will fix it, but I'll put this out as something to try.

I suggest you try making the following configuration modification to iTerm2:

  • Go to Preferences, then the Profiles tab at the top, then the General sub-tab
  • Select your profile on the left, likely Default
  • On the right, find the Command drop-down; it likely currently says "Login Shell"
  • Change the Command to "Command"
  • Enter the command /bin/zsh --login

With that configuration in place, close iTerm2 and then start it again. Does that yield a working environment? If not, do you see any error messages?

If that doesn't help, then I suggest you rename ~/.zshrc to something else (there's some way to get Finder to show dot files, but I don't remember how off the top of my head). Then try again.

If none of the above helps, you might try switching your shell to bash long enough to debug the problem. You'd follow the steps above, but change /bin/zsh --login to /bin/bash --login, then restart iTerm2.

  • Thanks for the idea. Unfortunately, it didn't change anything (the window's title changed from login to zsh but that's it). renaming the .zshrc also didn't work, sadly Jun 27, 2020 at 16:40
  • 1
    @Quantm I added another suggestion on the end, give that a try and see if it helps at all. Jun 27, 2020 at 17:46
  • Oh okay, now it's starting properly with the text "The default interactive shell is now zsh. To update your account to use zsh, please run chsh -s /bin/zsh". This is a progress :D Thanks. Do you know how I now figure out what's causing the problem? Or what does the /bin/zsh/ --login command exactly do? Jun 27, 2020 at 18:01
  • @Quantm Can once you get in with bash, can you manually run zsh? Jun 27, 2020 at 20:49
  • Seems like it. Typing in zsh and pressing enter does work. I just get another prompt, it's not getting stuck. Jun 27, 2020 at 20:59

The problem is caused by iTerm having problems with the first beta version of Mac OS Big Sur. A specific setting causes the problems I've experienced. See https://gitlab.com/gnachman/iterm2/-/issues/8965 for details.

Until fixed, the workaround is this (taken from the GitLab issue):

Workaround: Disabling Enable session restoration under Preferences > Advanced > Session resolves prevents the hang ups, albeit with the obvious loss of functionality.

Note: A computer restart may be required before this change takes effect.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .