# How to use Gurobi 11 in Julia launched by Anaconda?

**URL:** https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271
**Category:** Optimization (Mathematical)
**Tags:** gurobi
**Created:** [March 7, 2024, 12:41am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271 "2024-03-07T00:41:35Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![rzhao](https://avatars.discourse-cdn.com/v4/letter/r/fbc32d/32.png) [@rzhao](https://discourse.julialang.org/u/rzhao)
#### Post date: [March 7, 2024, 12:41am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/1 "2024-03-07T00:41:35Z")

</div>

I have updated my Julia to 1.10.2 indeed, and the version of Gurobi.jl is 1.2.1, all packages are newly installed for Julia 1.10.2.  
I have also downloaded the newest Gurobi 11 and updated the licence which support Gurobi 11

When I run the solver, the version is still 9.5.0  
Even when I try to run a Gurobi model in Julia’s terminal, it is also 9.5.0, same to Anaconda.

I hope to know how to run Gurobi 11 in JuMP?

Thanks

---

<div class="post-metadata">

### Author: ![odow](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/odow/32/28685_2.png) [@odow](https://discourse.julialang.org/u/odow)
#### Post date: [March 7, 2024, 1:11am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/2 "2024-03-07T01:11:55Z")

</div>

Try setting `GUROBI_HOME` to point to your new installation, then run `import Pkg; Pkg.build("Gurobi")`, and restart Julia for the change to take effect.

See [GitHub - jump-dev/Gurobi.jl: Julia interface for Gurobi Optimizer](https://github.com/jump-dev/Gurobi.jl/tree/master?tab=readme-ov-file#installation)

If it works, I should clarify the readme, since this comes up from time to time.

---

<div class="post-metadata">

### Author: ![rzhao](https://avatars.discourse-cdn.com/v4/letter/r/fbc32d/32.png) [@rzhao](https://discourse.julialang.org/u/rzhao)
#### Post date: [March 7, 2024, 6:43am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/3 "2024-03-07T06:43:41Z")

</div>

Thanks very much. I have tried the suggestions from this link and it does not works.

By the way, when I activate the newly obtained licence, I do it in Mac’s terminal, is that right?

---

<div class="post-metadata">

### Author: ![odow](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/odow/32/28685_2.png) [@odow](https://discourse.julialang.org/u/odow)
#### Post date: [March 7, 2024, 6:53am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/4 "2024-03-07T06:53:58Z")

</div>

Did you download Gurobi from [gurobi.com](http://gurobi.com)? Where is it installed?

---

<div class="post-metadata">

### Author: ![rzhao](https://avatars.discourse-cdn.com/v4/letter/r/fbc32d/32.png) [@rzhao](https://discourse.julialang.org/u/rzhao)
#### Post date: [March 7, 2024, 7:05am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/5 "2024-03-07T07:05:20Z")

</div>

Hi,

I find the problem. When I look at “system/Library”, I find a “gurobi950” folder, and there is no gurobi11 folder… Should I delete it and re-install the new one?

But, when I use Python to run Gurobi, it is Gurobi 11…

---

<div class="post-metadata">

### Author: ![odow](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/odow/32/28685_2.png) [@odow](https://discourse.julialang.org/u/odow)
#### Post date: [March 7, 2024, 7:10am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/6 "2024-03-07T07:10:01Z")

</div>

You need to download and install Gurobi 11 from [gurobi.com](http://gurobi.com).

Installing gurobipy on pip or conda automatically installs Gurobi, but Julia can’t easily use that version.

---

<div class="post-metadata">

### Author: ![rzhao](https://avatars.discourse-cdn.com/v4/letter/r/fbc32d/32.png) [@rzhao](https://discourse.julialang.org/u/rzhao)
#### Post date: [March 7, 2024, 7:17am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/7 "2024-03-07T07:17:51Z")

</div>

Thank you very much. I have fixed that. Gurobi 11 can be run on JuMP now.

I am very grateful

---

<div class="post-metadata">

### Author: ![odow](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/odow/32/28685_2.png) [@odow](https://discourse.julialang.org/u/odow)
#### Post date: [March 7, 2024, 7:24am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/8 "2024-03-07T07:24:07Z")

</div>

Great! Let me know if you have any other questions

---

<div class="post-metadata">

### Author: ![Xiangyin\_Wang](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/xiangyin_wang/32/210153_2.png) [@Xiangyin\_Wang](https://discourse.julialang.org/u/Xiangyin_Wang)
#### Post date: [June 22, 2024, 7:09am UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/9 "2024-06-22T07:09:09Z")

</div>

Hello. could you tell how did you solve this problem? I can not use gurobi 11 too.

---

<div class="post-metadata">

### Author: ![odow](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/odow/32/28685_2.png) [@odow](https://discourse.julialang.org/u/odow)
#### Post date: [June 22, 2024, 10:39pm UTC](https://discourse.julialang.org/t/how-to-use-gurobi-11-in-julia-launched-by-anaconda/111271/10 "2024-06-22T22:39:11Z")

</div>

Hi @Xiangyin_Wang, welcome to the forum.

See the installation instructions at [GitHub - jump-dev/Gurobi.jl: A Julia interface to the Gurobi Optimizer](https://github.com/jump-dev/Gurobi.jl?tab=readme-ov-file#installation)

Please start a new thread if you still have questions.
