CACTI中文设备名称不显示,是因为LINUX系统没有中文字库,安装就可以了
安装中文字体库
安装相关软件,我是在DEBIAN上安装的,安装的中文版本,相关软件都安装了
建立存放中文字体库的文件夹
# cd /usr/shared/fonts
# mkdir chinese
将字体上传到/usr/shared/fonts/chinese
我这里就只安装个华文楷体和宋体,上传方式就不细说了。
执行ttmkfdir命令
# ttmkfdir -e /usr/share/X11/fonts/encodings/encodings.dir
因为cacti指定的字体库也没有在配置文件内指定,我估计不做下面这一步也是可以的,但我就不测试了。
修改字体配置文件
# vim /etc/fonts/fonts.conf
增加红色框内一行,字库位置
刷新字体库缓存
# fc-cache
查询已经安装字体
[root@localhost]# fc-list
/usr/share/fonts/dejavu/DejaVuSansCondensed-Oblique.ttf: DejaVu Sans,DejaVu Sans Condensed:style=Condensed Oblique,Oblique
/usr/share/fonts/dejavu/DejaVuSansCondensed-Bold.ttf: DejaVu Sans,DejaVu Sans Condensed:style=Condensed Bold,Bold
/usr/share/fonts/chinese/simsun.ttc: SimSun,宋体:style=Regular,常规
/usr/share/fonts/chinese/STKAITI.TTF: STKaiti:style=Regular
/usr/share/fonts/dejavu/DejaVuSans.ttf: DejaVu Sans:style=Book
/usr/share/fonts/chinese/simsun.ttc: NSimSun,新宋体:style=Regular,常规
/usr/share/fonts/dejavu/DejaVuSans-Bold.ttf: DejaVu Sans:style=Bold
/usr/share/fonts/dejavu/DejaVuSansCondensed.ttf: DejaVu Sans,DejaVu Sans Condensed:style=Condensed,Book
/usr/share/fonts/dejavu/DejaVuSans-ExtraLight.ttf: DejaVu Sans,DejaVu Sans Light:style=ExtraLight
/usr/share/fonts/dejavu/DejaVuSansCondensed-BoldOblique.ttf: DejaVu Sans,DejaVu Sans Condensed:style=Condensed Bold Oblique,Bold Oblique
/usr/share/fonts/dejavu/DejaVuSans-Oblique.ttf: DejaVu Sans:style=Oblique
/usr/share/fonts/dejavu/DejaVuSans-BoldOblique.ttf: DejaVu Sans:style=Bold Obliqu
打开CACTI,就可以显示设备的中文名称了!
- 上一篇:debian中安装cacti的坑
- 下一篇:debian下宝塔面板安装cacti
发表评论: