This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 247690 - Will not quit. Will not let me turn off mac. I must hold down port o force quit laptop
Summary: Will not quit. Will not let me turn off mac. I must hold down port o force qu...
Status: REOPENED
Alias: None
Product: platform
Classification: Unclassified
Component: Launchers&CLI (show other bugs)
Version: 8.2
Hardware: Macintosh Mac OS X
: P3 normal with 8 votes (vote)
Assignee: Libor Fischmeistr
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-05 01:12 UTC by billmoriarty
Modified: 2018-09-08 17:38 UTC (History)
8 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
messages.log after NetBeans won't respond to Force Quit (41.73 KB, application/octet-stream)
2015-01-29 01:08 UTC, ggruen
Details
Screenshot of NetBeans application dock menu (52.59 KB, image/png)
2015-05-30 02:50 UTC, ggruen
Details
The ps ax output of my system when Netbeans freezes (23.35 KB, text/plain)
2016-03-09 12:41 UTC, teras
Details

Note You need to log in before you can comment on or make changes to this bug.
Description billmoriarty 2014-10-05 01:12:14 UTC
Hi. I recently started using netbeans. I started with 8 and had this problem. I uninstalled and now have 8.0.1. Same problem...

Often, netbeans won't quit if I go to Quit. It will appear to quit but I still see it open under active applications. When in this state - if I click on the netbeans icon to open the app again nothing happens. If I go to force quit on mac, select netbeans, and hit force quit nothing happens. If I tell my mac to restart or turn off it will not and the only application that's hanging and preventing it is netbeans. If I force quit the laptop a couple times by holding down the power button until it totally shuts off, then I can uninstall netbeans, reinstall netbeans, and it will work again for a day or so. I'm in a computer science class so we're using netbeans about every day... I'm wondering if you gave a fix for this? thank - Bill

Retina, 13-inch, Late 2012
Processor  2.9 GHz Intel Core i7
Memory  8 GB 1600 MHz DDR3
Graphics  Intel HD Graphics 4000 1024 MB
Software  OS X 10.9.5 (13F34)
Comment 1 DOC_ASAREL 2014-10-23 07:30:51 UTC
I have the same problem. Just wanted to post it.
I don't know if this is since Yosemite update only, since I use Netbeans for a short time only now (ramped up from Sublime, wanted to give you an (Y) for that!).

