- 准备安装包
cd /opt
#下载
wget http://mirrors.ustc.edu.cn/tdf/libreoffice/stable/6.1.2/rpm/x86_64/LibreOffice_6.1.2_Linux_x86-64_rpm.tar.gz)
wget http://mirrors.ustc.edu.cn/tdf/libreoffice/stable/6.1.2/rpm/x86_64/LibreOffice_6.1.2_Linux_x86-64_rpm_langpack_zh-CN.tar.gz
# 解压
tar xzvf LibreOffice_6.1.2_Linux_x86-64_rpm.tar.gz
tar xzvf LibreOffice_6.1.2_Linux_x86-64_rpm_langpack_zh-CN.tar.gz
- 安装
yum install /opt/LibreOffice_6.1.2_Linux_x86-64_rpm/RPMS/*.rpm
yum install /opt/LibreOffice_6.1.2_Linux_x86-64_rpm_langpack_zh-CN/RPMS/*.rpm
3.自启动
# 启动命令
/usr/bin/libreoffice6.1 --headless --accept="socket,host=127.0.0.1,port=8100;urp;" --nofirststartwizard
#修改启动脚本
vim /etc/rc.d/rc.local
#末尾添加
/usr/bin/libreoffice6.1 --headless --accept="socket,host=127.0.0.1,port=8100;urp;" --nofirststartwizard
#脚本授权
chmod +x /etc/rc.d/rc.local
重启检查 LibreOffice 是否启动
ps -ef|grep libreoffice
root 1110 1104 0 16:53 ? 00:00:00 /opt/libreoffice6.1/program/oosplash --headless --accept=socket,host=127.0.0.1,port=8100;urp; --nofirststartwizard
root 1152 1110 0 16:53 ? 00:00:00 /opt/libreoffice6.1/program/soffice.bin --headless --accept=socket,host=127.0.0.1,port=8100;urp; --nofirststartwizard
root 1679 1507 0 17:07 pts/1 00:00:00 grep --color=auto libreoffice
网友评论