Installation steps.
[Root @ DS-VM-Node190/tmp/] # mkdir-p/tmp/ruby
[Root @ DS-VM-Node190/tmp] # DOWNLOAD_URL = "http://mirrors.dwhd.org/Ruby/ruby "&&\
DOWNLOAD_URL = "$ (curl-Lks" $ {DOWNLOAD_URL} "| awk-PF '" ''{if ($2 ~ /^ [0-9] + \. [0-9] +/) a = $2} END {print "'$ DOWNLOAD_URL'/" }')"&&\
DOWNLOAD_URL = "$ (curl-s" $ {DOWNLOAD_URL} "| awk-PF '" ''{if ($2 ~ /^ Ruby. * xz $/) a = $2} END {print "'$ DOWNLOAD_URL'" }')"
# You can also use the official address.
# DOWNLOAD_URL = "https://cache.ruby-lang.org/pub/ruby "&&\
# DOWNLOAD_URL = "$ (curl-Lks" $ {DOWNLOAD_URL} "| awk-PF '" ''{if ($2 ~ /^ [0-9] + \. [0-9] +/) a = $2} END {print "'$ DOWNLOAD_URL'/" }')"&&\
# DOWNLOAD_URL = "$ (curl-s" $ {DOWNLOAD_URL} "| awk-PF '" ''{if ($2 ~ /^ Ruby. * xz $/) a = $2} END {print "'$ DOWNLOAD_URL'" }')"
[Root @ DS-VM-Node190/tmp] # curl-Lk $ DOWNLOAD_URL | tar-xJ-C/tmp/ruby -- strip-components = 1
[Root @ DS-VM-Node190/tmp] # cd/tmp/ruby/
[Root @ DS-VM-Node190/tmp/ruby] # yum install-y zlib-devel openssl-devel # If you do not install these two extension packages, it is still very troublesome
[Root @ DS-VM-Node190/tmp/ruby] #./configure -- prefix =/usr/local -- disable-install-rdoc
[Root @ DS-VM-Node190/tmp/ruby] # make-j $ (awk '/processor/{I ++} END {print I}'/proc/cpuinfo) & make install & cd & rm-rf/tmp/ruby
[Root @ DS-VM-Node190 ~] # Ruby-v
Ruby 2.4.0preview1 (trunk 55466) [x86_64-linux]
[Root @ DS-VM-Node190 ~] #