Skip to content

Commit 131e13f

Browse files
authored
Updated readme (#217)
1 parent c7d446e commit 131e13f

File tree

1 file changed

+13
-20
lines changed

1 file changed

+13
-20
lines changed

README.rst

Lines changed: 13 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -69,29 +69,14 @@ Run ``uname`` on two remote hosts in parallel.
6969
Native client
7070
**************
7171

72-
Starting from version ``1.2.0``, the default client in ``parallel-ssh`` has changed to the native clint which offers much greater performance and reduced overhead than the current default client.
72+
Starting from version ``1.2.0``, the default client in ``parallel-ssh`` has changed to the native client which offers much greater performance and reduced overhead.
7373

7474
The new default client is based on ``libssh2`` via the ``ssh2-python`` extension library and supports non-blocking mode natively. Binary wheel packages with ``libssh2`` included are provided for Linux, OSX and Windows platforms and all supported Python versions.
7575

7676
See `this post <https://parallel-ssh.org/post/parallel-ssh-libssh2>`_ for a performance comparison of the available clients.
7777

7878
The paramiko based client under ``pssh.clients.miko`` and the old ``pssh.pssh_client`` imports will be **removed** on the release of ``2.0.0``.
7979

80-
Default client:
81-
82-
.. code-block:: python
83-
84-
from pssh.clients import ParallelSSHClient
85-
86-
hosts = ['localhost', 'localhost']
87-
client = ParallelSSHClient(hosts)
88-
89-
output = client.run_command('uname')
90-
for host, host_output in output.items():
91-
for line in host_output.stdout:
92-
print(line)
93-
94-
9580
See `documentation <http://parallel-ssh.readthedocs.io/en/latest/ssh2.html>`_ for a feature comparison of the two clients.
9681

9782

@@ -133,9 +118,13 @@ Once all output has been gathered exit codes become available even without calli
133118
Linux
134119
0
135120
121+
**********************
122+
Waiting for Completion
123+
**********************
124+
136125
The client's ``join`` function can be used to wait for all commands in output object to finish.
137126

138-
After ``join`` returns, commands have finished and output can be read.
127+
After ``join`` returns, commands have finished and all output can be read without blocking.
139128

140129
.. code-block:: python
141130
@@ -167,7 +156,11 @@ Similarly, exit codes are available after ``client.join(output, consume_output=T
167156
0
168157
169158
170-
There is also a built in host logger that can be enabled to log output from remote hosts. The helper function ``pssh.utils.enable_host_logger`` will enable host logging to stdout.
159+
***************************
160+
Build in Host Output Logger
161+
***************************
162+
163+
There is also a built in host logger that can be enabled to log output from remote hosts for both stdout and stderr. The helper function ``pssh.utils.enable_host_logger`` will enable host logging to stdout.
171164

172165
To log output without having to iterate over output generators, the ``consume_output`` flag *must* be enabled - for example:
173166

@@ -213,7 +206,7 @@ See also documentation for SCP recv.
213206
SFTP
214207
*****
215208

216-
SFTP is supported natively. Performance is much slower than SCP due to underlying library limitations and SCP should be preferred where possible. In the case of the deprecated paramiko clients, several bugs exist with SFTP performance and behaviour - avoid if at all possible.
209+
SFTP is supported natively. In the case of the deprecated paramiko clients, several bugs exist with SFTP performance and behaviour - avoid if at all possible.
217210

218211
To copy a local file to remote hosts in parallel:
219212

@@ -311,7 +304,7 @@ In addition, ``parallel-ssh`` uses native threads to offload CPU blocked tasks l
311304

312305
Out of all the available Python SSH libraries, ``libssh2`` and ``ssh2-python`` have been shown, see benchmarks above, to perform the best with the least resource utilisation and ironically for a native code extension the least amount of dependencies. Only ``libssh2`` C library and its dependencies which are included in binary wheels.
313306

314-
However, it lacks support for some SSH features present elsewhere like ECDSA keys (`PR pending <https://github.com/libssh2/libssh2/pull/206>`_), agent forwarding (`PR also pending <https://github.com/libssh2/libssh2/pull/219>`_) and Kerberos authentication - see `feature comparison <http://parallel-ssh.readthedocs.io/en/latest/ssh2.html>`_.
307+
However, it lacks support for some SSH features present elsewhere like GSS-API and certificate authentication.
315308

316309

317310
********

0 commit comments

Comments
 (0)