Ben Chuanlong Du's Blog

It is never too late to learn.

Tips on NFS

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

  1. Make sure nfs service is not blocked. Check iptables and "/etc/hosts.allow".

  2. Make sure nfs service is running on the server.

    sudo service nfs-kernel-server start

  3. You can choose the version …

Tips on sshuttle

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

  1. sudo permission is required to run sshuttle.

  2. It's valid to run sshuttle more than once simultaneously on a single client machine, connecting to a different server every time, so you can …

Hands on the requests Module in Python

Comments

  1. It is suggested that you use the requests module instead of urllib unless you want to have minimal 3rd-party dependencies.

  2. Response.raise_for_status is a convenient method for raising an exception corresponding to the HTTP status code.

Hands on the Python Library notifiers

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Email

The function below is an example of sending email using the Python library notifiers.

import notifiers
notifiers.get_notifier("email").notify(
    from_="sender@domain.com",
    to=["recipient1@domain.com", "recipient2@domain …