Hi Yawei, For curl, always use the dns name of the server the container is running on, i.e. the http://128… address you have.
To address files, the pseudo-DNS name is created by taking the “domain” config value (in h5serv/server/config.py), and combining with the reverse path of the file relative to the data directory. There’s another config value: “datapath” that gives the location to the data directory. So in your case you should set this to: /data/h5_store. After this (and restarting the server), if you have “myfile.h5” in the h5_store directory, the h5serv host path to that file would be: myfile.hdfgroup.org. If you’ve setup a DNS entry for your server, say h5serv.ornl.gov, then you can update the domain config value to match. In that case you’d have myfile.h5serv.ornl.gov. The various config entries are documented here: http://h5serv.readthedocs.io/en/latest/Installation/ServerSetup.html#server-configuration. Hope this helps! Configuration is always the challenging aspect. You can email me directly (jreadey AT hdfgroup DOT org) if that doesn’t work. Cheers, John From: Hdf-forum <[email protected]> on behalf of "Hui, Yawei" <[email protected]> Reply-To: HDF Users Discussion List <[email protected]> Date: Tuesday, October 24, 2017 at 9:20 AM To: "[email protected]" <[email protected]> Subject: [Hdf-forum] Question about domain name in h5 server Hi, I’m a new user of h5 server. On my test server, I installed and ran the h5serv docker container. From a remote browser, I could get response by sending http://128.XXX.XXX.XXX:5000/ to the server. However, when I tried to use curl-based request, such as “curl --header "Host: dp.h5_store.hdfgroup.org" http://128.XXX. XXX. XXX:5000/”, an error “tornado.web.HTTPError: HTTP 404: Not Found” occurred. The h5 files I want the server to serve is under “/data/h5_store”. Because the h5 server is installed on a machine without domain name (e.g. hdfgroup.org), how could I set up a valid HTTP header so that the curl command could be used to send the request? Thanks. - Yawei - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Computer Science Research Group Computer Science and Mathematics Division Oak Ridge National Laboratory PO BOX 2008 MS6164 OAK RIDGE TN 37831-6164
_______________________________________________ Hdf-forum is for HDF software users discussion. [email protected] http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org Twitter: https://twitter.com/hdf5
