[tahoe-lafs-trac-stream] [Tahoe-LAFS] #2773: `tahoe create-node` should require `--location` and/or `--hostname`, and not autodetect

Tahoe-LAFS trac at tahoe-lafs.org
Thu Jun 30 03:57:53 UTC 2016


#2773: `tahoe create-node` should require `--location` and/or `--hostname`, and
not autodetect
--------------------------------+----------------------
     Reporter:  warner          |      Owner:  warner
         Type:  task            |     Status:  assigned
     Priority:  normal          |  Milestone:  1.13.0
    Component:  code-nodeadmin  |    Version:  1.11.0
   Resolution:                  |   Keywords:
Launchpad Bug:                  |
--------------------------------+----------------------
Description changed by warner:

Old description:

> This splits out the most user-visible aspect of #2491. The `create-node`
> commands that create listening nodes should always be told what hostname
> or IP address(es) to advertise, rather than guessing by using IP-address
> autodetection functions.
>
> That means the following commands should require a `--location=`
> argument:
>
> * create-node (when storage service is enabled)
> * create-introducer
> * create-key-generator
> * create-stats-gatherer
>
> These commands should also accept (but not require) a `--port=` argument,
> which says what port the server should listen on. These will be endpoint
> descriptors, so things like `tcp:12345`. Both location and port get
> written into tahoe.cfg. Unlike `--location=`, `--port=` is not mandatory,
> and the code should pick something sensible if it isn't provided.
>
> I'm undecided on what exactly counts as "sensible". One option is just to
> allocate a free one inside `create-node` (different for each server).
> Another is for use to choose a port number for Tahoe servers to listen on
> (now, in this ticket, maybe register it with IANA or something), and let
> the option default to that. A third is a hybrid: attempt to listen on the
> default port during `create-node` and record that (in tahoe.cfg) if that
> succeeds, but if it's already claimed by some other process, allocate and
> record a random one.
>
> Note: if the server is using a Tor "onion service", then the user should
> not be obligated to figure this out: the `--tor` option should provision
> and register the XYZ.onion location automatically. So `--location=` and
> `--port=` should *not* be required (and in fact should probably be
> rejected) if `--tor` is active.
>
> But for plain TCP locations, the server should stop trying to figure it
> out on its own, and have the node-constructing command get this
> information from the user.

New description:

 This splits out the most user-visible aspect of #2491. The `create-node`
 commands that create listening nodes should always be told what hostname
 or IP address(es) to advertise, rather than guessing by using IP-address
 autodetection functions.

 That means the following commands should require a `--location=` argument:

 * create-node (when storage service is enabled)
 * create-introducer
 * ~~create-key-generator~~ (deleted in #2783)
 * create-stats-gatherer

 These commands should also accept (but not require) a `--port=` argument,
 which says what port the server should listen on. These will be endpoint
 descriptors, so things like `tcp:12345`. Both location and port get
 written into tahoe.cfg. Unlike `--location=`, `--port=` is not mandatory,
 and the code should pick something sensible if it isn't provided.

 I'm undecided on what exactly counts as "sensible". One option is just to
 allocate a free one inside `create-node` (different for each server).
 Another is for use to choose a port number for Tahoe servers to listen on
 (now, in this ticket, maybe register it with IANA or something), and let
 the option default to that. A third is a hybrid: attempt to listen on the
 default port during `create-node` and record that (in tahoe.cfg) if that
 succeeds, but if it's already claimed by some other process, allocate and
 record a random one.

 Note: if the server is using a Tor "onion service", then the user should
 not be obligated to figure this out: the `--tor` option should provision
 and register the XYZ.onion location automatically. So `--location=` and
 `--port=` should *not* be required (and in fact should probably be
 rejected) if `--tor` is active.

 But for plain TCP locations, the server should stop trying to figure it
 out on its own, and have the node-constructing command get this
 information from the user.

--

--
Ticket URL: <https://tahoe-lafs.org/trac/tahoe-lafs/ticket/2773#comment:9>
Tahoe-LAFS <https://Tahoe-LAFS.org>
secure decentralized storage


More information about the tahoe-lafs-trac-stream mailing list