william

Keep Calm and Markdown.

sublime4 注册码

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
vim /etc/hosts

# Sublime-Bypass
0.0.0.0 sublimetext.com
0.0.0.0 sublimemerge.com
0.0.0.0 sublimehq.com
0.0.0.0 telemetry.sublimehq.com
0.0.0.0 license.sublimehq.com
0.0.0.0 45.55.255.55
0.0.0.0 45.55.41.223


wget https://raw.githubusercontent.com/CITIZENSIXTYNINE/Sublime-Bypass/mistress/sublime-bypass.sh
sudo bash ./sublime-bypass.sh

## sublime4 -> Help -> Enter Licence

—– BEGIN LICENSE —–
Die Socialisten GmbH
10 User License
EA7E-800613
51311422 E45F49ED 3F0ADE0C E5B8A508
2F4D9B65 64E1E244 EDA11F0E F9D06110
B7B2E826 E6FDAA72 2C653693 5D80582F
09DCFFB5 113A940C 5045C0CD 5F8332F8
34356CC6 D96F6FDB 4DEC20EA 0A24D83A
2C82C329 E3290B29 A16109A7 EC198EB9
F28EBB17 9C07403F D44BA75A C23C6874
EBF11238 5546C3DD 737DC616 445C2941
—— END LICENSE ——

Linux coredump 设置

注意:需要有普通用户写入权限的路径。

1
2
3
4
5
6
7
8
## 查看当前配置
cat /proc/sys/kernel/core_pattern

## 临时
echo "/tmp/core-%e-%p-%t" > /proc/sys/kernel/core_pattern

## 使用 sysctl 设置
sysctl -w kernel.core_pattern=/tmp/core-%e-%p-%t
  • %% 单个%字符
  • %p 所dump进程的进程ID
  • %u 所dump进程的实际用户ID
  • %g 所dump进程的实际组ID
  • %s 导致本次core dump的信号
  • %t core dump的时间 (由1970年1月1日计起的秒数)
  • %h 主机名
  • %e 程序文件名

systemd 学习

Linux systemd 学习总结

simple vs oneshot:

When you are deciding which service type to choose between simple and oneshot, here is some guidance:

  • Does your service need to complete before any follow-up services run? Use oneshot.
  • Do your follow-up services need to be running while this service does? Use simple.
  • Is this a long-running service? Probably use simple.
  • Do you need to run this service only at shutdown? Use oneshot.
  • Do you need to have multiple separate commands to run? Use oneshot.
0%