Ask Different is a question and answer site for power users of Apple hardware and software. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I know this has been asked before but none of the answers seems to work in OS X Mountain Lion. I would like to launch a process via SSH and close the terminal without killing the process.

nohup ccl64 -e '(ql:quickload :"file")' & 

Doesn't work. When the terminal is closed, the process dies.

nohup ccl64 -e '(ql:quickload :"file")'

Same here.

I think there must be a way. This is very annoying as it works as a standard in any Linux system, yet Mac OS X refuses to work with any of these combinations.

share|improve this question

migrated from Oct 7 '12 at 6:35

This question came from our site for system and network administrators.

One thing that always works is screen. it seems to be available on Mac OS X per default.

Edit: another tutorial abut screen.

Additionally, here is some quick tips on how to use screen

Open a new 'screen' instance

$ screen

Once, in the screen, you can 'detach' (or close out of it) the screen like this:

ctrl+A and then press D

To resume a screen, you typically do this:

$ screen -x

If you have more than one screen instance, it will tell you their IDs, in which case you can choose which one to resume like this:

$ screen -r <screen id>
share|improve this answer
so over ssh I do screen and then pass the nohup command? with or without the & at the end ? – devnull Oct 7 '12 at 2:57
No need for nohup. Just do screen ccl64... & . Later, if you need to you can reconnect with screen -R to monitor progress. Alternatively, just run screen and type the command in there , you can detach with Ctrl+A D. – chx Oct 7 '12 at 2:58
thanks it is possible to save the screen output in a file after the launch ? – devnull Oct 7 '12 at 3:03
Of course, screen can do everything. You want screen -X hardcopy. See for more. – chx Oct 7 '12 at 6:38

Try screen instead, it should still be part of the default install. Some people even use screen as their default shell so they don't need to worry about nohup at all.

share|improve this answer
could you describe how to run a nohup command with screen? – devnull Oct 7 '12 at 2:57
You use screen instead of nohup, and then detach the screen. Your program will continue to work even if the ssh session ends. – Sven Oct 7 '12 at 2:59
See man screen for details. – Sven Oct 7 '12 at 2:59

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.