-
The order of precedence of operators in POSIX extended regular expression is as follows.
- Collation-related bracket symbols
[==],[::],[..] - Escaped characters
\ - Character set (bracket expression)
[] - Grouping
() - Single-character-ERE duplication
*,+,?,{m,n} - Concatenation
- Anchoring
^,$ - Alternation
|
- Collation-related bracket symbols
-
Some regular expression patterns are defined using a single leading backslash, e.g.,
\s,\b, etc. However, since special …
Check Whether a Linux Is Using upstart, systemd or SysV
The simplest way to check whether a Linux system is running systemd, upstart or SysV is by running the following command.
ps -p1 | grep "init\|upstart\|systemd"
References
How to determine which system manager is running on Linux System
PySpark Issue: Java Gateway Process Exited Before Sending the Driver Its Port Number
I countered the issue when using PySpark locally
(the issue can happen to a cluster as well).
It turned out to be caused by a misconfiguration of the environment variable JAVA_HOME in Docker.
References
PySpark: Exception: Java gateway process exited before sending the driver its port number
Best Filesystem Format for Cross-platform Data Exchanging
FAT32
FAT32 is an outdated filesystem. The maximum size for a single file is 4G. You should instead exFAT instead of FAT32 where possible.
exFAT
exFAT is great cross-platform filesystem that is support out-of-box by Windows, Linux and macOS. There is practically no limit (big enough for average users) on …
Fonts for Linux
-
ttf-arphic-uming,ttf-wqy-microhei,ttf-wqy-zenhei,xfonts-wqyandttf-opensymbolare some packages related to Chinese fonts. -
If you have Adobe Reader installed on your computer, you can use Adobe Chinese fonts for free.
-
To check Chinese fonts installed on your computer, you can use the command
fc-list :lang=zh-cn | sort. -
To install extra …
Search for Files in Command-line Using grep
The article
14 Practical examples of the grep command
has some good examples on how to use the grep command.
-
The Perl style (option
-P) regular expression is more powerful than the basic (default) and extended (option-E) regular expression. It is suggested that you use the perl style as …