@@ -29,7 +29,7 @@ matter which method you use to start your IPython cluster.
29
29
30
30
If you are running engines on multiple machines, you will likely need to instruct the
31
31
controller to listen for connections on an external interface. This can be done by specifying
32
- the ``ip `` argument on the command-line, or the ``HubFactory .ip `` configurable in
32
+ the ``ip `` argument on the command-line, or the ``IPController .ip `` configurable in
33
33
:file: `ipcontroller_config.py `.
34
34
35
35
If your machines are on a trusted network, you can safely instruct the controller to listen
@@ -42,8 +42,8 @@ Or you can set the same behavior as the default by adding the following line to
42
42
43
43
.. sourcecode :: python
44
44
45
- c.HubFactory .ip = '*'
46
- # c.HubFactory .location = 'controllerhost.tld'
45
+ c.IPController .ip = '*'
46
+ # c.IPController .location = 'controllerhost.tld'
47
47
48
48
49
49
.. note ::
@@ -78,7 +78,7 @@ hosts ``host1``-``hostn``. The following steps are then required:
78
78
79
79
1. Start the controller on ``host0 `` by running :command: `ipcontroller ` on
80
80
``host0 ``. The controller must be instructed to listen on an interface visible
81
- to the engine machines, via the ``ip `` command-line argument or ``HubFactory .ip ``
81
+ to the engine machines, via the ``ip `` command-line argument or ``IPController .ip ``
82
82
in :file: `ipcontroller_config.py `.
83
83
2. Move the JSON file (:file: `ipcontroller-engine.json `) created by the
84
84
controller from ``host0 `` to hosts ``host1 ``-``hostn ``.
@@ -364,7 +364,7 @@ connections on all its interfaces, by adding in :file:`ipcontroller_config`:
364
364
365
365
.. sourcecode :: python
366
366
367
- c.HubFactory .ip = '*'
367
+ c.IPController .ip = '*'
368
368
369
369
You can now run the cluster with::
370
370
@@ -532,14 +532,14 @@ slightly more complicated, but the underlying ideas are the same:
532
532
533
533
1. Start the controller on a host using :command: `ipcontroller `. The controller must be
534
534
instructed to listen on an interface visible to the engine machines, via the ``ip ``
535
- command-line argument or ``HubFactory .ip `` in :file: `ipcontroller_config.py `::
535
+ command-line argument or ``IPController .ip `` in :file: `ipcontroller_config.py `::
536
536
537
537
$ ipcontroller --ip=192.168.1.16
538
538
539
539
.. sourcecode :: python
540
540
541
541
# in ipcontroller_config.py
542
- HubFactory .ip = '192.168.1.16'
542
+ IPController .ip = '192.168.1.16'
543
543
544
544
2. Copy :file: `ipcontroller-engine.json ` from :file: `IPYTHONDIR/profile_<name>/security ` on
545
545
the controller's host to the host where the engines will run.
@@ -618,15 +618,15 @@ the engines.
618
618
619
619
[controller.host] $ ipcontroller --ip=192.168.1.16
620
620
621
- [IPControllerApp ] Using existing profile dir: u'/Users/me/.ipython/profile_default'
622
- [IPControllerApp ] Hub listening on tcp://192.168.1.16:63320 for registration.
623
- [IPControllerApp ] Hub using DB backend: 'ipyparallel.controller.dictdb.DictDB'
624
- [IPControllerApp ] hub::created hub
625
- [IPControllerApp ] writing connection info to /Users/me/.ipython/profile_default/security/ipcontroller-client.json
626
- [IPControllerApp ] writing connection info to /Users/me/.ipython/profile_default/security/ipcontroller-engine.json
627
- [IPControllerApp ] task::using Python leastload Task scheduler
628
- [IPControllerApp ] Heartmonitor started
629
- [IPControllerApp ] Creating pid file: /Users/me/.ipython/profile_default/pid/ipcontroller.pid
621
+ [IPController ] Using existing profile dir: u'/Users/me/.ipython/profile_default'
622
+ [IPController ] Hub listening on tcp://192.168.1.16:63320 for registration.
623
+ [IPController ] Hub using DB backend: 'ipyparallel.controller.dictdb.DictDB'
624
+ [IPController ] hub::created hub
625
+ [IPController ] writing connection info to /Users/me/.ipython/profile_default/security/ipcontroller-client.json
626
+ [IPController ] writing connection info to /Users/me/.ipython/profile_default/security/ipcontroller-engine.json
627
+ [IPController ] task::using Python leastload Task scheduler
628
+ [IPController ] Heartmonitor started
629
+ [IPController ] Creating pid file: /Users/me/.ipython/profile_default/pid/ipcontroller.pid
630
630
Scheduler started [leastload]
631
631
632
632
2. on each engine, fetch the connection file with scp::
@@ -711,15 +711,15 @@ Ports and addresses
711
711
In many cases, you will want to configure the Controller's network identity. By default,
712
712
the Controller listens only on loopback, which is the most secure but often impractical.
713
713
To instruct the controller to listen on a specific interface, you can set the
714
- :attr: `HubFactory .ip ` trait. To listen on all interfaces, specify:
714
+ :attr: `IPController .ip ` trait. To listen on all interfaces, specify:
715
715
716
716
.. sourcecode :: python
717
717
718
- c.HubFactory .ip = '*'
718
+ c.IPController .ip = '*'
719
719
720
720
When connecting to a Controller that is listening on loopback or behind a firewall, it may
721
721
be necessary to specify an SSH server to use for tunnels, and the external IP of the
722
- Controller. If you specified that the HubFactory listen on loopback, or all interfaces,
722
+ Controller. If you specified that the IPController listen on loopback, or all interfaces,
723
723
then IPython will try to guess the external IP. If you are on a system with VM network
724
724
devices, or many interfaces, this guess may be incorrect. In these cases, you will want
725
725
to specify the 'location' of the Controller. This is the IP of the machine the Controller
@@ -733,22 +733,22 @@ through the login node, an example :file:`ipcontroller_config.py` might contain:
733
733
# allow connections on all interfaces from engines
734
734
# engines on the same node will use loopback, while engines
735
735
# from other nodes will use an external IP
736
- c.HubFactory .ip = '*'
736
+ c.IPController .ip = '*'
737
737
738
738
# you typically only need to specify the location when there are extra
739
739
# interfaces that may not be visible to peer nodes (e.g. VM interfaces)
740
- c.HubFactory .location = '10.0.1.5'
740
+ c.IPController .location = '10.0.1.5'
741
741
# or to get an automatic value, try this:
742
742
import socket
743
743
hostname = socket.gethostname()
744
744
# alternate choices for hostname include `socket.getfqdn() `
745
745
# or `socket.gethostname() + '.local' `
746
746
747
747
ex_ip = socket.gethostbyname_ex(hostname)[-1][-1]
748
- c.HubFactory .location = ex_ip
748
+ c.IPController .location = ex_ip
749
749
750
750
# now instruct clients to use the login node for SSH tunnels:
751
- c.HubFactory .ssh_server = 'login.mycluster.net'
751
+ c.IPController .ssh_server = 'login.mycluster.net'
752
752
753
753
After doing this, your :file: `ipcontroller-client.json ` file will look something like this:
754
754
@@ -781,23 +781,23 @@ data types.
781
781
782
782
MongoDB `BSON doc <http://bsonspec.org/ >`_
783
783
784
- To use one of these backends, you must set the :attr: `HubFactory .db_class ` trait:
784
+ To use one of these backends, you must set the :attr: `IPController .db_class ` trait:
785
785
786
786
.. sourcecode :: python
787
787
788
788
# for a simple dict-based in-memory implementation, use dictdb
789
789
# This is the default and the fastest, since it doesn't involve the filesystem
790
- c.HubFactory .db_class = 'ipyparallel.controller.dictdb.DictDB'
790
+ c.IPController .db_class = 'ipyparallel.controller.dictdb.DictDB'
791
791
792
792
# To use MongoDB:
793
- c.HubFactory .db_class = 'ipyparallel.controller.mongodb.MongoDB'
793
+ c.IPController .db_class = 'ipyparallel.controller.mongodb.MongoDB'
794
794
795
795
# and SQLite:
796
- c.HubFactory .db_class = 'ipyparallel.controller.sqlitedb.SQLiteDB'
796
+ c.IPController .db_class = 'ipyparallel.controller.sqlitedb.SQLiteDB'
797
797
798
798
# You can use NoDB to disable the database altogether, in case you don't need
799
799
# to reuse tasks or results, and want to keep memory consumption under control.
800
- c.HubFactory .db_class = 'ipyparallel.controller.dictdb.NoDB'
800
+ c.IPController .db_class = 'ipyparallel.controller.dictdb.NoDB'
801
801
802
802
When using the proper databases, you can allow for tasks to persist from
803
803
one session to the next by specifying the MongoDB database or SQLite table in
@@ -868,9 +868,9 @@ Engine:
868
868
869
869
.. sourcecode :: python
870
870
871
- c.IPEngineApp .startup_script = u'/path/to/my/startup.py'
871
+ c.IPEngine .startup_script = u'/path/to/my/startup.py'
872
872
873
- c.IPEngineApp .startup_command = 'import numpy, scipy, mpi4py'
873
+ c.IPEngine .startup_command = 'import numpy, scipy, mpi4py'
874
874
875
875
These commands/files will be run again, after each
876
876
@@ -879,7 +879,7 @@ in some scratch directory. This can be set with:
879
879
880
880
.. sourcecode :: python
881
881
882
- c.IPEngineApp .work_dir = u'/path/to/scratch/'
882
+ c.IPEngine .work_dir = u'/path/to/scratch/'
883
883
884
884
885
885
0 commit comments