04 2024 档案

在qemu中配置pci bus和numa node亲和性
摘要:在多numa node的物理机中,pci bus常常是连接到其中一个numa上。如此,不同的numa节点访问该pci bus下的设备的访问速度是不同的。基于此常常要将访问该设备的负载绑定到对应的numa node上可以提供性能。 对于qemu虚拟机也可以模拟pci bus与numa之间的亲和性。在x 阅读全文

posted @ 2024-04-29 14:01 半山随笔 阅读(482) 评论(0) 推荐(0) 编辑

generated/autoconf.h: No such file or directory问题解决
摘要:编kernel module的时候碰到generated/autoconf.h: No such file or directory的问题。开始以为又是host上的库缺失,折腾许久,发现是kernel 源码没有生成自动生成的文件。 编译kernel module的时候,原始的kernel源码还不能作 阅读全文

posted @ 2024-04-28 16:34 半山随笔 阅读(740) 评论(0) 推荐(0) 编辑

“you are in emergency mode”的解决办法
摘要:You are in emergency mode. After logging in, type "journalctl -xb" to view system logs, "systemctl reboot" to reboot, "systemctl default" or "exit" to 阅读全文

posted @ 2024-04-28 12:48 半山随笔 阅读(3807) 评论(0) 推荐(0) 编辑

编译linux kernel预装工具list
摘要:对一个新系统,编译kernel需要预装很多工具,这里总结以下,一并安装。以ubuntu为例: apt update; apt install -y flex bison make build-essential libncurses-dev libssl-dev libelf-dev bc cent 阅读全文

posted @ 2024-04-26 19:43 半山随笔 阅读(21) 评论(0) 推荐(0) 编辑

给虚拟机镜像改密码
摘要:经常下载ubuntu cloud image,但是这个image没有密码,要想登陆需要先改一下密码。 sudo apt install libguestfs-tools virt-customize -a bionic-server-cloudimg-amd64.img --root-passwor 阅读全文

posted @ 2024-04-26 14:49 半山随笔 阅读(84) 评论(0) 推荐(0) 编辑

linux下cpu/mem的硬件拓扑
摘要:linux系统中,sysfs导出了很多系统硬件信息。cpu的拓扑即在其中。 cpu相关的拓扑信息位于/sys/devices/system/cpu下。 # ls /sys/devices/system/cpu cpu0 cpu1 cpufreq cpuidle crash_hotplug isola 阅读全文

posted @ 2024-04-18 14:23 半山随笔 阅读(88) 评论(0) 推荐(0) 编辑

gprofiler-performance-studio
摘要:一个性能监控工具,有时间看看怎么用 阅读全文

posted @ 2024-04-17 16:39 半山随笔 阅读(13) 评论(0) 推荐(0) 编辑

内存性能引发的程序性能恶化案例
摘要:在一台机器上测试spec。发现性能很差。使用top去看,发现cpu可以占满,但即便能占用大量cpu资源吞吐量却上不去。使用perf stat去看。 # perf stat -a -p 946806 PID/TID switch overriding SYSTEM ^C Performance cou 阅读全文

posted @ 2024-04-12 13:44 半山随笔 阅读(144) 评论(0) 推荐(0) 编辑

跨numa的内存带宽测试
摘要:如果服务器上有多个numa节点,访问不同numa的性能有较大的性能损失,这里提供一种测试跨numa带宽的方法。 测试工具使用lmbench,github链接:https://github.com/intel/lmbench.git clone编译好之后可以在bin下找到所有可用的子命令。可以使用下面 阅读全文

posted @ 2024-04-12 12:00 半山随笔 阅读(321) 评论(0) 推荐(0) 编辑

在centos上离线安装k8s
摘要:测试环境中很多是没有连外网的,在这种环境下安装k8s相对麻烦一点,本篇展示一下如何在没有外网的环境当中安装k8s。 为了在离线环境当中安装,需要额外准备一台可以连接外网的机器,且这台机器可以向离线机器传输文件,以下称之为外网机器。 安装k8s大致分为两步,安装binary文件包括kubectl,ku 阅读全文

posted @ 2024-04-09 10:28 半山随笔 阅读(1465) 评论(0) 推荐(0) 编辑

resize centos分区
摘要:下了一个centos cloud image准备扩容。首先使用qemu-img resize2fs $centos_image +100G。在虚拟机中挂在centos image,使用parted改变分区大小,最后一步是使用resize2fs来更新文件系统超级块。但是却报错: resize2fs / 阅读全文

posted @ 2024-04-02 14:50 半山随笔 阅读(37) 评论(0) 推荐(0) 编辑

< 2025年2月 >
26 27 28 29 30 31 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 1
2 3 4 5 6 7 8

导航

统计

点击右上角即可分享
微信分享提示