# The kernel appears to have died. It will restart automatically, when using NLopt

**URL:** <https://discourse.julialang.org/t/the-kernel-appears-to-have-died-it-will-restart-automatically-when-using-nlopt/11362>\
**Category:** Optimization (Mathematical)\
**Created:** [June 2, 2018, 10:21am UTC](https://discourse.julialang.org/t/the-kernel-appears-to-have-died-it-will-restart-automatically-when-using-nlopt/11362 "2018-06-02T10:21:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ludo](https://avatars.discourse-cdn.com/v4/letter/l/5f9b8f/32.png) [@Ludo](https://discourse.julialang.org/u/Ludo)\
**Post date:** [June 2, 2018, 10:21am UTC](https://discourse.julialang.org/t/the-kernel-appears-to-have-died-it-will-restart-automatically-when-using-nlopt/11362/1 "2018-06-02T10:21:03Z")

</div>

Trying to find a solve a NL system using a derivative-free (LN\_COBYLA or GN\_ISRES) algorithm with NLopt, within JuMP. I receive the following error message:

`The kernel appears to have died. It will restart automatically.`

In my attempt to solve the issue, I ran `Pkg.build(“IJulia”) and there is the below error message:

`Error executing Jupyter command 'kernelspec': [Errno 'jupyter-kernelspec' not found] 2`

Please, are both errors linked? How could I get around the issues?

Thanks for your help  
Below is my version info:

Julia Version 0.6.0  
Commit 903644385b\* (2017-06-19 13:05 UTC)  
Platform Info:  
OS: Windows (x86\_64-w64-mingw32)  
CPU: Intel(R) Core™ i5-6300U CPU @ 2.40GHz  
WORD\_SIZE: 64  
BLAS: libopenblas (USE64BITINT DYNAMIC\_ARCH NO\_AFFINITY Haswell)  
LAPACK: libopenblas64\_  
LIBM: libopenlibm  
LLVM: libLLVM-3.9.1 (ORCJIT, skylake)

---

<div class="post-metadata">

**Author:** ![sysk\_msk](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sysk_msk/32/6945_2.png) [@sysk\_msk](https://discourse.julialang.org/u/sysk_msk)\
**Post date:** [August 26, 2018, 2:06pm UTC](https://discourse.julialang.org/t/the-kernel-appears-to-have-died-it-will-restart-automatically-when-using-nlopt/11362/2 "2018-08-26T14:06:14Z")

</div>

There are two ways to solve it：  
a). Rebuilding the jupyter with  
pip3 install --upgrade --force-reinstall --no-cache-dir jupyter  
b). create a new file and rename as jupyter-kernelspec, the file contents as fellow:  
#!/usr/bin/python3  
import re  
import sys

from jupyter\_client.kernelspecapp import KernelSpecApp

if **name** == ‘ **main** ’:  
sys.argv[0] = re.sub(r’(-script.pyw?|.exe)?$', ‘’, sys.argv[0])  
sys.exit(  
KernelSpecApp.launch\_instance()  
)

Best wish!

ref:[Error executing Jupyter command 'kernelspec' · Issue #135 · n-riesco/ijavascript · GitHub](https://github.com/n-riesco/ijavascript/issues/135)
