ubuntu下安裝配置完drbd後啓動報錯, 查看版本信息:html
root@drbd2:~# drbdadm --version DRBD module version: 8.4.5 userland version: 8.4.4 you should upgrade your drbd tools! DRBDADM_BUILDTAG=GIT-hash:\ 599f286440bd633d15d5ff985204aff4bccffadd\ build\ by\ phil@fat-tyre\,\ 2013-10-11\ 16:42:48 DRBDADM_API_VERSION=1 DRBD_KERNEL_VERSION_CODE=0x080405 DRBDADM_VERSION_CODE=0x080404 DRBDADM_VERSION=8.4.4
ubuntu14.4.04 kernel中編譯的 drbd module 版本是 8.4.5, 而官方trusty所提供的drbd8-utils的版本只到8.4.4, 只能手動編譯了ubuntu
apt-get install flex
官方下載drbd-utils: http://oss.linbit.com/drbd/flex
root@ubuntu:~# tar -xf drbd-utils-latest.tar.gz -C /usr/src/ root@ubuntu:~# cd /usr/src/drbd-utils-8.9.6/ root@ubuntu:/usr/src/drbd-utils-8.9.6# ls autogen.sh configure COPYING drbd-headers Makefile.in scripts ChangeLog configure.ac documentation drbd.spec.in README user root@ubuntu:/usr/src/drbd-utils-8.9.6# ./configure --prefix=/usr/local/drbd-utils --sysconfdir=/etc/ root@ubuntu:/usr/src/drbd-utils-8.9.6# make root@ubuntu:/usr/src/drbd-utils-8.9.6# make install root@ubuntu:~# mkdir /usr/local/drbd-utils/var/run/drbd
make 後會報如下錯誤:ui
Userland tools build was successful. make -C documentation/v9 doc make[1]: Entering directory `/usr/src/drbd-utils-8.9.6/documentation/v9' xsltproc -o drbdsetup.xml drbdsetup.xsl drbdsetup.xml.in make[1]: xsltproc: Command not found make[1]: *** [drbdsetup.xml] Error 127 make[1]: Leaving directory `/usr/src/drbd-utils-8.9.6/documentation/v9' make: *** [doc] Error 2
此錯誤對drbd運行沒有影響, 提示安裝xsltproc可解決, 然而實際上又報了別的錯, 以下:.net
http://docbook.sourceforge.net/release/xsl/current/html/param.xsl:445: parser error : Premature end of data in tag stylesheet line 3 compilation error: file http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl line 24 element include xsl:include : unable to load http://docbook.sourceforge.net/release/xsl/current/html/param.xsl make[1]: *** [drbdsetup.8] Error 5 make[1]: Leaving directory `/usr/src/drbd-utils-8.9.6/documentation/v9' make: *** [doc] Error 2
此處的報錯貌似影響的是文檔, 文檔要在線下載卻又爬不動牆, 不影響軟件使用3d
Userland tools build was successful. make -C documentation/v9 doc make[1]: Entering directory `/usr/src/drbd-utils-8.9.6/documentation/v9' make -C ../../user/v9 drbdsetup make[2]: Entering directory `/usr/src/drbd-utils-8.9.6/user/v9' make[2]: `drbdsetup' is up to date. make[2]: Leaving directory `/usr/src/drbd-utils-8.9.6/user/v9' ../../user/v9/drbdsetup xml-help new-resource > drbdsetup_xml-help_new-resource.xml xsltproc -o drbdsetup_new-resource.xml xml-usage-to-docbook.xsl drbdsetup_xml-help_new-resource.xml make[1]: xsltproc: Command not found make[1]: *** [drbdsetup_new-resource.xml] Error 127 make[1]: Leaving directory `/usr/src/drbd-utils-8.9.6/documentation/v9' make: *** [doc] Error 2
無影響, 可忽略code