Luis
Luis

Reputation: 3497

Julia Kernel for Jupyter crashes

I installed Julia but cannot run a notebook in Jupyter (XUbuntu 14.04). As soon as I start a new notebook, it connects with the kernel and then crashes:

enter image description here

enter image description here

enter image description here


There's 2 possible things that I can think of. First, I installed Julia like this:

$ sudo apt-add-repository ppa:staticfloat/julianightlies
$ sudo apt-add-repository ppa:staticfloat/julia-deps
$ sudo apt-get update
$ sudo apt-get install julia

and then:

julia> Pkg.add("IJulia")
julia> Pkg.build("IJulia")

when running $ jupyter notebook, it showed the messages above. I removed Julia and now I have version 0.4.6, which I can run perfectly from bash. It still crashes in Jupyter, though. And it still shows two versions of Julia:

enter image description here

(Python and R work just nice)


The second idea is, maybe it has something to do with being root? If I run

$ Julia
julia> using IJulia
ERROR: SystemError: opening file /home/luis/.julia/lib/v0.4/IJulia.ji: Permission denied
 in open at ./iostream.jl:90
 in open at iostream.jl:102
 in stale_cachefile at loading.jl:439
 in recompile_stale at loading.jl:474
 in _require_from_serialized at loading.jl:83
 in _require_from_serialized at ./loading.jl:109
 in require at ./loading.jl:235

If I run:

$ sudo Julia
julia> using IJulia

it throws no errors at all.


Any ideas what could be happening?

Note: I am aware of similar questions here, but they havn't worked for me...

Upvotes: 2

Views: 1155

Answers (1)

cel
cel

Reputation: 31349

This can happen when files in your home directory were created by root and thus do not belong to your user. Rule of thumb is here: everything in your home directory should to belong to your user account.

You can use chown to change ownership:

sudo chown -R luis /home/luis/.julia will recursively change the owner of all files in /home/luis/.julia to the user account luis.

Upvotes: 6

Related Questions