How to start the lunaserv after compliling?

55 views
Skip to first unread message

俊黄

unread,
May 5, 2020, 10:06:18 PM5/5/20
to Lunaserv
Dear Nick,
It is a separate question so I start a new post.

Could you point out where I can find how to start the lunaserv map service?

I found configuration of the lunaserv and an example for qgis on the lunaserv website, but I didn't find how to start the service. 

thank you,
Jun

Nick Estes

unread,
May 5, 2020, 10:49:52 PM5/5/20
to 俊黄, Lunaserv
We recommend using Passenger (https://www.phusionpassenger.com/). If
you already have an Apache or Nginx web server running, Passenger can
install as a module into either of those web servers or for just trying
out Lunaserv, Passenger in standalone mode is probably your best bet.
The short version of how to do that is to install passenger with the
command "gem install passenger", then you just go into the Lunaserv
directory (the directory that contains the config.ru file) and run
"passenger start". By default, it will run in development mode on port
3000, but it has lots of options to change those and other settings.

It's also possible to run it with any other mechanism that can run a
Rack application which includes webrick, rackup, FastCGI, and probably
other things, but Passenger is super easy and well-tested with Lunaserv.

--Nick
> --
> You received this message because you are subscribed to the Google
> Groups "Lunaserv" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to lunaserv+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com
> [1].
>
>
> Links:
> ------
> [1]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&utm_source=footer

俊黄

unread,
May 7, 2020, 10:45:48 AM5/7/20
to Lunaserv
Thank you Nick!

The following is the messages after I typed "passenger start". I didn't install naif, because I don't think I will need the illumination.

Do you think I can point to http://0.0.0.0:3000/ in qgis now? I have untared the example layers provided by the lunaserv website.

=============== Phusion Passenger Standalone web server started ===============
PID file: /home/jun/Downloads/lunaserv-3.20160316/passenger.3000.pid
Log file: /home/jun/Downloads/lunaserv-3.20160316/log/passenger.3000.log
Environment: development
Accessible via: http://0.0.0.0:3000/

You can stop Phusion Passenger Standalone by pressing Ctrl-C.
===============================================================================
App 15105 output: Error: The application encountered the following error: Could not find gem 'naif-spice' in any of the gem sources listed in your Gemfile. (Bundler::GemNotFound)
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:289:in `block in verify_gemfile_dependencies_are_found!'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:257:in `each'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:257:in `verify_gemfile_dependencies_are_found!'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:48:in `start'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/resolver.rb:22:in `resolve'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/definition.rb:257:in `resolve'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/definition.rb:170:in `specs'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/definition.rb:237:in `specs_for'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/definition.rb:226:in `requested_specs'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:108:in `block in definition_method'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/runtime.rb:20:in `setup'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler.rb:107:in `setup'
App 15105 output:     /usr/lib/ruby/vendor_ruby/bundler/setup.rb:20:in `<top (required)>'
App 15105 output:     /usr/lib/ruby/2.5.0/rubygems/core_ext/kernel_require.rb:59:in `require'
App 15105 output:     /usr/lib/ruby/2.5.0/rubygems/core_ext/kernel_require.rb:59:in `require'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/ruby_supportlib/phusion_passenger/loader_shared_helpers.rb:363:in `activate_gem'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/ruby_supportlib/phusion_passenger/loader_shared_helpers.rb:221:in `block in run_load_path_setup_code'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/ruby_supportlib/phusion_passenger/loader_shared_helpers.rb:527:in `running_bundler'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/ruby_supportlib/phusion_passenger/loader_shared_helpers.rb:220:in `run_load_path_setup_code'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/helper-scripts/rack-preloader.rb:91:in `preload_app'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/helper-scripts/rack-preloader.rb:189:in `block in <module:App>'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/ruby_supportlib/phusion_passenger/loader_shared_helpers.rb:380:in `run_block_and_record_step_progress'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/helper-scripts/rack-preloader.rb:188:in `<module:App>'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/helper-scripts/rack-preloader.rb:30:in `<module:PhusionPassenger>'
App 15105 output:     /var/lib/gems/2.5.0/gems/passenger-6.0.4/src/helper-scripts/rack-preloader.rb:29:in `<main>'
[ E 2020-05-07 22:37:26.7811 15066/Tj age/Cor/App/Implementation.cpp:221 ]: Could not spawn process for application /home/jun/Downloads/lunaserv-3.20160316: The application encountered the following error: Could not find gem 'naif-spice' in any of the gem sources listed in your Gemfile. (Bundler::GemNotFound)
  Error ID: 34284127
  Error details saved to: /tmp/passenger-error-eykfMW.html

[ E 2020-05-07 22:37:26.7888 15066/T8 age/Cor/Con/CheckoutSession.cpp:276 ]: [Client 1-1] Cannot checkout session because a spawning error occurred. The identifier of the error is 34284127. Please see earlier logs for details about the error.
[ N 2020-05-07 22:37:29.2673 15066/T5 age/Cor/SecurityUpdateChecker.h:519 ]: Security update check: no update found (next check in 24 hours)
> an email to luna...@googlegroups.com.

Nick Estes

unread,
May 7, 2020, 10:47:16 AM5/7/20
to 俊黄, Lunaserv
The naif-spice gem still needs to be installed even if you don't think
you'll use it. Once you do that, the error you see should go away and
hopefully that's the last one.

--Nick
>> [1]). If
>> you already have an Apache or Nginx web server running, Passenger
>> can
>> install as a module into either of those web servers or for just
>> trying
>> out Lunaserv, Passenger in standalone mode is probably your best
>> bet.
>> The short version of how to do that is to install passenger with the
>>
>> command "gem install passenger", then you just go into the Lunaserv
>> directory (the directory that contains the config.ru [2] file) and
>> [3]
>> [4]
>
> --
> You received this message because you are subscribed to the Google
> Groups "Lunaserv" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to lunaserv+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com
> [5].
>
>
> Links:
> ------
> [1] https://www.phusionpassenger.com/
> [2] http://config.ru
> [3]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com
> [4]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [5]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&utm_source=footer

