Ben Chuanlong Du's Blog

And let it direct your passion with reason.

Configure SSH to Use a Proxy Server

Suppose you have a production server that you want to visit via SSH, however, it is not accessible directly. Instead, you have to visit it from a bastion/proxy server. You can configure SSH to use the bastion/proxy server when visiting the production server.

Host <production_server>
ProxyCommand ssh <proxy_server …

Use wget with Proxy

  1. If you don't already know the proxy in use (in your company), read the post Find out Proxy in Use to figure it out.

  2. Put the following lines into your wget configuration file, which is usually ~/.wget.

    use_proxy = on
    http_proxy = http://username:password@proxy_ip:port
    https_proxy = http://username:password@proxy_ip …

Parallel Computing Using Multithreading

  1. Not all jobs are suitable for parallel computing. The more comminication that threads has to make, the more dependent the jobs are and the less efficient the parallel computing is.

  2. Generally speaking, commercial softwares (Mathematica, MATLAB and Revolution R, etc.) have very good support on parallel computing.

Python

Please refer …

Copy SSH Public Key Using "ssh-copy-id"

You can use the following command to copy your SSH public key to a Linux server.

ssh-copy-id -i ~/.ssh/id_rsa.pub host_machine

However, if a Linux server runs the SSH deamon on a non default port (default is 22), you have to specify the port with option -p port. In …

Read CPU Temperature in Linux

First you have to install package "lm-sensors".

wajig install lm-sensors

To detect the cpu temperature, type the following command.

modprobe coretemp
sensors

For more instructions on this top, see nixCraft.