6

How do I validate my Gurobi academic license remotely, that is, from a computer that is not on my university network?

Official instructions for Gurobi 9.1 are here: https://www.gurobi.com/documentation/9.1/quickstart_mac/academic_validation.html, but these require a VPN.

There are old instructions for using an ssh tunnel on the (retired) google group https://groups.google.com/g/gurobi/c/MaEP4cun8o8?pli=1, but these no longer work.

Neal Young
  • 169
  • 7
  • 1
    I don't think this belongs here. And your answer is very hard to read. Why don't you just delete the text instead of using strikethrough?

    License questions should be handled directly with Gurobi Support.

    – mattmilten Jan 19 '21 at 16:18
  • 1
    I figured this way at least people with the same question will be able to find an answer without bothering Gurobi support staff. (Apparently a number of Gurobi users use ssh instead of a VPN, but the official docs don't address how to do that, and the previous public forum that we used to use for sharing how has been archived in read-only mode and shows obsolete information. I did also post this on a Gurobi support forum, but at the moment anyway that forum is a little harder to find / google.) I have edited the answer to remove the previous answer, as you suggested, thanks. – Neal Young Jan 19 '21 at 19:07
  • Please accept Neal's answer, it's providing a working solution – Dima Pasechnik Nov 15 '23 at 15:48

3 Answers3

6

EDIT: Instead of a VPN, one can apparently use an ssh SOCKS proxy. This worked for me as of January 2021. Specifically, commands for enabling a SOCKS proxy on my mac are:

sudo networksetup -setsocksfirewallproxy 'Ethernet' 127.0.0.1 4088
sudo networksetup -setsocksfirewallproxy 'Wi-Fi' 127.0.0.1 4088

ssh -N -D 4088 <remote host>

Then, in a separate terminal window, run grbgetkey as usual.

grbgetkey <LICENSE KEY>

See also https://support.gurobi.com/hc/en-us/community/posts/360076437251-grbgetkey-via-ssh-socks-proxy .

EDIT Sept. 2021: the following comment for Mac OS Catalina was given at the above link, 1:

I couldn't get these instructions to work. (on Catalina, it seems opening a new terminal window doesn't give the terminal the proxy information... and I was still getting the 'not an academic domain' error) But this led me to an easier fix...

$ ssh -N -D 4088 user@host.edu

Then in another terminal

$ export HTTP_PROXY=socks5://127.0.0.1:4088
$ grbgetkey --http --verbose <LICENSE KEY>

You can probably get this to use https too if you setup the https_proxy variable, but I didn't try that.

EDIT Oct. 2022 (and still working Oct 2023):

It seems grbgetkey version 9.5.2 doesn't have the --http flag, but using HTTPS_PROXY did work for me:

$ ssh -N -D 4088 user@host.edu

Then in another terminal

$ export HTTPS_PROXY=socks5://127.0.0.1:4088
$ grbgetkey --verbose <LICENSE KEY>
Neal Young
  • 169
  • 7
  • The "socks5://" scheme in the proxy env var is very important! without it, it was having some kind of effect, but I was getting error : unexpected EOF. This was on Linux, and with HTTPS_PROXY. – golvok Oct 02 '22 at 02:28
  • great, export HTTPS_PROXY=socks5://127.0.0.1:<port> is what I needed! (on Linux) – Dima Pasechnik Nov 15 '23 at 15:45
6

Please direct licensing questions to Gurobi Support directly or check the official Knowledge Base articles.

mattmilten
  • 1,633
  • 8
  • 12
2

I have faced the same problem in getting an educational license since my college activities are fully remote. My solution (and I think the easiest way) is to open a support ticket and send several documents to validate you are the student.

overboxed
  • 593
  • 1
  • 12