All Posts

  • Published on
    CentOS7 系统的 systemctl 服务介绍及示例。配置文件有[Unit]、[Service]、[Install]区块,分别用于定义元数据、服务配置和启动设置。给出两个服务配置示例及相关脚本,最后通过 systemctl daemon-reload 使其生效。
  • Published on
    CentOS7 优盘安装时出现“[sda] No Caching mode page found”,需耐心等待超时输出错误信息,找到 U 盘位置(如 sda4),修改安装选项第二行,将 inst.stage2 改为 hd:/dev/sda4:/,按 Ctrl+X 安装,安装后启动网络。
  • Published on
    CentOS6 is end-of-life with no more updates. Its online yum repos are archived. Options for running it include reinstalling with a newer version, converting to RHEL6, choosing a different distro. Doing nothing risks being hacked. Don't delay, migrate today.
  • Published on
    介绍 jemalloc C++实践,包括下载、解压、编译安装,给出 c++ 测试源码及 CMakeLists,展示编译测试过程和链接 jemalloc 的情况,还可通过环境变量配置满足特殊要求,相关内容可参考[https://github.com/jemalloc/jemalloc/blob/dev/TUNING.md]
  • Published on
    文章介绍 C++11 实现的 defer 功能,内部 lambda 表达式捕获引用,同一作用域先定义后执行。通过 define 及连接符使局部变量名唯一,使用起来方便,给出源码及用法示例,如在不同函数中使用 defer 输出特定信息。