How to validate Gurobi 8 on Ubuntu 18.04

857 views
Skip to first unread message

Jorge von Atzingen dos Reis

unread,
May 2, 2018, 5:06:42 PM5/2/18
to Gurobi Optimization

Hi

My computer is using a proxy server

How i can validate gurobi 8?


jorge@Asus-Z550SA:~$ grbgetkey 6dff6822-4e39-11e8-8dc6-0a4522cc772c 
info  : grbgetkey version 8.0.0, build v8.0.0rc0
info  : Contacting Gurobi key server...
info  : Communication failed, check your network connection or set variable HTTPS_PROXY if you need a proxy
info  : Run 'grbgetkey --help' for more details
error : dial tcp 54.163.225.128:443: i/o timeout
jorge@Asus-Z550SA:~$ gurobi.sh
Python 2.7.13 (default, Sep  4 2017, 15:40:17)
[GCC 4.4.7 20120313 (Red Hat 4.4.7-18)] on linux2
Type "help", "copyright", "credits" or "license" for more information.

No Gurobi license found (user jorge, host Asus-Z550SA, hostid cdc2b459, cores 4)

Running grbgetkey...
info  : grbgetkey version 8.0.0, build v8.0.0rc0

Enter the Key Code for the license you are activating
(format is xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx):
6dff6822-4e39-11e8-8dc6-0a4522cc772c

info  : Contacting Gurobi key server...
info  : Communication failed, check your network connection or set variable HTTPS_PROXY if you need a proxy
info  : Run 'grbgetkey --help' for more details
error : dial tcp 54.163.225.128:443: i/o timeout
Restart the Gurobi Interactive Shell to use a newly retrieved license key
jorge@Asus-Z550SA:~$ pygrbgetkey 6dff6822-4e39-11e8-8dc6-0a4522cc772c
pygrbgetkey: comando não encontrado
jorge@Asus-Z550SA:~$ grbgetkey --port=8008 --verbose 6dff6822-4e39-11e8-8dc6-0a4522cc772c
info  : grbgetkey version 8.0.0, build v8.0.0rc0
info  : Contacting Gurobi key server...
info  : Communication failed, check your network connection or set variable HTTPS_PROXY if you need a proxy
info  : Run 'grbgetkey --help' for more details
error : dial tcp 54.163.225.128:8008: i/o timeout
jorge@Asus-Z550SA:~$


Please check the following conditions for the computer where you want to install the free academic license:

  • The computer can communicate with the Gurobi website (http://www.gurobi.com)
  • The computer is not using a proxy server
  • The grbgetkey program is not blocked by a personal firewall or an internet security program


Thanks

Michel Jaczynski

unread,
May 2, 2018, 5:11:20 PM5/2/18
to Gurobi Optimization
Hi Jorge,

Please set the environment variable HTTPS_PROXY. You will find more help with command 'grbgetkey --help'

Regards,

Michel Jaczynski

Jorge von Atzingen dos Reis

unread,
May 2, 2018, 9:07:09 PM5/2/18
to Gurobi Optimization
Hi
I'm sorry but I did not understand how to do the validation
Could you explain it again? 
I tried the following commands

jorge@Asus-Z550SA:~$ grbgetkey --help
Gurobi license key utility version 8.0.0, build v8.0.0rc0
Copyright (c) 2018, Gurobi Optimization, LLC

Usage:
 grbgetkey --help              Display usage
 grbgetkey [flags] [KEYCODE]   Download license from Gurobi license server

This command passes identifying information about your machine back to the
Gurobi website, and the website responds with your license key. You should
provide the KEYCODE as the following, or you will be prompted to enter it:

   grbgetkey xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

Once this exchange has occurred, you will be asked for the name of the
directory in which to store your license key file (gurobi.lic). You can store
the license key file anywhere, but we strongly recommend that you accept the
default location. If you would like to use a non-default license key file
location, you can do so by setting the environment variable GRB_LICENSE_FILE
to point to the license key file.

Flags can be set using --flag=value or the short form -f=value if defined.
A boolean flag can be enabled using --flag or the short form -f if defined.

Flags:
     --console-ts      Add timestamps to console log messages
     --help            Display usage
     --http            Use HTTP instead of HTTPS (less secure)
     --path string     Path to store the license file
     --port string     Alternate Gurobi license server port
 -q, --quiet           Do not prompt user
 -v, --verbose         Enable verbose logging
     --version         Display version information
     --server string   Alternate Gurobi license server name

grbgetkey is compatible with standard proxy settings using environment
variables HTTP_PROXY and HTTPS_PROXY. HTTPS_PROXY takes precedence over
HTTP_PROXY for https requests. The values may be either a complete URL or
a "host[:port]", in which case the "http" scheme is assumed. grbgetkey uses
HTTPS by default but HTTP can also be used with the flag --http.
jorge@Asus-Z550SA:~$ pygrbgetkey proxy.facip.ufu.br  6dff6822-4e39-11e8-8dc6-0a4522cc772c
pygrbgetkey: comando não encontrado
jorge@Asus-Z550SA:~$ grbgetkey proxy.facip.ufu.br  6dff6822-4e39-11e8-8dc6-0a4522cc772c   

info  : grbgetkey version 8.0.0, build v8.0.0rc0
error : Key code invalid format
jorge@Asus-Z550SA:~$ grbgetkey --HTTPS_PROXY=proxy.facip.ufu.br[:3128] 6dff6822-4e39-11e8-8dc6-0a4522cc772c              
Error: unknown flag: --HTTPS_PROXY
Run 'grbgetkey --help' for usage.
jorge@Asus-Z550SA:~$ grbgetkey --https=proxy.facip.ufu.br[:3128] 6dff6822-4e39-11e8-8dc6-0a4522cc772c            
Error: unknown flag: --https
Run 'grbgetkey --help' for usage.
jorge@Asus-Z550SA:~$ grbgetkey --http=proxy.facip.ufu.br[:3128] 6dff6822-4e39-11e8-8dc6-0a4522cc772c  
Error: invalid argument "proxy.facip.ufu.br[:3128]" for "--http" flag: strconv.ParseBool: parsing "proxy.facip.ufu.br[:3128]": invalid
syntax
Run 'grbgetkey --help' for usage.
jorge@Asus-Z550SA:~

Thanks
Jorge

Michel Jaczynski

unread,
May 2, 2018, 9:09:24 PM5/2/18
to Gurobi Optimization
Jorge,

You need to set the HTTPS environment variable first, then use grbgetkey. In your case, please type the 2 following commands:

export HTTPS_PROXY=proxy.facip.ufu.br:3128

grbgetkey 6dff6822-4e39-11e8-8dc6-0a4522cc772c 


Michel Jaczynski
Reply all
Reply to author
Forward
0 new messages