Go Back   The macosxhints Forums > OS X Help Requests > System



Reply
 
Thread Tools Rate Thread Display Modes
Old 04-12-2012, 11:23 AM   #1
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
NOT having applications re-launch at start?

Hi,

Coming up to a year on Lion soon. Has anyone developed a way to NOT have applications re-launch upon startup after the system crashes, is rebooted hard, etc.?

Looking for any easy way to "permanently" prevent applications from launching on startup other than having to manually close everything down in some kind of orderly fashion first (for example, when I want to reboot, I want to reboot NOW - sometimes I'll just take out the battery for instant shut-down - and I don't want to wait for a bunch of crap I'm not even going to use to re-launch).

Just looking for a solution - not a bunch of suggestions that I adapt my way of working to what Apple thinks I should be doing.

Tia,
oa
onceagain is offline   Reply With Quote
Old 04-12-2012, 12:51 PM   #2
DeltaMac
League Commissioner
 
Join Date: Jan 2002
Posts: 8,523
Hoo Boy!
I thought you were asking a serious question, until you got here...

Quote:
Originally Posted by onceagain
...for example, when I want to reboot, I want to reboot NOW - sometimes I'll just take out the battery for instant shut-down - and I don't want to wait for a bunch of crap I'm not even going to use to re-launch).
...

all bets are off when you force your computer off in some response to an emergency situation... Your Mac, with Lion, will always try to resume to that last working state - not as some lame attempt to annoy you - but to give you the opportunity to properly close out those apps. And, that next reboot will take longer for other reasons - a check of the hard drive for major errors, which Lion will attempt to repair.
Pulling the battery as a routine "shut it off now", is just asking for trouble - and not a suitable option "because you don't want to wait".
DeltaMac is offline   Reply With Quote
Old 04-12-2012, 04:53 PM   #3
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by DeltaMac
Pulling the battery as a routine "shut it off now", is just asking for trouble - and not a suitable option "because you don't want to wait".

Unfortunately, with my current MBP, I can't just pull the battery (oh, how I miss my 12" Powerbook!). However, I can simulate it by using the power manager reset sequence to instantly turn the machine off.

The appeal of an SSD drive for "instant on" is really limited if it means you have to wait for a bunch of apps to "re-open" just so you can close them and their stupid auto-opening windows (I'm looking at you, Microsoft) back down so you can then finally get some work done.

Again, for me, the WHOLE POINT of rebooting is to, relatively instantly, close down all open applications. Lion has removed that really useful feature.......because Apple has decided thats how it wants people to work.
onceagain is offline   Reply With Quote
Old 04-12-2012, 06:12 PM   #4
DeltaMac
League Commissioner
 
Join Date: Jan 2002
Posts: 8,523
My point was that you always risk damage to your system files when you force the system off like that.
There's various methods that you can use that work _with_ the system, without having to fight with it each time you force a restart...
Here's how I work: System Preferences/General pane: uncheck "Restore windows when quitting and re-opening apps"
If I want to partly reset the system (including a quick quit of all open apps), simply press Shift-Command-Q, which gets you a logout dialog, so uncheck "Reopen windows when logging back in", then just press Enter, and you're logged out in a few seconds. Log back in, and you're back, no apps open.
Maybe you can try that - it may work well for you, too...
DeltaMac is offline   Reply With Quote
Old 04-12-2012, 06:19 PM   #5
NaOH
Hall of Famer
 
Join Date: Dec 2007
Posts: 3,845
As long as System Preferences > Keyboard > Keyboard Shortcuts is set to enable keyboard access for All Controls, the following method takes about 1 second, maybe 1.25 if the user moves slowly:
  1. Press the power button (or Control-Eject) to initiate the Shutdown prompt.
  2. Press the Space Bar to disable the option for re-opening applications.
  3. Press R to Restart or Return to Shutdown.
NaOH is offline   Reply With Quote
Old 04-12-2012, 06:38 PM   #6
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by DeltaMac
Here's how I work: System Preferences/General pane: uncheck "Restore windows when quitting and re-opening apps"

Yeah, that doesn't work for me - all the crap re-opens itself anyway. But thanks.

As for system file damage - I'll happily accept that risk for the sake of saving myself time. Sort of like risking a speeding ticket for the same reason.
onceagain is offline   Reply With Quote
Old 04-12-2012, 06:40 PM   #7
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by NaOH
As long as System Preferences > Keyboard > Keyboard Shortcuts is set to enable keyboard access for All Controls, the following method.....

But you still have to wait for stuff to quit. That's no better than having to wait for stuff to launch.

All I want is a simple, reliable way of returning to the pre-Lion behaviour - an option for the system to simply not auto-launch previously open stuff. But it sounds like no one has developed that feature yet, is that correct?
onceagain is offline   Reply With Quote
Old 04-12-2012, 06:47 PM   #8
NaOH
Hall of Famer
 
Join Date: Dec 2007
Posts: 3,845
Quote:
Originally Posted by onceagain
All I want is a simple, reliable way of returning to the pre-Lion behaviour - an option for the system to simply not auto-launch previously open stuff. But it sounds like no one has developed that feature yet, is that correct?

That's correct, though a couple of simple techniques for "not auto-launch[ing] previously open stuff" have been explained in this thread.

Quote:
Originally Posted by onceagain
But you still have to wait for stuff to quit [before shutting down or restarting].

That has always been the case, so it has nothing to do with Lion.
NaOH is offline   Reply With Quote
Old 04-12-2012, 07:39 PM   #9
DeltaMac
League Commissioner
 
Join Date: Jan 2002
Posts: 8,523
Quote:
Originally Posted by onceagain
...
As for system file damage - I'll happily accept that risk for the sake of saving myself time. Sort of like risking a speeding ticket for the same reason.

A speeding ticket is simply a piece of paper, that you can likely talk your way out of, or simply toss it.
I would more compare that to 'risking an accident by cutting through the wrong way on a one way street during rush hour, just to save 5 seconds.'
Which is about what you save..., which you then lose the next time you boot, due to the extra POST checks after an improper shutdown. No risk there, just a promise of future file/system corruption. (and it's all you could ask for saving 5 seconds!)
DeltaMac is offline   Reply With Quote
Old 04-12-2012, 07:59 PM   #10
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by DeltaMac
A speeding ticket is simply a piece of paper...

The reality is that I often run my laptop out of power - and by the time it gets hooked back up to power, its last little bit of "reserve" is gone, and it has to start all the way back up again (as if I yanked the battery) - and when it does, I have no way of not having to wait for it to launch whatever applications happened to be running (along with opening all their windows) when the battery power died - which take a WHILE - when all I want to do is check my damned email. I don't want to have to wait for Word, Firefox, Omnigraffle, Illustrator, Photoshop, Excel, and whatever else I was last using to fire up and open all their windows. Takes a lot longer than 5 seconds. Word and Excel are particularly annoying, since they open a blank window that I just have to close.

This wasn't an issue with previous versions of the OS. Now it is. I don't think it's really asking for much to simply have an option for NOT doing this. It would be TRIVIAL for Apple to provide this option.

Last edited by onceagain; 04-12-2012 at 08:02 PM.
onceagain is offline   Reply With Quote
Old 04-12-2012, 08:01 PM   #11
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by NaOH
That's correct, though a couple of simple techniques for "not auto-launch[ing] previously open stuff" have been explained in this thread.

None of which seem to work for me....I've been trying for the last 4 hours.
onceagain is offline   Reply With Quote
Old 04-12-2012, 08:12 PM   #12
NaOH
Hall of Famer
 
Join Date: Dec 2007
Posts: 3,845
  1. In the Finder, hold the Option key, click on the Go menu, then select Library.
  2. When that opens, locate the Saved Application State folder.
  3. Open it, then move everything in it to the Trash.
  4. Press Command-I, then make certain the box next to Locked is checked.
No applications will ever re-open on their own (nor will application states ever be restored when relaunching an application).
NaOH is offline   Reply With Quote
Old 04-12-2012, 08:33 PM   #13
DeltaMac
League Commissioner
 
Join Date: Jan 2002
Posts: 8,523
Ah, well you missed telling us that you run the battery down, so it shuts off. Not the same as pulling the battery out, is it?
If you run the battery down completely, your MBPro stores the last memory state on the hard drive (safe sleep mode). So, you get a restore the next time you start the system. It's provided by the power manager. That's the sort-of transparent desktop that you get when you first turn power back on, with a progress bar. Nothing actually launches again, it's just restoring you to the same state. That restore process takes 30 seconds or so, but isn't the same as booting from nothing, and you return to exactly the same state that you were in before the battery runs down.
And, that's not new to Lion.

If none of THAT happens for you, after the battery completely runs down and your MBPro shuts off, then why have you disabled safe-sleep? Letting Safe Sleep work may get you more of what you are looking for, without needing to change how you actually use your Mac!

Last edited by DeltaMac; 04-12-2012 at 08:34 PM. Reason: NaOH has a good option, too!
DeltaMac is offline   Reply With Quote
Old 04-12-2012, 08:36 PM   #14
NaOH
Hall of Famer
 
Join Date: Dec 2007
Posts: 3,845
Quote:
Originally Posted by DeltaMac
Ah, well you missed telling us that you run the battery down, so it shuts off.

Re-read the thread and it becomes clear that onceagain's time is so valuable there isn't time to properly explain the situation to those who are spending time freely trying to help.
NaOH is offline   Reply With Quote
Old 04-13-2012, 12:33 AM   #15
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by NaOH
  1. In the Finder, hold the Option key, click on the Go menu, then select Library.
  2. When that opens, locate the Saved Application State folder.
  3. Open it, then move everything in it to the Trash.
  4. Press Command-I, then make certain the box next to Locked is checked.

Did this a long time ago - doesn't work. If I go to the terminal and su to root, I can go into the folder, and see there is nothing in there.
onceagain is offline   Reply With Quote
Old 04-13-2012, 12:35 AM   #16
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by DeltaMac
If none of THAT happens for you, after the battery completely runs down and your MBPro shuts off, then why have you disabled safe-sleep?

I disabled it (a long time ago) because I don't want my machine's state saved. Ever. Ever. Ever.

It also slow things down when going into sleep mode.

Last edited by onceagain; 04-13-2012 at 12:38 AM.
onceagain is offline   Reply With Quote
Old 04-13-2012, 12:38 AM   #17
NaOH
Hall of Famer
 
Join Date: Dec 2007
Posts: 3,845
These commands work (though the checkbox in the Shutdown prompt won't show it), but they also supposedly need to be re-entered in Terminal after a restart.

Code:
defaults write com.apple.loginwindow TALLogoutSavesState -bool false
defaults write com.apple.loginwindow LoginwindowLaunchesRelaunchApps -bool false
Truthfully, I don't know. I restarted this afternoon during this thread, leaving Mail and Safari open. They didn't re-launch on boot, and I certainly haven't applied the above commands since my last restart a couple days ago.
NaOH is offline   Reply With Quote
Old 04-13-2012, 12:46 AM   #18
NaOH
Hall of Famer
 
Join Date: Dec 2007
Posts: 3,845
There's also this method for disabling the behavior. That was the first result when I searched for mac lion disable reopen windows. It's from August when we were at 10.7.1, so I have no idea if it still works.
NaOH is offline   Reply With Quote
Old 04-13-2012, 03:25 AM   #19
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Quote:
Originally Posted by NaOH
These commands work (though the checkbox in the Shutdown prompt won't show it), but they also supposedly need to be re-entered in Terminal after a restart.

Code:
defaults write com.apple.loginwindow TALLogoutSavesState -bool false
defaults write com.apple.loginwindow LoginwindowLaunchesRelaunchApps -bool false

I will try that right now. I tried your second solution earlier today with no luck...
onceagain is offline   Reply With Quote
Old 04-13-2012, 03:32 AM   #20
onceagain
All Star
 
Join Date: Aug 2009
Posts: 666
Success??

Quote:
Originally Posted by onceagain
I will try that right now. I tried your second solution earlier today with no luck...

Hey, I think that worked!

After two power manager reset instant shutoff tests, applications failed to auto-launch each time.

Hopefully, this particular defaults/write trick will "stick". We'll see how it goes. In the meantime, I'll put those two lines in my "standard install" documentation.

Thanks for your help.
onceagain is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT -5. The time now is 03:26 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.
Site design © IDG Consumer & SMB; individuals retain copyright of their postings
but consent to the possible use of their material in other areas of IDG Consumer & SMB.