Ben Chuanlong Du's Blog

And let it direct your passion with reason.

Install GNU Utils Using Homebrew

Installing GNU tools is a way to try to get Linux command experience in macOS. However, not every Linux command has an identical-experience version in macOS. ** It is suggested that you use a Linux virtual machine if you really want to have Linux experience in macOS. ** Notice that some hardwares …

Parse TOML Files in Python

  1. There are 2 popular Python libraries tomlkit and toml for parsing TOML formatted files in Python. tomlkit is preferred to toml as it is more flexible and style-preserving.

  2. A TOML file always interpret a key (even a bare ASCII integer) as string. For this reason, a dict with numerical keys …

Things to Do After Installing Linux

Note: The tips here are for Debian-based Linux distributions (Debian, Ubuntu, LinuxMint, Pop!_OS, AntiX, etc.).

Debian Specific

  1. If you installed Debian without a desktop environment, and wants to install a customized desktop environment now, make sure to install a DE manager (e.g., gdm, lightdm, etc.) as well. without …

Process Big Data Using PySpark

  1. PySpark 2.4 and older does not support Python 3.8. You have to use Python 3.7 with PySpark 2.4 or older.

  2. It can be extremely helpful to run a PySpark application locally to detect possible issues before submitting it to the Spark cluster.

    #!/usr/bin/env bash …

Permission Issues when Installing Softwares in Linux

Sometime when you install softwares in Linux, you get an error message saying that you do not have permission while you used sudo or the root account. This probably means that you do not have full access to some installation files. An easy way to solve this problem is to …