# Shared Julia environment

**URL:** <https://discourse.julialang.org/t/shared-julia-environment/14206>\
**Category:** New to Julia\
**Tags:** question\
**Created:** [August 28, 2018, 6:52pm UTC](https://discourse.julialang.org/t/shared-julia-environment/14206 "2018-08-28T18:52:42Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![bnebgen](https://avatars.discourse-cdn.com/v4/letter/b/34f0e0/32.png) [@bnebgen](https://discourse.julialang.org/u/bnebgen)\
**Post date:** [August 28, 2018, 6:52pm UTC](https://discourse.julialang.org/t/shared-julia-environment/14206/1 "2018-08-28T18:52:42Z")

</div>

I’m trying to build Julia to be used by a group of developers. I’m work with v1.0 and have a Linux group associated with the developers, so I would like each member of the group to be able to use Julia and install packages (it is a small group and we trust each other).

Steps I’ve taken:

1. Unzipped Julia in a shared folder
2. Used $JULIA\_DEPOT\_PATH to point to a shared folder so Julia doesn’t try an install packages in ~/.julia. This seems to be working
3. installed a few packages including CMake
4. chgrp -R (now all of Julia should be part of the group)
5. chmod -R g=u (now group permissions should mirror user)
6. chmod -R g+s (now files made in sub-directories should inherit the group property)
7. run Julia and execute “status” in the package manager.

I’ve made sure that the other users have set up their environment (exporting the $JULIA\_DEPOT\_PATH variable) exactly the same as me. Step 7 works fine for me, but other group members get the following error:

```julia
(v1.0) pkg> status
ERROR: IOError: futime: operation not permitted (EPERM)
Stacktrace:
 [1] uv_error at ./libuv.jl:85 [inlined]
 [2] futime at ./filesystem.jl:143 [inlined]
 [3] touch(::String) at ./file.jl:407
 [4] write_env_usage(::String) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/Types.jl:424
 [5] Pkg.Types.EnvCache(::Nothing) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/Types.jl:306
 [6] Type at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/Types.jl:285 [inlined]
 [7] Type at ./none:0 [inlined]
 [8] Context!(::Array{Pair{Symbol,Any},1}) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/Types.jl:367
 [9] Context! at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/REPLMode.jl:497 [inlined]
 [10] do_status!(::Dict{Symbol,Any}, ::Array{String,1}, ::Dict{Symbol,Any}) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/REPLMode.jl:569
 [11] #invokelatest#1(::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::Function, ::Any, ::Any, ::Vararg{Any,N} where N) at ./essentials.jl:686
 [12] invokelatest(::Any, ::Any, ::Vararg{Any,N} where N) at ./essentials.jl:685
 [13] do_cmd!(::Pkg.REPLMode.PkgCommand, ::REPL.LineEditREPL) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/REPLMode.jl:542
 [14] #do_cmd#30(::Bool, ::Function, ::REPL.LineEditREPL, ::String) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/REPLMode.jl:507
 [15] do_cmd at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/REPLMode.jl:503 [inlined]
 [16] (::getfield(Pkg.REPLMode, Symbol("##41#44")){REPL.LineEditREPL,REPL.LineEdit.Prompt})(::REPL.LineEdit.MIState, ::Base.GenericIOBuffer{Array{UInt8,1}}, ::Bool) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/REPLMode.jl:842
 [17] #invokelatest#1 at ./essentials.jl:686 [inlined]
 [18] invokelatest at ./essentials.jl:685 [inlined]
 [19] run_interface(::REPL.Terminals.TextTerminal, ::REPL.LineEdit.ModalInterface, ::REPL.LineEdit.MIState) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/REPL/src/LineEdit.jl:2261
 [20] run_frontend(::REPL.LineEditREPL, ::REPL.REPLBackendRef) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/REPL/src/REPL.jl:1029
 [21] run_repl(::REPL.AbstractREPL, ::Any) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/REPL/src/REPL.jl:191
 [22] (::getfield(Base, Symbol("##720#722")){Bool,Bool,Bool,Bool})(::Module) at ./logging.jl:311
 [23] #invokelatest#1 at ./essentials.jl:686 [inlined]
 [24] invokelatest at ./essentials.jl:685 [inlined]
 [25] macro expansion at ./logging.jl:308 [inlined]
 [26] run_main_repl(::Bool, ::Bool, ::Bool, ::Bool, ::Bool) at ./client.jl:330
 [27] exec_options(::Base.JLOptions) at ./client.jl:242
 [28] _start() at ./client.jl:421

```

I can’t really figure out what file is causing the error. If anybody has any advice I would greatly appreciate it.

---

<div class="post-metadata">

**Author:** ![00vareladavid](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/00vareladavid/32/23521_2.png) [@00vareladavid](https://discourse.julialang.org/u/00vareladavid)\
**Post date:** [August 28, 2018, 9:56pm UTC](https://discourse.julialang.org/t/shared-julia-environment/14206/2 "2018-08-28T21:56:56Z")

</div>

Have you checked to see if the people who are getting the errors can manually run `touch` on `<depot_path>/logs/manifest_usage.toml` without getting errors?

I.e. what happens on `$ touch <depot_path>/logs/manifest_usage.toml` ?

---

<div class="post-metadata">

**Author:** ![bnebgen](https://avatars.discourse-cdn.com/v4/letter/b/34f0e0/32.png) [@bnebgen](https://discourse.julialang.org/u/bnebgen)\
**Post date:** [August 29, 2018, 2:30pm UTC](https://discourse.julialang.org/t/shared-julia-environment/14206/3 "2018-08-29T14:30:11Z")

</div>

touching the toml files works fine for them. They can grep through every file in both the julia folder and \<depot\_path\> without permission errors.

---

<div class="post-metadata">

**Author:** ![bnebgen](https://avatars.discourse-cdn.com/v4/letter/b/34f0e0/32.png) [@bnebgen](https://discourse.julialang.org/u/bnebgen)\
**Post date:** [August 29, 2018, 10:32pm UTC](https://discourse.julialang.org/t/shared-julia-environment/14206/4 "2018-08-29T22:32:16Z")

</div>

Update: The issue seems to have been solved by copying the files at \<JULIA\_DEPOT\_PATH\> for each user. That is to say that a user must be the owner of \<JULIA\_DEPOT\_PATH\> in order to use the Julia environment located there. The user does not need to own the base Julia executable.

This seems like a bug.

---

<div class="post-metadata">

**Author:** ![00vareladavid](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/00vareladavid/32/23521_2.png) [@00vareladavid](https://discourse.julialang.org/u/00vareladavid)\
**Post date:** [August 30, 2018, 1:41am UTC](https://discourse.julialang.org/t/shared-julia-environment/14206/5 "2018-08-30T01:41:59Z")

</div>

Ah, I think you are correct. I checked julia’s current issues and it seems like [this issue](https://github.com/JuliaLang/julia/issues/28815) is the source of the bug. I don’t think the package manager can do anything about it until this issue is resolved.

---

<div class="post-metadata">

**Author:** ![bnebgen](https://avatars.discourse-cdn.com/v4/letter/b/34f0e0/32.png) [@bnebgen](https://discourse.julialang.org/u/bnebgen)\
**Post date:** [August 30, 2018, 2:26pm UTC](https://discourse.julialang.org/t/shared-julia-environment/14206/6 "2018-08-30T14:26:33Z")

</div>

Thanks for pointing this out. I will stick with the work around until this gets fixed.

---

<div class="post-metadata">

**Author:** ![htwai](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/htwai/32/13383_2.png) [@htwai](https://discourse.julialang.org/u/htwai)\
**Post date:** [January 11, 2019, 2:08pm UTC](https://discourse.julialang.org/t/shared-julia-environment/14206/7 "2019-01-11T14:08:06Z")

</div>

Hey I’m wondering if there is any update on the issue…

We ran into the same issue of building up Julia (with packages) in a shared environment. While the main program of Julia works well, the users do not have access to the installed packages since they are not the owner of that folder (and they should not be)…