俊黄

unread,
May 8, 2020, 12:24:53 PM5/8/20
to Lunaserv
Dear Nick,
Thank you very much for your reply! It did go away as you predicted.

An additional issue shows up when I config layer in QGIS, which I filled http://0.0.0.0:3000/ in the URL. When I selected the sample layers provide by lunaserv website, and clicked add in the Data Source Manager | WMS/WMTS, the error message read:

Invalid layer: WMS provide Cannot calculate extent Raster layer Provider is not valid

The error message in the terminal is:

=============== Phusion Passenger Standalone web server started ===============
PID file: /home/jun/Downloads/lunaserv-3.20160316/passenger.3000.pid
Log file: /home/jun/Downloads/lunaserv-3.20160316/log/passenger.3000.log
Environment: development
Accessible via: http://0.0.0.0:3000/

You can stop Phusion Passenger Standalone by pressing Ctrl-C.
===============================================================================
I, [2020-05-09T00:15:03.027611 #23543]  INFO -- : Request for: / from 127.0.0.1 query: {}
I, [2020-05-09T00:15:03.071351 #23543]  INFO -- : Request completed in 0.043582156 seconds. Status: 302
[ N 2020-05-09 00:15:04.0960 23463/T5 age/Cor/SecurityUpdateChecker.h:519 ]: Security update check: no update found (next check in 24 hours)
I, [2020-05-09T00:21:09.044437 #23543]  INFO -- : Request for: / from 127.0.0.1 query: {"SERVICE"=>"WMS", "REQUEST"=>"GetCapabilities"}
I, [2020-05-09T00:21:09.101584 #23543]  INFO -- : Capabilities request
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: 
App 23543 output: map_calc_extents: not found
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found
App 23543 output: 
App 23543 output: sh: 1: map_calc_extents: not found

I appreciate your time!
Jun

Nick Estes

unread,
May 8, 2020, 12:27:14 PM5/8/20
to 俊黄, Lunaserv
0.0.0.0 is just a bind address that means the server is listening on all
network addresses on the system. If you're running qgis on the same
system as Lunaserv, try http://localhost:3000 and if it's running on a
different system, use the address or hostname of the system Lunaserv is
running on.

--Nick
>> [1]
>> [2]
>>>> [1]). If
>>>> you already have an Apache or Nginx web server running, Passenger
>>
>>>> can
>>>> install as a module into either of those web servers or for just
>>>> trying
>>>> out Lunaserv, Passenger in standalone mode is probably your best
>>>> bet.
>>>> The short version of how to do that is to install passenger with
>> the
>>>>
>>>> command "gem install passenger", then you just go into the
>> Lunaserv
>>>> directory (the directory that contains the config.ru [3] [2]
>> [4]
>>>> [3]
>>>>> [1].
>>>>>
>>>>>
>>>>> Links:
>>>>> ------
>>>>> [1]
>>>>>
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&utm_source=footer
>> [5]
>>>> [4]
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>
>>> Groups "Lunaserv" group.
>>> To unsubscribe from this group and stop receiving emails from it,
>> send
>>> an email to luna...@googlegroups.com.
>>> To view this discussion on the web visit
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com
>> [6]
>>> [4]
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;utm_source=footer
>> [7]
>>> [5]
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&utm_source=footer
>> [8]
>
> --
> You received this message because you are subscribed to the Google
> Groups "Lunaserv" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to lunaserv+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com
> [9].
>
>
> Links:
> ------
> [1]
> https://www.phusionpassenger.com/library/admin/standalone/troubleshooting/
> [2] https://www.phusionpassenger.com/
> [3] http://config.ru
> [4]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com
> [5]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [6]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com
> [7]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;amp;utm_source=footer
> [8]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [9]
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com?utm_medium=email&utm_source=footer

俊黄

unread,
May 9, 2020, 8:13:10 AM5/9/20
to Lunaserv
Good to know it. Many thanks.

I tried http://localhost:3000, and the error message in qgis is:

Invalid Layer: WMS provider Cannot calculate extent Raster layer Provider is not valid (provider: wms, URI: crs=EPSG:4326&dpiMode=7&format=image/png&layers=mars_viking&styles&url=http://localhost:3000/

The message in the terminal is:

=============== Phusion Passenger Standalone web server started ===============
PID file: /home/jun/Downloads/lunaserv-3.20160316/passenger.3000.pid
Log file: /home/jun/Downloads/lunaserv-3.20160316/log/passenger.3000.log
Environment: development
Accessible via: http://0.0.0.0:3000/

You can stop Phusion Passenger Standalone by pressing Ctrl-C.
===============================================================================
I, [2020-05-09T19:32:47.478848 #12311]  INFO -- : Request for: / from 127.0.0.1 query: {}
I, [2020-05-09T19:32:47.517463 #12311]  INFO -- : Request completed in 0.038154329 seconds. Status: 302
[ N 2020-05-09 19:32:53.6341 12234/T5 age/Cor/SecurityUpdateChecker.h:519 ]: Security update check: no update found (next check in 24 hours)
I, [2020-05-09T19:32:54.899521 #12311]  INFO -- : Request for: / from 127.0.0.1 query: {"SERVICE"=>"WMS", "REQUEST"=>"GetCapabilities"}
I, [2020-05-09T19:32:54.959972 #12311]  INFO -- : Capabilities request
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: 
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: 
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: 
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: 
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: 
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: 
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: 
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found
App 12311 output: sh: 1: 
App 12311 output: map_calc_extents: not found
App 12311 output: sh: 1: map_calc_extents: not found

Thank you!
Jun

俊黄

unread,
May 19, 2020, 11:19:14 AM5/19/20
to Lunaserv
Dear Nick,
Thank you very much for your help.

The error is due to that I DID not type make install after compiling.

Now it is working. Looks cool.

So do you have an example to show that how I can deploy the stamps like NAC images?

best,
Jun

Nick Estes

unread,
May 19, 2020, 2:15:44 PM5/19/20
to 俊黄, Lunaserv
How many stamps are you looking to use for this layer? There are two
ways of doing that type of layer depending on how many you will have.

--Nick


On 2020-05-19 08:19, 俊黄 wrote:
> Dear Nick,
> Thank you very much for your help.
>
> The error is due to that I DID not type make install after compiling.
>
> Now it is working. Looks cool.
>
> So do you have an example to show that how I can deploy the stamps
> like NAC images?
>
> best,
> Jun
>
> On Saturday, May 9, 2020 at 8:13:10 PM UTC+8, 俊黄 wrote:
>
>> Good to know it. Many thanks.
>>
>> I tried http://localhost:3000, and the error message in qgis is:
>>
>> Invalid Layer: WMS provider Cannot calculate extent Raster layer
>> Provider is not valid (provider: wms, URI:
>>
> crs=EPSG:4326&dpiMode=7&format=image/png&layers=mars_viking&styles&url=http://localhost:3000/
>> [14]
>>
>> The message in the terminal is:
>>
>> =============== Phusion Passenger Standalone web server started
>> ===============
>> PID file: /home/jun/Downloads/lunaserv-3.20160316/passenger.3000.pid
>> Log file:
>> /home/jun/Downloads/lunaserv-3.20160316/log/passenger.3000.log
>> Environment: development
>> Accessible via: http://0.0.0.0:3000/
>>
>> You can stop Phusion Passenger Standalone by pressing Ctrl-C.
>> Problems? Check
>>
> https://www.phusionpassenger.com/library/admin/standalone/troubleshooting/
>> [2]
>>> system as Lunaserv, try http://localhost:3000 [1] and if it's
>>> [2]
>>> [2]
>>> (https://www.phusionpassenger.com/ [3]
>>>>> [2]
>>>>>>> [1]). If
>>>>>>> you already have an Apache or Nginx web server running,
>>> Passenger
>>>>>
>>>>>>> can
>>>>>>> install as a module into either of those web servers or for
>>> just
>>>>>>> trying
>>>>>>> out Lunaserv, Passenger in standalone mode is probably your
>>> best
>>>>>>> bet.
>>>>>>> The short version of how to do that is to install passenger
>>> with
>>>>> the
>>>>>>>
>>>>>>> command "gem install passenger", then you just go into the
>>>>> Lunaserv
>>>>>>> directory (the directory that contains the config.ru [4] [3]
>>> [5]
>>>>> [4]
>>>>>>> [3]
>>>>>>>> [1].
>>>>>>>>
>>>>>>>>
>>>>>>>> Links:
>>>>>>>> ------
>>>>>>>> [1]
>>>>>>>>
>>>>>>>
>>>>>>
>>>>>
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&utm_source=footer
>>> [6]
>>>>> [5]
>>>>>>> [4]
>>>>>>
>>>>>> --
>>>>>> You received this message because you are subscribed to the
>>> Google
>>>>>
>>>>>> Groups "Lunaserv" group.
>>>>>> To unsubscribe from this group and stop receiving emails from
>>> it,
>>>>> send
>>>>>> an email to luna...@googlegroups.com.
>>>>>> To view this discussion on the web visit
>>>>>>
>>>>>
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com
>>> [7]
>>>>> [6]
>>>>>> [5].
>>>>>>
>>>>>>
>>>>>> Links:
>>>>>> ------
>>>>>> [1] https://www.phusionpassenger.com/ [3] [2]
>>> [5]
>>> [8]
>>>>> [7]
>>>>>> [5]
>>>>>>
>>>>>
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&utm_source=footer
>>> [9]
>>>>> [8]
>>>>
>>>> --
>>>> You received this message because you are subscribed to the
>>> Google
>>>> Groups "Lunaserv" group.
>>>> To unsubscribe from this group and stop receiving emails from
>>> it, send
>>>> an email to luna...@googlegroups.com.
>>>> To view this discussion on the web visit
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com
>>> [10]
>>>> [9].
>>>>
>>>>
>>>> Links:
>>>> ------
>>>> [1]
>>>>
>>>
>>
> https://www.phusionpassenger.com/library/admin/standalone/troubleshooting/
>>> [2]
>>>> [2] https://www.phusionpassenger.com/ [3]
>>>> [5]
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;utm_source=footer
>>> [8]
>>>> [6]
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com
>>> [7]
>>> [11]
>>>> [8]
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&amp;utm_source=footer
>>> [12]
>>>> [9]
>>>>
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com?utm_medium=email&utm_source=footer
>>> [13]
>
> --
> You received this message because you are subscribed to the Google
> Groups "Lunaserv" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to lunaserv+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/lunaserv/c4f01760-9ad7-495c-b279-20b95c5f6340%40googlegroups.com
> [15].
>
>
> Links:
> ------
> [1]
> http://www.google.com/url?q=http%3A%2F%2Flocalhost%3A3000&amp;sa=D&amp;sntz=1&amp;usg=AFQjCNHG6bI-J86lpl5lBnLnedt2nrRzuA
> [2]
> https://www.phusionpassenger.com/library/admin/standalone/troubleshooting/
> [3] https://www.phusionpassenger.com/
> [4] http://config.ru
> [5]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com
> [6]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [7]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com
> [8]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;amp;utm_source=footer
> [9]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [10]
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com
> [11]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;amp;amp;utm_source=footer
> [12]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&amp;amp;utm_source=footer
> [13]
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [14] http://localhost:3000/
> [15]
> https://groups.google.com/d/msgid/lunaserv/c4f01760-9ad7-495c-b279-20b95c5f6340%40googlegroups.com?utm_medium=email&utm_source=footer

俊黄

unread,
May 20, 2020, 1:54:03 AM5/20/20
to Lunaserv
Maybe hundreds for now. It would be more in the future.

Thanks,
Jun

俊黄

unread,
May 21, 2020, 12:29:53 PM5/21/20
to Lunaserv
We are thinking to have hundreds of HiRISE and CTX in our study region, and maybe later for the whole planet.

Nick Estes

unread,
May 21, 2020, 4:54:49 PM5/21/20
to 俊黄, Lunaserv
The best way to do it is by putting all the stamps into a database
(Lunaserv only supports Postgres out of the box). You can use doubles,
postgis, or pg_sphere for the geometry, and you can associate them with
a standard set of bins to speed up to lookup of which stamps overlap the
map request. Then you put your query in a stamp db layer to return the
files based on the map search so it attempts to render the smallest set
of stamps possible to fulfill the request.

Most of the settings in the layer config file such as name, description,
etc are self-explanatory, but the key settings for this type of layer
are:

:type: stamp_db
:stamp_query: "select path from stamps where bin_ids &&
'{#{BINS}}'::integer[] and #{CIRCLE_CLAUSE}"
:circle_clause: "and ps_footprint && scircle '<(#{CIRCLE_LON}d,
#{CIRCLE_LAT}d), #{CIRCLE_RADIUS}d>'"

The SQL is pretty free-form allowing you to construct the query for
however your data is stored, and you can read more in the stamp db layer
section of the Lunaserv configuration guide. You can also define
additional SQL clauses to do optional filtering or sorting based on
extra WMS parameters.

There is a bins.sql in the Lunaserv package that has the pg_sphere bins
that Lunaserv uses, and I've also attached the more current views for
both postgis and pg_sphere that do the same thing a bit more
efficiently. Lunaserv internally can come up with bin ids for each map
query on the fly without doing a lot of extra pixel math so sometimes
that can speed up the query, but the bins aren't required for use.
(Some postgis indexes are fast enough on their own.)

--Nick
>> [1]
>>>>> (https://www.phusionpassenger.com/ [3] [3]
>>>>>>> [2]
>>>>>>>>> [1]). If
>>>>>>>>> you already have an Apache or Nginx web server running,
>>>>> Passenger
>>>>>>>
>>>>>>>>> can
>>>>>>>>> install as a module into either of those web servers or for
>>>>> just
>>>>>>>>> trying
>>>>>>>>> out Lunaserv, Passenger in standalone mode is probably your
>>>>> best
>>>>>>>>> bet.
>>>>>>>>> The short version of how to do that is to install passenger
>>>>> with
>>>>>>> the
>>>>>>>>>
>>>>>>>>> command "gem install passenger", then you just go into the
>>>>>>> Lunaserv
>>>>>>>>> directory (the directory that contains the config.ru [4] [4]
>>>>>>>> [1] https://www.phusionpassenger.com/ [3] [3] [2]
>> [14]
>> [15]
>>> [2]
>>>
>>
> https://www.phusionpassenger.com/library/admin/standalone/troubleshooting/
>> [2]
>>> [3] https://www.phusionpassenger.com/ [3]
>> [5]
>>> [6]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com
>> [7]
>> [11]
>>> [9]
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&amp;utm_source=footer
>> [12]
>>> [10]
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com
>> [10]
>> [16]
>> [17]
>>> [13]
>>>
>>
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com?utm_medium=email&amp;utm_source=footer
>> [18]
>> [19]
>
> --
> You received this message because you are subscribed to the Google
> Groups "Lunaserv" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to lunaserv+u...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/lunaserv/b3af6f7b-2216-427d-a740-dcd2277dd688%40googlegroups.com
> [20].
>
>
> Links:
> ------
> [1] http://localhost:3000/
> https://groups.google.com/d/msgid/lunaserv/c4f01760-9ad7-495c-b279-20b95c5f6340%40googlegroups.com
> [15]
> http://www.google.com/url?q=http%3A%2F%2Flocalhost%3A3000&amp;amp;sa=D&amp;amp;sntz=1&amp;amp;usg=AFQjCNHG6bI-J86lpl5lBnLnedt2nrRzuA
> [16]
> https://groups.google.com/d/msgid/lunaserv/9784220b-33b6-4730-b322-6fd6b7b18051%40googlegroups.com?utm_medium=email&amp;amp;amp;amp;utm_source=footer
> [17]
> https://groups.google.com/d/msgid/lunaserv/d660be67-b8d4-4108-8dfb-4b6360e7d203%40googlegroups.com?utm_medium=email&amp;amp;amp;utm_source=footer
> [18]
> https://groups.google.com/d/msgid/lunaserv/8b64feae-4105-4f51-9c5b-5fcf3e59bd3b%40googlegroups.com?utm_medium=email&amp;amp;utm_source=footer
> [19]
> https://groups.google.com/d/msgid/lunaserv/c4f01760-9ad7-495c-b279-20b95c5f6340%40googlegroups.com?utm_medium=email&amp;utm_source=footer
> [20]
> https://groups.google.com/d/msgid/lunaserv/b3af6f7b-2216-427d-a740-dcd2277dd688%40googlegroups.com?utm_medium=email&utm_source=footer
ps_bins.sql
pg_bins.sql
Reply all
Reply to author
Forward
0 new messages