MacOS – Mac App SQLDeveloper stuck in Dock after application closed, Process killed

dockjavamacmacos

I just started experiencing a bug where the SQLDeveloper 4.1.3 (latest) app icon freezes in the mac OS dock. This prevents me from relaunching the app without a hard reboot of the computer.

sqldeveloper in dock

Activity Monitor shows no app running.

P1105S123LT3:~ dan$ ps -A | grep SQL
  569 ??         0:00.01 /bin/bash /Applications/SQLDeveloper.app/Contents/MacOS/sqldeveloper.sh
4330 ??         0:39.13 /Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/bin/java -Xbootclasspath/a:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/lib/tools.jar:/Library/Java/JavaVirtualMachines/jdk1.8.0_92.jdk/Contents/Home/lib/dt.jar -Djdeveloper.system_http_proxy=DIRECT -Djdeveloper.system_http_non_proxy_hosts= -Dsun.java2d.noddraw=true -Dnetbeans.home=../../ide/bin/../../netbeans/platform/ -Dnetbeans.logger.console=true -Dexcluded.modules=org.eclipse.osgi -Dide.cluster.dirs=../../ide/bin/../../netbeans/fcpbridge/:../../ide/bin/../../netbeans/ide/:../../ide/bin/../../netbeans/../ -Xverify:none -Doracle.ide.extension.HooksProcessingMode=LAZY -Dorg.eclipse.equinox.simpleconfigurator.configUrl=file:bundles.info -Dosgi.bundles.defaultStartLevel=1 -Dosgi.configuration.cascaded=false -Dosgi.noShutdown=true -Dorg.osgi.framework.bootdelegation=* -Dosgi.parentClassloader=app -Dosgi.locking=none -Dosgi.contextClassLoaderParent=app -Xbootclasspath/p:../../ide/bin/../../rdbms/jlib/ojdi.jar -Dosgi.classloader.type=parallel -Dosgi.bundlefile.limit=500 -Dide.feedback-server=ide.us.oracle.com -Djavax.xml.transform.TransformerFactory=oracle.ide.xml.switchable.SwitchableTransformerFactory -Djavax.xml.stream.XMLInputFactory=com.ctc.wstx.stax.WstxInputFactory -Djavax.xml.stream.util.XMLEventAllocator=oracle.ideimpl.xml.stream.XMLEventAllocatorImpl -Doracle.ide.reportEDTViolations=bug -Doracle.ide.reportEDTViolations.exceptionsfile=../../ide/bin/../../ide/bin/swing-thread-violations.conf -Xms128M -Xmx800M -Doracle.ide.IdeFrameworkCommandLineOptions=-clean,-console,-debugmode,-migrate,-migrate:,-nomigrate,-nonag,-nondebugmode,-noreopen,-nosplash,-role:,-su -Dide.update.usage.servers=http://www.oracle.com/webfolder/technetwork/sqldeveloper/usage.xml -Doracle.ide.util.AddinPolicyUtils.OVERRIDE_FLAG=true -Dsun.java2d.ddoffscreen=false -Dwindows.shell.font.languages= -Doracle.ide.startup.features=sqldeveloper -Doracle.ide.osgi.boot.api.OJStartupHook=oracle.dbtools.raptor.startup.HomeSupport -Doracle.jdbc.mapDateToTimestamp=false -Doracle.jdbc.autoCommitSpecCompliant=false -Doracle.jdbc.useFetchSizeWithLongColumn=true -Dsun.locale.formatasdefault=true -Dorg.netbeans.CLIHandler.server=false -Dide.AssertTracingDisabled=true -Doracle.ide.util.AddinPolicyUtils.OVERRIDE_FLAG=true -Djava.util.logging.config.file=logging.conf -Dsqldev.debug=false -Dsqldev.onsd=true -Dcom.apple.mrj.application.apple.menu.about.name=SQL_Developer -Dcom.apple.mrj.application.growbox.intrudes=false -Dcom.apple.macos.smallTabs=true -Dapple.laf.useScreenMenuBar=true -Xdock:name=Oracle SQL Developer -Xdock:icon=SQLDeveloperIcons.icns -Xbootclasspath/p:../../rdbms/jlib/ojdi.jar -Dide.conf="/Applications/SQLDeveloper.app/Contents/Resources/sqldeveloper/sqldeveloper/bin/sqldeveloper.conf" -Duser.conf="/Users/dan/.sqldeveloper/4.1.0/product.conf" -Dtool.user.conf="/Users/dan/.sqldeveloper/4.1.0/sqldeveloper.conf" -Dide.startingcwd="/Applications/SQLDeveloper.app/Contents/Resources/sqldeveloper/sqldeveloper/bin" -classpath ../../ide/bin/../../ide/lib/ide-boot.jar:../../ide/bin/../../netbeans/platform/lib/boot.jar:../../ide/bin/../../netbeans/platform/lib/org-openide-util-ui.jar:../../ide/bin/../../netbeans/platform/lib/org-openide-util.jar:../../ide/bin/../../netbeans/platform/lib/org-openide-util-lookup.jar:../../ide/bin/../../netbeans/platform/lib/org-openide-modules.jar:../../ide/bin/../../ide/lib/fcpboot.jar:../../ide/bin/../../ide/lib/xml-factory.jar:../../ide/bin/../../ide/lib/woodstox-core-asl-4.2.0.jar:../../ide/bin/../../ide/lib/stax2-api-3.1.1.jar:../lib/oracle.sqldeveloper.homesupport.jar oracle.ide.osgi.boot.OracleIdeLauncher
4536 ttys000    0:00.00 grep SQL
P1105S123LT3:~ dan$ ps -A | grep SQL
4560 ttys000    0:00.00 grep SQL


P1105S123LT3:~ dan$ kill -9 4330
-bash: kill: (4330) - No such process
P1105S123LT3:~ dan$ kill -9 569
-bash: kill: (569) - No such process
P1105S123LT3:~ dan$

When I run directly from shell, it launches
P1105S123LT3:~ dan$ /Applications/SQLDeveloper.app/Contents/MacOS/sqldeveloper.sh
When I kill it from another terminal window :

P1105S123LT3:~ dan$ kill -9 12148
The shell from which I launched it returns this:

/Applications/SQLDeveloper.app/Contents/Resources/sqldeveloper/sqldeveloper/bin/../../ide/bin/launcher.sh: line 1286: 12148 Killed: 9               ${JAVA} "${APP_VM_OPTS[@]}" ${APP_ENV_VARS} -classpath ${APP_CLASSPATH} ${APP_MAIN_CLASS} "${APP_APP_OPTS[@]}"
P1105S123LT3:~ dan$
P1105S123LT3:~ dan$
P1105S123LT3:~ dan$

I have tried killall Dock which does not clear it.
I have tired deleting /Users/dan/Library/Preferences/com.apple.dock.plist

Still can't clear the app from the dock….

Any ideas??

Best Answer

So it appears that this was related to mac file structure corruption. I rebooted in safe mode and that rebuilt some caches which resolved the issue when

I again rebooted in normal mode. I ran the disk utility repair to verify file structure as well.

I talked with apple support who advised that safe mode bypasses the following caches, preferences, folders... so if need be - could wipe these folders to force a rebuilding of caches.

/Users/myuser/library/cache
/Users/myuser/library/LaunchAgents
/Users/myuser/library/Saved Application State

/library/Caches
/library/LaunchAgents
/library/LaunchDaemons
/library/StartupItems
Related Question