Slashdot Mirror


Multi-Threaded SSH/SCP

neo writes "Chris Rapier has presented a paper describing how to dramatically increase the speed of SCP networks. It appears that because SCP relies on a single thread in SSH, the crypto can sometimes be the bottleneck instead of the wire speed. Their new implementation (HPN-SSH) takes advantage of multi-threaded capable systems dramatically increasing the speed of securely copying files. They are currently looking for potential users with very high bandwidth to test the upper limits of the system."

62 of 228 comments (clear)

  1. A likely story by sqldr · · Score: 5, Funny

    Hi, I've invented a new way of downloading pron^H^H^H^H^H^Hcopying files across a network. If you have uber bandwidth, please contact me urgently!

    --
    I wrote my first program at the age of six, and I still can't work out how this website works.
    1. Re:A likely story by slyn · · Score: 5, Insightful

      Makes you wonder how many innovations can either be directly attributed to or partially attributed to the distribution of porn (not (necessarily) that this is).

      VHS v Betamax comes to mind.

    2. Re:A likely story by harry666t · · Score: 2, Insightful

      Get a /real/ girl.

    3. Re:A likely story by shenanigans · · Score: 5, Insightful

      I think this story is interesting because it shows a general trend: increased focus on multi-threading. We will see much more of this in the future as multi-core and multi-processor systems become more common. This trend is driven not by porn though, but by that other big driving force behind the computer industry, gaming.

    4. Re:A likely story by neumayr · · Score: 2, Funny

      They're overrated..

      --
      Truth arises more readily from error than from confusion. -Francis Bacon
    5. Re:A likely story by empaler · · Score: 2, Funny

      AND they get pregnant.

    6. Re:A likely story by mikael · · Score: 5, Insightful

      People are always willing to pay more to be entertained that to be educated.

      Which explains why football players and movie stars will get paid more than the innovators that carried out the research to develop the broadcast technology that helped to make those stars famous.

      --
      Vintage computer adverts: http://www.vintageadbrowser.com/computers-and-software-ads
    7. Re:A likely story by Anonymous Coward · · Score: 2, Interesting

      ...what's wrong with looking at porn with a real girl?

    8. Re:A likely story by rapier1 · · Score: 5, Insightful

      Actually, this is one of the main reasons why we did this. If you look at where processor architectures are going they aren't necessarily increasing the pure computational power of each core as much as they are using more and more cores. If you are in a situation where you have a single threaded process that is CPU bound - like SSH can be - you'll find that throughput rates (assuming that you aren't network bound) will remain flat. In order to make full use of the available network capacity we'll have to start doing things like this. There is still a lot of work to be done but we're pleased by our progress so far.

    9. Re:A likely story by dodobh · · Score: 2, Interesting

      There's also message passing and event driven programming, which can be a much simpler model if done right. Multi threading tends to shared state, and that's bad for programmers.

      --
      I can throw myself at the ground, and miss.
    10. Re:A likely story by Mister+Whirly · · Score: 3, Funny

      Because slasdotters generally can either only afford to pay for the porn site, or pay for the girl, but not both.

      --
      "But this one goes to 11!"
    11. Re:A likely story by jovetoo · · Score: 3, Insightful

      It is rare that you can completely separate every context of every step of your processing. There is always some data that needs to be shared between the threads and they become bottlenecks. The faster you serve your requests, the worse the contention (waiting for a resource) and thus the inefficiency.

      It depends on the task at hand and on your architecture. A file or web server is less likely to encounter contention than for example an IRC server. The first requires some authentication and resource resolving through configuration data but the actual data can be send without interference from other requests. An IRC server requires constant lookups in the user database for routing information and this is likely to take longer than actually sending the messages (even without multi-threading). In these cases, you really have to think your locking scheme through or you will lose more time waiting for a lock than doing actual work - defeating much of the purpose of going MT.

      When it comes to architecture, multi threading is an option in your architecture, not an architecture in itself. There is no problem doing a multi-threaded event-driven architecture or a MT message passing architecture -- these are actually very effective. For some interesting reading about this, I would suggest you check out the SEDA white paper for a pretty in depth list of options and their goals.

      Why is it bad for programmers? Because locking is hard to do in itself and if your locking scheme is subobtimal it often requires a lot of work to change it afterwards.

    12. Re:A likely story by dodobh · · Score: 2, Informative

      This one perhaps? : Threads.pdf

      --
      I can throw myself at the ground, and miss.
  2. this is just what i've been looking for by Anonymous Coward · · Score: 2, Funny

    not that scp as-is isn'--stalled--

  3. Must be why rsync over ssh is much faster by MichaelSmith · · Score: 4, Insightful

    I get a lot of use out of ssh for moving files around and rsync is definitely the best way to do heavy lifting in this area. Improving scp would be good to. I can't wait to hear what Theo thinks about this. I don't see him as a fan of adding complexity to improve performance.

    Big scp copies through my wifi router used to cause kernel panics under netbsd current of about a year ago. I never had that problem running rsync inside ssh.

    1. Re:Must be why rsync over ssh is much faster by MichaelSmith · · Score: 4, Interesting

      There is definitely something funny(strange) about the way scp does bulk copies. It stops and starts. Other applications happily stream through encrypted ssh connections.

      And in my experience rsync is faster.

    2. Re:Must be why rsync over ssh is much faster by AnyoneEB · · Score: 3, Informative
      Unless your servers are running rsh, rsync is probably going to get routed through ssh, in which case it gets encrypted just like scp. ref:

      Secure Shell - The security concious of you out there would like this, and you should all be using it. The stream from rsync is passed through the ssh protocol to encrypt your session instead of rsh, which is also an option (and required if you don't use ssh - enable it in your /etc/inet.d and restart your inet daemon if you disabled it for security).
      --
      Centralization breaks the internet.
    3. Re:Must be why rsync over ssh is much faster by drinkypoo · · Score: 5, Interesting

      If you just want to copy some files from system to system in an encrypted fashion, then the BEST option by far is to use tar, and pipe it through ssh like so:

      tar cvfpz - * | ssh user@host '( cd /destination ; tar xvfpz - )

      This example will compress and encrypt your data before sending it; on the other end, the file is streamed to tar. This example requires GNU rar or a close facsimile.

      Now, if you want to UPDATE a directory, use rsync:

      rsync -av -e ssh * user@host:/destination/

      Because rsync will do partial checksums and send parts even of BINARY files if the whole file has not changed, and doesn't re-send unchanged files, rsync makes sense when updating a directory. But it provides no speedup benefit over using tar, and in fact the directory scans it does before the sync mean that it may actually be slower.

      Use scp only for copying single files, because you're right, scp chokes between each file.

      --
      "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
    4. Re:Must be why rsync over ssh is much faster by rapier1 · · Score: 3, Informative

      As a note, the changes are actually to SSH itself and not just SCP. So any application that uses SSH as a transport mechanism can see a performance boost. This isn't to say *every* user will. This is mainly geared towards high bandwidth delay product networks (greater than 1MB) or GigE LANs.

    5. Re:Must be why rsync over ssh is much faster by gazbo · · Score: 2, Informative

      SSH can, of course, be configured to compress automatically.

    6. Re:Must be why rsync over ssh is much faster by ComputerSlicer23 · · Score: 2, Informative

      tar cfpz - . | ssh user@host '( cd /destination ; tar xfpvz - )'

      I'd use a "." instead of *, it avoids shell line length problems, and will also copy hidden files... as someone who as learned this the hard way. Also in my experience, on anything faster then 10MB, don't bother with compression (it's really a CPU to network speed ratio, on transfers I did regularly that was the rule of thumb with P4 2.2Ghz Xeons). Also, I removed the "v" from the source tar, as it duplicates every file name twice and can be hard to read. I can't remember if ssh or tar had better compression, I know I tested both. It really just changed the tipping point of the CPU speed. I also used to use blowfish for the cipher as it was easier on the CPU if you were running out of CPU instead of network. On a Gigabit network, I always ran out of CPU first.

      I normally use -C instead of a subshell, but that's merely a matter of taste. I also use the technique in reverse quite often so I can untar on the destination machine as root.

      Kirby

    7. Re:Must be why rsync over ssh is much faster by timeOday · · Score: 2, Informative

      tar cpzf - * | ssh user@host " cd /destination ; tar xpzf - "
      You don't need a quoted pair of commands, just use tar's -C option

      ssh user@host.com tar -C /remote/path -cpzf - remotefile1 remotefile2 | tar -C /local/path -xvzp -

  4. Alternative solution for a trusted LAN by Diomidis+Spinellis · · Score: 5, Interesting

    If you want to speed up transfers and you're working on a LAN you trust (i.e. you don't worry about the integrity and confidentiality of the data passing through it), you can dramatically increase throughput using socketpipe. Although the initial socketpipe communication setup is performed through client-server intermediaries such as ssh(1), the communication channel that socketpipe establishes is a direct socket connection between the local and the remote commands. This eliminates not only the encryption/description overhead, but also the copying between your processes and ssh or rsh.

  5. Sweet! by miffo.swe · · Score: 5, Insightful

    I really hope this will make it into OpenSSH after some security auditing. The performance gains was pretty impressive. It will make ssh much more fun for rsync, backups and other times when i transfer large files. I also wonder if one cant get similar performance gains with normal ssh and for example forwarded X-windows. That would be very interesting indeed.

    --
    HTTP/1.1 400
    1. Re:Sweet! by Per+Wigren · · Score: 3, Informative

      Use NX instead of plain old remote DISPLAY or ssh's X11 forwarding or even VNC! It's silly fast! You get a perfectly usable desktop even on slow, high latency connections. The free edition is free as in GPL.

      --
      My other account has a 3-digit UID.
  6. Re:Alternative solution for a trusted LAN by upside · · Score: 4, Informative

    You can also use a cheaper cipher. From the ssh manpage:

    -c blowfish|3des|des
                              Selects the cipher to use for encrypting the session. 3des is
                              used by default. It is believed to be secure. 3des (triple-des)
                              is an encrypt-decrypt-encrypt triple with three different keys.
                              blowfish is a fast block cipher, it appears very secure and is
                              much faster than 3des. des is only supported in the ssh client
                              for interoperability with legacy protocol 1 implementations that
                              do not support the 3des cipher. Its use is strongly discouraged
                              due to cryptographic weaknesses.

    --
    I'm sorry if I haven't offended anyone
  7. To *have* such problems... by pla · · Score: 5, Interesting

    the crypto can sometimes be the bottleneck instead of the wire speed.

    Between two devices on my gigabit home LAN, the CPU barely even registers while SCP'ing a large file (and that with every CPU-expensive protocol option turned on, including compression). What sort of connection do these guys have, that the CPU overhead of en/decryption throttles the transfer???


    Coming next week: SSH compromised via a thread injection attack, thanks to a "feature" that only benefits those of us running our own undersea fiber.

    1. Re:To *have* such problems... by dm(Hannu) · · Score: 5, Informative

      They claim that the first bottleneck is actually flow control of buffers, which prevents utilizing full network bandwidth in normal gigabit connections. The threads will help only after this first bottleneck has been cleared. They have patches to fix both problems. The slashdot summary was therefore a bit inaccurate, and reading TFA certainly helps.

    2. Re:To *have* such problems... by totally+bogus+dude · · Score: 5, Interesting

      Have you measured your actual throughput on the file transfer? It tends to take a crapload of tuning to get anywhere near saturating gigabit, even if you're not using encrypted transfers.

      I wrote the bit below which I'll keep because it might be interesting to someone, but dm(Hannu) already mentioned the claw flaw in the logic behind the PP and article summary: if the CPU is the bottleneck, how could adding more threads possibly help?

      Just for a laugh I used scp to copy a 512 MB file from my file server to itself, an Athlon 3700+ running at 2.2ghz. I got about 18 megabytes / second out of it. I took a snapshot of top's output right at the end (97% complete) and the CPU usage was as follows:

      ssh: 48.6%
      sshd: 44.9%
      scp: 3.7%
      scp: 1.3%
      pdflush: 0.7%

      So this system was pretty much pegged by this copy operation, and it achieved less than a fifth the capacity of a gigabit network link. Obviously the system is capable of transferring data much faster than this; the source was a RAID-5 set of 5 new 500 GB drives, and the destination was a stripe across two old 40 GB drives. I'd also repeated the experiment a few times (and this was the fastest transfer I got) so it's likely the source file was cached, too.

      I do agree that there's probably more interesting and useful things to optimise (and make easy to optimise) than scp's speed, but I know for sure that scp'ing iso images to our ESX servers in a crapload slower than using Veeam's copy utility or the upload facility in the new version of Infrastructure Client (at least I think it's new, never noticed it before).

    3. Re:To *have* such problems... by mikael_j · · Score: 4, Interesting

      A possible problem source here is that you're also doing disk I/O, when transferring data on my home network I've noticed that rsyncing things for redundancy purposes I end up with a lot more CPU usage (even when reading from a RAID5 via a hardware controller) than if I just pump random data from one machine to another. I reommend you try just transferring random data and piping it directly to /dev/null on the receiving machine to see if there's any difference in CPU usage.

      /Mikael

      --
      Greylisting is to SMTP as NAT is to IPv4
    4. Re:To *have* such problems... by totally+bogus+dude · · Score: 2, Interesting

      True enough, but my main point was that getting to actual gigabit speeds in the first place is actually pretty difficult. Plus, I couldn't find an easy way to copy only X amount of "random" data via scp which was the point of the article. Regardless, copying data is rarely if ever a useful thing to do with scp, anyway.

    5. Re:To *have* such problems... by egede · · Score: 5, Informative

      The limitations of transfer rates for scp is often the round trip time that consumes time for confirmation of received packages. This is a serious issue for transfers from the Europe to the US West Coast (around 200 ms) or to Australia (around 400 ms). Having several parallel TCP streams can solve this problem and has been in use for many years for transfer of data in High Energy Physics. An example of such a solution is GridFTP http://www.globus.org/toolkit/docs/4.0/data/gridftp/.

    6. Re:To *have* such problems... by Andy+Dodd · · Score: 2

      Older implementations of TCP only allow for a 64 KB window size. (Older meaning "really old" - nearly any implementation in the last decade implements extensions that allow for much larger transmit/receive windows.)

      Many apps set fixed window sizes (incl. apparently standard SSH - the webpage implies 64K.)

      Linux can "autotune" window sizes, but most OSes don't, hence the need for an app to be able to specify a larger window.

      Even with larger window sizes, TCP congestion control starts breaking on networks with high speed and large BDP. For example, even with a BER of something like 1*10^-12, a gigabit connection will drop something like one packet per hour - on a gigabit connection with 400 ms latency, 1 hour is apparently about how long it will take for the congestion control algorithm to even ramp up to full wire speed. One packet drop and all of a sudden TCP throttles way back - hence the large amount of work on advanced congestion control algorithms that handle high BDP networks better. (Such as the current default algo in Linux, CUBIC.)

      Using multiple TCP streams works around this problem in a more cross-platform manner as it does not depend on the OS's TCP implementation getting tweaked.

      --
      retrorocket.o not found, launch anyway?
    7. Re:To *have* such problems... by rapier1 · · Score: 2, Informative

      > if the CPU is the bottleneck, how could adding more threads possibly help? This is actually a great question. On single core systems its very unlikely that the multi-threading aspect of our patch will be of much use to you. The stock version of SSH is, because of its design, unable to use more than one core regardless of how many cores you actually happen to have. Which means that you could have one core thats pegged by SSH and have other cores that are essentially running idle (if you look at the presentation we go into that after we address with window issues). What we've done is allow SSH to offload the heavy work (the encryption) onto other cores in order to make full use of the CPU resources available.

  8. Oblig applicable Dilbert by bigmouth_strikes · · Score: 4, Funny

    Wally: "My proposed work plan for the year is to stress-test our product under severe network conditions. I will accomplish this by downloading large image files from the busiest servers on the net."

    (PHB rejects suggestion)
    (later)

    Wally: "I was this close to making it my job to download naughty pictures."
    Dilbert : "It's just as well; I would have had to kill you."

    ( http://books.google.com/books?id=dCeVfKrZ-3MC&pg=PA77&source=gbs_selected_pages&cad=0_1&sig=xD5tmMhG1RcspLch8gCIJu8ro2U#PPA79,M1 )

    --
    Oh, I can't help quoting you because everything that you said rings true
  9. Linux kernel version 2.6.17 to 2.6.24.1 by arkarumba · · Score: 3, Funny

    Preferably, we would like to test it any very high bandwidth systems running Linux kernels version 2.6.17 to 2.6.24.1.

  10. Pretty much totaly incorrect summary by Eunuchswear · · Score: 5, Informative
    Almost all the improvements they talk about come from optimising TCP buffer usage. The summary of the fixes:

    HPN-13 A la Carte
    • Dynamic Windows and None Cipher
      This is a basis of the HPN-SSH patch set. It provides dynamic window in SSH and the ability to switch to a NONE cipher post authentication. Based on the HPN12 v20 patch.
    • Threaded CTR cipher mode
      This patch adds threading to the CTR block mode for AES and other supported ciphers. This may allow SSH to make use of multiple cores/cpus during transfers and significantly increase throughput. This patch should be considered experimental at this time.
    • Peak Throughput
      This patch modifes the progress bar to display the 1 second throughput average. On completion of the transfer it will display the peak throughput through the life of the connection.
    • Server Logging
      This patch adds additional logging to the SSHD server including encryption used...
    So the main part of the patch set is "It provides dynamic window in SSH and the ability to switch to a NONE cipher post authentication" and the only part that has to do with threading is marked "This patch should be considered experimental at this time".

    By the way, does anybody else think "the ability to switch to a NONE cipher post authentication" is pretty dodgy?
    --
    Watch this Heartland Institute video
    1. Re:Pretty much totaly incorrect summary by Arimus · · Score: 2, Informative

      By the way, does anybody else think "the ability to switch to a NONE cipher post authentication" is pretty dodgy?


      Not really, for some of the stuff I do via SSH: eg logging into my webhost to untar a patch and apply it the only part of the transaction I want to be secure is my initial password/key-exchange post authentication I really don't give a stuff who sees me type

      cd ~/www
      tar xvfz ~/patch.tar.gz
      or any of the other commands I type in. However it should be down to the admin of the system in the first place to decided whether to allow NONE down-grade (Either on system wide or per user/session basis) and then down to me as a user to decide whether to take advantage.

      --
      --- Users are like bacteria -> Each one causing a thousand tiny crises until the host finally gives up and dies.
    2. Re:Pretty much totaly incorrect summary by tbuskey · · Score: 2, Insightful

      By the way, does anybody else think "the ability to switch to a NONE cipher post authentication" is pretty dodgy?

      I'd like it when I tunnel a new SSH or scp through another SSH tunnel. We call it a sleeve. I've had to sleeve within a sleeve's sleeve before to get through multiple SSH gateways and firewalls to an inner system. You can tell ssh to use XOR but I'm not sure you can in scp.

      Of course, if speed is paramount, you can use netcat inside the sleeve(s) to copy files. No encryption of the netcat, but it's inside an encrypted sleeve so the stream is encrypted.

    3. Re:Pretty much totaly incorrect summary by rapier1 · · Score: 2, Informative

      Where the performance boost comes from is going to depend on a lot on the characteristics of the network path. If its a high bandwidth delay product path then the majority of the performance increase may very well come from the dynamic window sizing (this is application layer windowing by the way). However, if path has a low BDP and you are CPU bound then either the NONE cipher switch or the multi-threading may provide more of a performance increase than the window sizing. Alternatively, in some high BDP paths the windowing patch may speed up the transfer enough so that it becomes CPU bound at which point the threading and/or NONE cipher switch will allow the user to make full use of the network capacity. One of our test paths is a transatlantic GigE pipe. With the window patch and full encryption we were able to get around 300Mb/s and then we were CPU bound. When we used either the NONE cipher switch or the multi-threaded AES-CTR mode cipher our throughput increased to 700Mb/s.
      As for the dodgy aspect of the NONE cipher switching. I'll be the first to admit that its not a perfect solution. The authentication remains fully encrypted and you can't use the NONE switch in an interactive session which obviates some of the problems. However, it still, in some ways, is counter to the idea of SSH which is why we came up with the threaded cipher. If you are willing to accept the NONE cipher then you can use that but if you want full encryption then you can use the threaded AES-CTR mode cipher.

    4. Re:Pretty much totaly incorrect summary by rapier1 · · Score: 4, Informative

      As a note - while the NONE cipher switch turns off data encryption we do *not* disable the message authentication cipher (MAC). So each data packet is still signed and authenticated. If it detects any in transit modification of the packet the connection is immediately dropped.

  11. Hardware acceleration by AceJohnny · · Score: 4, Interesting

    I've been wondering, does there exist hardware accelerators usable by OpenSSL or GnuTLS? I work in embedded systems, and our chip includes a crypto and hash processor. I'm surprised nothing equivalent exists on modern PCs, or have I just not been looking in the right places?

    --
    Misleading titles? Inflammatory blurbs? Keep in mind that Slashdot is a tabloid.
    1. Re:Hardware acceleration by neumayr · · Score: 2, Informative

      There were crypto acceleration cards, but I think the market was fairly small. They made sense for sites with lots of https traffic, but nowadays general purpose cpus are blazingly fast compared to back then.
      So I guess they disappeared..

      --
      Truth arises more readily from error than from confusion. -Francis Bacon
    2. Re:Hardware acceleration by htd2 · · Score: 2, Interesting

      There are a number of vendors who supply PCI/e/x/etc crypto accelerators. However these are mostly targeted at servers where the overhead of serving up numerous encrypted streams of data is much higher than on a client PC.

      The Sun T1 and T2 processors in the T2000 and T5000 also have onchip crypto units 1 on the T2000 and 8 on the T5000 which accelerate OpenSSL traffic by offloading DES, AES, MD5 etc.

  12. Re:Alternative solution for a trusted LAN by KiloByte · · Score: 5, Informative

    Actually, it appears that (at least on Debian) AES is already the default. Selecting 3des gives tremendous slowdown; blowfish is somewhat slower than AES.

    Copying 100MB of data over 100mbit ethernet to a P2 350Mhz box (the slowest I got) gives:
    * 3des 1.9MB/s
    * AES 4.8MB/s
    * blowfish 4.4MB/s

    --
    The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
  13. Re:Alternative solution for a trusted LAN by Diomidis+Spinellis · · Score: 2, Informative
    Nc is useful, but it still involves the overhead of copying the data through it (once at the client and once at the server). Nowadays, in most settings this overhead can be ignored. But, given the fact that a well-behaved application will work with a socket exactly as well as with a pipe or a file descriptor, I thought it would be very elegant to be able to connect two instances of (say) tar through a socket. Hence the implementation of socketpipe. Socketpipe sets up the plumbing and then just waits for the programs to finish.

    This is the setup using nc:

    tar --pipe--> nc --socket--> nc --pipe--> tar

    and this is the setup that socketpipe arranges:

    tar --socket--> tar
  14. News just in! by j.a.mcguire · · Score: 5, Funny

    Crowds were shocked to discover that multi-threaded software runs faster on a multi-core system, it was hard to contain the excitement over the discovery which could revolutionise software development!

  15. Re:sftp and ASCII mode transfers by raynet · · Score: 2, Insightful

    The lack of ASCII transfer mode is a good thing. A LATIN15 transfer mode might be handy. Less time wasted and less confusion and complaints amongst my clients.

    --
    - Raynet --> .
  16. Old news? by Damocles+the+Elder · · Score: 2, Interesting

    Digging around for the best way to apply the patch without screwing up my portage updates, I came across a request for this to be merged into the portage back in 2005, and is apparently usable with the HPN useflag.

    Not that I'm that surprised to see this is old news, since they're apparently on major revision 13...

  17. Re:Alternative solution for a trusted LAN by Neil+Watson · · Score: 2, Informative

    Actually, it depends upon the SSH protocol. Both Debian and Cygwin have this to say:

            -c cipher_spec
                              Selects the cipher specification for encrypting the session.

                              Protocol version 1 allows specification of a single cipher. The
                              supported values are "3des", "blowfish", and
                              "des". 3des (triple-des) is an encrypt-decrypt-encrypt
                              triple with three different keys. It is believed to be secure.
                              blowfish is a fast block cipher; it appears very secure and is
                              much faster than 3des. des is only supported in the ssh client
                              for interoperability with legacy protocol 1 implementations that
                              do not support the 3des cipher. Its use is strongly
                              discouraged due to cryptographic weaknesses. The default
                              is "3des".

                              For protocol version 2, cipher_spec is a comma-separated list of
                              ciphers listed in order of preference. The supported ciphers are:
                              3des-cbc, aes128-cbc, aes192-cbc, aes256-cbc, aes128-ctr,
                              aes192-ctr, aes256-ctr, arc
                              four128, arcfour256, arcfour, blowfish-cbc, and cast128-cbc. The default is:

                                          aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,arcfour128,
                                          arcfour256,arcfour,aes192-cbc,aes256-cbc,aes128-ctr,
                                          aes192-ctr,aes256-ctr

  18. Multithreading waaay to go... by Crass+Spektakel · · Score: 2, Insightful

    Today you can buy a machine with eight cores, 8gb memory and 1tb harddrive for less than 2000. And most software will only use one core and a maximum of 2gb memory.

    WE NEED MULTITHREADING NOW BIG AND EVERYWHERE.

    Multithreading is maybe the biggest change in software development. In contrast to advanced command sets like MMX, SSE and so on it is not about some peep hole optimization, about replacing a bunch of x86_32 commands with some SSE commands, it is about changing the whole approach, finding new algorithms and redevelop much if not all software we are used to work with.

    And we are lightyears away from using appropiate software on on todays systems.

    See compressors: Most can't multithread at all. Those who can have more issues than the SCO buisness plan, eg reduced efficency, scale very bad, can't accept input from stdio or can't output on stdout. Basically compression should be a good starting point but even here todays solutions are incredible far behind the hardware.

    Also consider network communication, graphical interfaces, games, printing, non-enterprise realtime presentation and so on and so forth.

    The revolution is NOT here. People aren't even talking about it.

    --
    "Life is short and in most cases it ends with death." Sir Sinclair
  19. Re:Alternative solution for a trusted LAN by HAKdragon · · Score: 2, Interesting

    I may be speaking out of ignorance, but doesn't that defeat the point of SSH?

    --
    "Our opponent is an alien starship packed with atomic bombs. We have a protractor."
  20. Can't we all just get along? by piojo · · Score: 2, Interesting

    Okay, it's very simple.

    Encrypted and tunneled over SSH, rsync is spawned by a login shell at the other side:
    rsync /some/path myhost.com:my/directory

    Not encrypted, rsyncs daemon must be running at other end:
    rsync /some/path rsync://myhost.com/my/directory OR
    rsync /some/path myhost.com::my/directory

    --
    A cat can't teach a dog to bark.
  21. Re:FUNNY?! That's not funny, try for TRUE by Anonymous Coward · · Score: 5, Insightful

    I won't lie to you -- being a parent is no laughing matter. It is a ton of work. It can be amazingly stressful and expensive. I've been through periods that I look back on now and wonder how the hell I managed to pull through without going completely insane. But if you ask me, the rewards outweigh the difficulties ten to one.

    When your child first looks up at your face and you see actual recognition in her eyes... when you see all the blocks fall into place as she figures out how to do something for the first time... look, I know it sounds really sappy and smarmy, but seriously (srsly) it is absolutely indescribable. This thing started out as a bit of genetic code from two people, and now it is actually self-aware and sentient. How cool is that? What geek can't be astonished at these emergent properties, derived from a program more complicated than you can possibly imagine -- a program that has spontaneously evolved over time?

    And you get to see her mental map evolve. You watch branches get added to her decision tree. You observe as she learns how to acquire information, process it, and decide how to act upon it. And all the while, you mold her view of the world based on your interactions with her. I don't know about you, but I find that not only fascinating, but incredibly rewarding.

    Before my daughter was born, I was terrified too, and somebody had said these things to me, I would've said, "Yeah, okay, I'm sure it's great and all, but I'm sure you're exaggerating somewhat." That's because there is something that happens to you when it's your kid. There's some very ancient, very basic code that gets turned on in your brain that says "this life is your responsibility, and you must do everything you can to ensure its safety, survival, and growth". I can't explain it because I honestly believe it's something buried deep beneath the conscious mind.

    Whatever the case, if you honestly don't want the baby, for it's sake, put it up for adoption. Don't make it live a life with a father who doesn't care for it. I'm being absolutely serious here. Find a loving couple who are unable to have kids of their own.

    (Posting AC because this is way offtopic, and because there are a lot of single, selfish, bitter child-haters out there with mod points to burn... but I had to say something.)

  22. Re:Why not loopback? by Mr+Z · · Score: 2, Informative

    BDP is the bandwidth-delay product. BDP is one of the main things these patches address. Loopback has very, very little delay. You could, I suppose, add artificial delay over loopback, but now you're diverging further from the actual deployment scenario.

    The other thing is that when sender and receiver are the same host, you don't engage the full network stack (no ethernet queuing, for example, no dropped packets, etc. etc.), so you don't find out all the curve balls that TCP/IP will throw you.

    And yet another thing is that sender and receiver will compete for the same CPUs, and so whatever upper CPU bound you have with separate sender and receiver, you'll be at roughly half that (assuming send and receive are balanced) when both are on the same machine.

    --Joe
  23. Re:Alternative solution for a trusted LAN by forkazoo · · Score: 2, Interesting

    I may be speaking out of ignorance, but doesn't that defeat the point of SSH?


    SSH is one of those uberutilities that has a surprising amount of usefulness once you dig a bit. Sure, secure telnet functionality is great, and I use it a lot. But, I still use ssh on my own LAN where I don't really care about security. I use sshfs because it is easier and more convenient for me than bothering with Samba. SCP/SFTP to avoid bothering with ftp. I use it for forwarding ports between various machines, and I use it for forwarding X sessions. There are surely ways to accomplish all the same stuff that I use ssh (and the closely related stuff like scp) for without using ssh, but I'd just rather not bother about it.

    Defeating the point of ssh is like defeating the point of a morning star. No matter how dull you make the point, the other 99 of them will still clobber you in the face.
  24. Some comments from one of the authors by rapier1 · · Score: 5, Informative
    First off, thank you for taking the time to read down this far. There have been some very interesting and useful comments so far. Second, I need to point out that both Ben Bennett of PSC and Michael Stevens of CMU were instrumental in getting this patch written. Without them there would be no HPN-SSH patch. I also highly suggest that interested people go to the http://www.psc.edu/networking/projects/hpn-ssh and read about what we've done. There is a lot of good material in the papers and presentations section as well as the FAQ.

    A couple notes about the multi-threading: The main goal was to allow SSH to make use of multiple processing cores. The stock OpenSSH is, by design, limited to using one core. As such a user can encounter situations where they have more network capacity and more compute capacity but will be unable to exploit them. The goal of this patch was to allow users to make full use of the resources available too them. The upshot of this is that its best suited for high performance network and compute environments (The HPN in HPN-SSH stands for High Performance Networking). This doesn't mean it won't be useful to home users - only that they might not see the dramatic performance gains someone in a higher capacity environment might see. Its really going to depend on the specifics of their environment.
    Based on our research we decided the most effective way to do this would be to make the AES-CTR mode cipher multi-threaded. The CTR mode is well suited to threading because there is no inter block dependency and, even better, the resulting cypher stream is indistinguishable from a single threaded CTR mode cypher stream. As a result, we retain full compatibility with other implementations of SSH - you don't need to have HPN-SSH on both sides of the connection. Of course, you won't see the same improvements unless you do.
    We still see this as somewhat experimental because we've not yet implemented a way to allow users to choose between a single threaded AES-CTR and multi-threaded AES-CTR mode. As such users on single core machines - if using AES-CTR may see a decrease in performance. We suggest those users just make use of the AES-CBC mode instead (which is the default anyway). Also, you need to be able to support posix threads.
    Future work will involve pipelining the MAC routine and that should provide us with another 30% or so improvement in throughput.

    Also, its important to keep in mind that these improvements are *not* just for SCP but for SSH as a whole. People using HPN-SSH as a transport mechanism for rsync, tunnels, pipes, and so forth may also see considerable performance improvements. Additionally, the windowing patches don't necessarily require HPN-SSH to be installed on both ends of the connection. As long as the patch is installed on the receiving side (the data sink) you may (assuming you were previously window limited) see a performance gain.

    We welcome any comments, suggests, ideas, or problem reports you might have regarding the HPN-SSH patch. Go the website mentioned above and use the email address there to get in touch with us. This is a work in progress and we are doing what we can to enable line rate easy to use fully encrypted communications. We've a lot more to do but I hope what we've done so far is of use and value to the community.

  25. Comment removed by account_deleted · · Score: 2, Insightful

    Comment removed based on user account deletion

  26. Re:FUNNY?! That's not funny, try for TRUE by sgbett · · Score: 2, Insightful

    There's also other geek parents out there that know exactly where you are coming from. well said.

    --
    Invaders must die
  27. Re:FUNNY?! That's not funny, try for TRUE by empaler · · Score: 2, Insightful

    Yeah. Turns out 0.8% risk of pregnancy isn't as small as I thought it was.

  28. Re:FUNNY?! That's not funny, try for TRUE by empaler · · Score: 2, Informative

    No worries, she'll be right.

  29. Re:FUNNY?! That's not funny, try for TRUE by empaler · · Score: 4, Interesting

    Thank you for your very well-written reply, but I wasn't actually being all that serious. (No, the pregnancy was unplanned, and I am actually opposed to the idea of becoming a parent at my current place in life; however, after talking this over with the only other person to have any say in this (the mother), I've decided to go with it).

    Don't mistake my badly crafted joke for being completely ignorant of what's ahead of me; before the final decision came, I had consulted with friends who are also parents (carefully not discussing this with any of my single, singlemindedly free-roaming friends), and I am in no way in doubt that I will make this child a net benefit for the human race. There are simply too many rotten parents, spoilt children, miserable families and bad genes in the world for me to actually fail in that respect.
    Plus, living in Denmark*, the baby will have pretty good odds for a good life, my involvement notwithstanding.

    I am going to have a lot of fun making tech projects for my little one when that time comes, including audio books with his/her favourite bed time stories, video diaries of how the child evolves, and of course, teaching how to solder before the age of 5. How I survived until 15 without that knowledge eludes me to this day.

    *: Studies have shown that there is a tie for Country With Best Quality of Life; Denmark and Iceland. I've been to Iceland, and it smelled like rotten eggs. Denmark takes the lead.