Also the really reason why this is annoying, is that a restart is completely blocked (referrable bug here: https://netbeans.org/bugzilla/show_bug.cgi?id=168718).
Comment 2 Tomas Hurka 2014-10-24 13:35:49 UTC
Please, generate a thread dump (http://wiki.netbeans.org/GenerateThreadDump) when the problem happens again. Attach thread dump and messages.log (http://wiki.netbeans.org/FaqLogMessagesFile) to this issue. Thanks.
Comment 3 ggruen 2015-01-29 01:08:59 UTC
Created attachment 151721 [details]
messages.log after NetBeans won't respond to Force Quit

Just had this issue happen to me.

Gathering the information requested in the previous comment:
- Can't generate a thread dump because:
  - Didn't run NetBeans from the command line - it's installed as an application
    in the Applications folder
  - It appears no Java VM is running:
    lightie:~ grant$ ps -u grant | grep j
    501 10968 ttys000    0:00.01 grep j

- messages.log is attached.
Comment 4 ggruen 2015-01-29 01:13:18 UTC
Updated platform and version number.  Happened in NetBeans 8.0.2 on MacBook Air running MAC OS 10.10.1.
Comment 5 Tomas Hurka 2015-02-09 08:42:43 UTC
(In reply to ggruen from comment #3)
> Created attachment 151721 [details]
> messages.log after NetBeans won't respond to Force Quit
> 
> Just had this issue happen to me.
> 
> Gathering the information requested in the previous comment:
> - Can't generate a thread dump because:
>   - Didn't run NetBeans from the command line - it's installed as an
> application
>     in the Applications folder
>   - It appears no Java VM is running:
>     lightie:~ grant$ ps -u grant | grep j
>     501 10968 ttys000    0:00.01 grep j
> 
> - messages.log is attached.
Thanks for the messages.log file. Thread dump can be generated even if the application is not run from the command line. Please read http://wiki.netbeans.org/GenerateThreadDump - you can use jps/jstack or VisualVM.
Comment 6 mpilone 2015-03-16 14:25:05 UTC
I've seen the same issue at least twice with OS X 10.10 and Netbeans 8.0 and 8.0.1. NetBeans is still listed in the application list of the Force Quit window, but attempting to force quit does nothing. Attempting to shutdown/restart results in OS X complaining that it could not stop the process. However there are no Java processes running on the machine and nothing obvious listed with "ps auwwx".

It isn't possible to get a thread dump because there is no PID. JPS also doesn't show any Java process (other than itself) running.

It seems like the issue is that the application is registered as still running with the OS even though it has exited. I found that "sudo shutdown -r now" works and is probably slightly safer than just holding the power button on the machine.
Comment 7 xiaolittle 2015-05-27 14:53:36 UTC
Same here.
When will this bug be fixed? I don't want to use the power button each time
Comment 8 ggruen 2015-05-30 02:49:55 UTC
(In reply to Tomas Hurka from comment #5)
> (In reply to ggruen from comment #3)
> > Created attachment 151721 [details]
> > messages.log after NetBeans won't respond to Force Quit
> > 
> > Just had this issue happen to me.
> > 
> > Gathering the information requested in the previous comment:
> > - Can't generate a thread dump because:
> >   - Didn't run NetBeans from the command line - it's installed as an
> > application
> >     in the Applications folder
> >   - It appears no Java VM is running:
> >     lightie:~ grant$ ps -u grant | grep j
> >     501 10968 ttys000    0:00.01 grep j
> > 
> > - messages.log is attached.
> Thanks for the messages.log file. Thread dump can be generated even if the
> application is not run from the command line. Please read
> http://wiki.netbeans.org/GenerateThreadDump - you can use jps/jstack or
> VisualVM.

So, here's the output from jps:
$ jps -lm
33248 sun.tools.jps.Jps -lm
$ jstack 33248
33248: No such process

If I'm reading that right, looks like NetBeans isn't actually running/frozen.  Maybe there's an issue with the way the application packaged on the Mac?

I currently have NetBeans 8.0 appearing in my Dock.  But:
- if I hit command-tab, it doesn't appear in the application switcher
- if I go to Applications/NetBeans in the Finder and double-click on
  NetBeans 8.0.app (I don't know why it's in a sub-folder), the application
  line is selected (I'm in list view), but nothing else happens (no
  opening animation, no switching to a different application, etc).
- if I click on the icon in the Dock, the icon darkens for a moment, then returns
  to its normal state.  The application shown in the menu bar doesn't change.
- if I click and hold on the icon in the dock, a menu appears (I'll attach
  a screenshot).  It states that the application is not responding at the top.
  If I select Force Quit from said menu, the Force Quit option blinks three times.

I should also mention that I *think* the following happened - might be a means to
reproduce the problem:
- Run NetBeans (I did this from Spotlight by hitting command-space, typing
  netbeans, hitting return).
- With the application open, run NetBeans again (I did it again accidentally
  in Spotlight)

When I did this, a second instance of the NetBeans icon appeared and started bouncing in the dock.  It's this instance that won't quit.  When I hit command-Q to quit NetBeans, the application windows closed and the original instance of the icon disappeared from the Dock.

Re-openening in the hopes that this info helps debug the issue more.
Comment 9 ggruen 2015-05-30 02:50:44 UTC
Created attachment 153964 [details]
Screenshot of NetBeans application dock menu
Comment 10 Tomas Hurka 2015-06-05 08:01:32 UTC
(In reply to ggruen from comment #8)
> (In reply to Tomas Hurka from comment #5)
> > (In reply to ggruen from comment #3)
> > > Created attachment 151721 [details]
> > > messages.log after NetBeans won't respond to Force Quit
> > > 
> > > Just had this issue happen to me.
> > > 
> > > Gathering the information requested in the previous comment:
> > > - Can't generate a thread dump because:
> > >   - Didn't run NetBeans from the command line - it's installed as an
> > > application
> > >     in the Applications folder
> > >   - It appears no Java VM is running:
> > >     lightie:~ grant$ ps -u grant | grep j
> > >     501 10968 ttys000    0:00.01 grep j
> > > 
> > > - messages.log is attached.
> > Thanks for the messages.log file. Thread dump can be generated even if the
> > application is not run from the command line. Please read
> > http://wiki.netbeans.org/GenerateThreadDump - you can use jps/jstack or
> > VisualVM.
> 
> So, here's the output from jps:
> $ jps -lm
> 33248 sun.tools.jps.Jps -lm
> $ jstack 33248
> 33248: No such process
33248 is the process id of jps itself. It does not make much sense to call jstack on 33248.

> If I'm reading that right, looks like NetBeans isn't actually
> running/frozen. 
The output shows that there is no java process running.

It looks like that NetBeans launcher script is still there and therefor you have NetBeans icon in the dock. It would be useful to get output of 'ps -ax' to see if the NetBeans launcher is still there. Reasoning to platform/launcher.
Comment 11 bernd_zedv 2015-07-14 14:15:24 UTC
Had the same problem with 8.0.2 today. NB was running in full screen mode. Switched with Command+Tab to an other application. NB full screen window had been disappeared when switching back. Could not force quit or 'sudo killall -9 java' - no java process was running.
Comment 12 rocketrisa 2015-08-05 17:37:58 UTC
I had this same issue. NetBeans was running super slow on my iMac so I deactivated the plugins I was not using. After it restarted, I quit the application. The screen closed but the icon is still active at the bottom in my dock bar. I tried force quitting from the icon and from the Force Quit Applications menu and it still will not quit. I've had this issue previously after installing Yosemite (10.10.4). My iMac has 32gbs of memory so I highly doubt it's a memory issue, especially because when I checked in my Activity Monitor, it states I'm only using 3.56gb of memory. 

iMac (27-inch, Late 2012)
Processor 3.2 GHz Intel Core i5
Memory 32 GB 1600 MHz DDR3
Graphics NVIDIA GeForce GTX 675MX 1024 MB
Software 10.10.4

Netbeans version: 8.0.2
Comment 13 TheKarateKid 2015-09-10 14:36:07 UTC
Same thing happened to me with NetBeans 8.0.2 on OS X 10.10.4

I quit Netbeans, all windows of it are closed, but it prevents the OS from shutting down. It appears in the Force Quit menu, but still can't be killed. No process of Netbeans or Java appear in Activity Monitor or through 'ps' via terminal.
Comment 14 massimo 2016-03-02 18:42:53 UTC
same here, NB 8.1 on Mac El Capitan
Comment 15 TheKarateKid 2016-03-02 22:08:46 UTC
For those experiencing this issue, to get your Mac to reboot without hard resetting, open Terminal and type 'sudo shutdown -r now'.

This was the only way my Mac was able to reboot, other than holding the power button down.
Comment 16 teras 2016-03-09 12:40:09 UTC
I have the same problem. I have found that this is when it happens:

When a plugin is updated, then the second time Netbeans starts, it shows a second icon on the Dock. If I click on that icon everything is fine. If on the other hand click on the original Netbeans icon (which now is marked as "not running"), then the icon starts to bounce as if it is trying to start Netbeans again.

Of course Netbeans doesn't start a second time, since it is still running with a new dedicated icon below so it keeps on bouncing. The second icon can be properly quit. The original icon though is now stuck and unable to either force quit or kill PID. If I kill the Dock itself, then ghost Netbeans icon is still there and marked as running (with the same stuck behavior).

This behavior happens all the time.


I confirm that no sh/bash is found on ps or Java executable. I will also attach a list of ps just to have a look.
Comment 17 teras 2016-03-09 12:41:33 UTC
Created attachment 158786 [details]
The ps ax output of my system when Netbeans freezes
Comment 18 tberty 2016-04-01 21:13:06 UTC
We can easy to force quit any application on Mac OS X with a few keys.

Check it out!

http://www.techfor.us/2015/12/how-to-force-quit-mac-application-with-shortcut/
Comment 19 nesreb 2016-04-06 14:33:09 UTC
(In reply to tberty from comment #18)
Thanks for that info tberty, but unfortunately those tips don't kill NetBeans when you accidentally click on the docked NetBeans icon (which only sometimes causes this issue).  Without killing NetBeans, the mac will not shut down.  Even running as sudo from the command line won't kill it.  Just happened again to me today and I tried all those suggestions.  The only thing that works for me is holding down the power button until it powers off.
Comment 20 johnjamesjacoby 2016-04-21 20:18:12 UTC
Am running into this now on my Mac Pro.

* I've used Netbeans for years and never had this problem
* Everything is up-to-date
* Running OS X 10.11.5 Beta (15F24b)
* I don't think my Macbook Air has this issue
* I don't think I have any custom Netbeans configurations set, but I'll need to check
Comment 21 bergmann 2016-04-26 13:44:16 UTC
I have the exact same issue and it's driving me nuts. Is anyone on this?
Comment 22 jimmytehbanana 2016-05-04 00:44:01 UTC
I've been able to repeat this problem by running a bash script within netbeans. The bash script prompts for user input. As soon as I run it, Netbeans stops responding. Force quitting Netbeans doesn't work, there is no jvm running, and I am able to start netbeans from command prompt just fine. 

To run the bash script, I right click it and click "Open in System"


I haven't tested with a non-prompting bash script.
Comment 23 kaha6uc 2016-06-24 11:50:32 UTC
Same here, this happens on all Macs and Hackintoshes I have tried.

The NetBeans launcher is docked on the Dock.

The problem appears after an update or LAF change (or any preferences modification that requires IDE restart) - the user is requested to restart IDE for the changes to take effect. Regardless of whether you click the balloon or quit and start NetBeans manually, a new icon appears on the Dock, this one saying "java" as a title. This process starts up a good and running, fully usable instance of NetBeans.
However, if I forget that it is running from the new icon and click the original Dock icon, it bounces and, of course, doesn't start. The I cmd+Q the "java" instance, it closes, but the hanged "NetBeans 8.1" process cannot be force-quit or killed any other way, preventing UI reboot or shutdown.

No "java" and no "NetBeans" process can be found in "ps aux", "top", "Activity Monitor".

At this point, the command "sudo shutdown -r now" in Terminal is the only way to reboot the machine.
Comment 24 tberty 2016-07-01 17:10:04 UTC
(In reply to tberty from comment #18)
> We can easy to force quit any application on Mac OS X with a few keys.
> 
> Check it out!
> 
> techfor(dot)us/2015/12/how-to-force-quit-mac-application-with-
> shortcut/

This link is dead now, I just want to update with the new one.

https://usefulpcguide.com/16706/how-to-force-quit-mac-apps-with-shortcut/
Comment 25 normandavid67 2016-08-28 21:34:45 UTC
I cannot use Netbeans 8,1 on 

Model Name:	iMac
Model Identifier:	iMac15,1
Processor Name:	Intel Core i5
Processor Speed:	3.3 GHz
Number of Processors:	1
Total Number of Cores:	4
L2 Cache (per Core):	256 KB
L3 Cache:	6 MB
Memory:	16 GB
-------------------------
System Version:	OS X 10.11.6 (15G31)
Kernel Version:	Darwin 15.6.0
Boot Volume:	Macintosh HD
Comment 26 normandavid67 2016-08-28 21:36:37 UTC
(In reply to normandavid67 from comment #25)
It keeps restarting, even after deleting the ´update´ folder.
Comment 27 twolf2919 2017-10-25 15:41:52 UTC
I just encountered the same issue.  Force-Quit dialog shows Netbeans, but selecting it for force-quit doesn't do anything.  There's no actual NB process running.

Environment: macOS High Sierra (10.13), 2017 MBP, with Radeon Pro 560.  NB is running Java 8.
Comment 28 twolf2919 2017-10-25 15:42:57 UTC
(In reply to twolf2919 from comment #27)
Forgot NB version: 8.2.
Comment 29 rafschietekat 2017-10-27 05:21:47 UTC
Try "Remove from Dock".

For what this *anecdote* is worth, because this only just happened, and I don't remember the exact steps nor do I particularly care about trying to reproduce this myself (just very randomly: it was with a "Keep in Dock" NetBeans 8.2 on a Mac running Sierra 10.12.6, I was doing some bundle reconfiguration involving restarting NetBeans, there was a second icon at some point, I couldn't restart the computer and Force Quit had no effect, I couldn't run NetBeans again from the icon but I could from a command line, etc.): I tried "Remove from Dock", which at first didn't seem to have any effect, although I did notice the dot that indicates a running application (I don't remember whether it was there before), but sometime after I tried to "Restart..." the computer again, while I had already started entering my password to "sudo shutdown -r now" in Terminal (anything better than a reset, why don't Macs have emergency shells that can bypass the window server?!), suddenly I got a dialog about shutting down a command in Terminal, and when I allowed that the computer restarted normally.
Comment 30 bentech 2017-12-18 12:17:19 UTC
How to reproduce:

Start netbeans in dock

Perform update with restart

While new instance of Netbeans is open called "java" attempt to open the other icon in the dock
Comment 31 gfrias 2018-01-16 18:00:03 UTC
Hi,

Is someone actually working on this bug? It's pretty annoying... 

- No java nor NB process running under ps aux. 
- 'sudo shutdown -r now' to restart or forcefully shut it down by holding the power button is only WA.  
- NB8.2 and Macbook Air. 
- Dock shows NB 'not responding'

Let me know if you need any other info 

Gabriels-Air:~ gabriek$ java -version
java version "1.8.0_151"
Java(TM) SE Runtime Environment (build 1.8.0_151-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.151-b12, mixed mode)
Gabriels-Air:~ gabriek$
Gabriels-Air:~ gabriek$ sw_vers
ProductName:	Mac OS X
ProductVersion:	10.13.1
Comment 32 nbsocko 2018-03-28 22:38:57 UTC
This is happening to me as well.  Steps to reproduce:

- Open Netbeans
- Re-open Netbeans while it is currently open

Now two Netbeans icons display in the dock. The original version will quit. The newly opened version shows "Application not Responding" when right-clicking its icon in the Dock. It cannot be force quit via the Dock, and cannot be located in Activity Monitor.d Whatever is running (or starting to run and never fully opening) prevents user logout or standard shutdown. The only remedy is the sudo shutdown via Terminal as others have listed here, or holding down the power button to forcibly shut down.

java version "9.0.1"
Java(TM) SE Runtime Environment (build 9.0.1+11)
Java HotSpot(TM) 64-Bit Server VM (build 9.0.1+11, mixed mode)
ProductName:	Mac OS X
ProductVersion:	10.13.3
BuildVersion:	17D102
  
  Model Name:	iMac
  Model Identifier:	iMac17,1
  Processor Name:	Intel Core i7
  Processor Speed:	4 GHz
  Number of Processors:	1
  Total Number of Cores:	4
  L2 Cache (per Core):	256 KB
  L3 Cache:	8 MB
  Memory:	32 GB
  Boot ROM Version:	IM171.0110.B00
  SMC Version (system):	2.34f2
Comment 33 kvguser 2018-09-08 16:42:33 UTC
and keeps happening:

NB 8.2
MacBook Pro Retina 15" (mid 2012)
macOS High Sierra 10.13.6
total RAM: 8 GB
used RAM: 6.77 GB
Comment 34 kvguser 2018-09-08 17:38:38 UTC
I just found that logging out works also to get rid of that "ghost" NetBeans.
But the log out itself cannot be initiated from the OS GUI (Apple > Log Out <your_user_name>). So you do it from shell:

sudo pkill loginwindow


I found another advice but haven't had the chance to test it yet:

1) close all your apps
2) run:
killall -u <your_user_name>