SRS如何在麒麟V10系统上部署
众所周知,麒麟V10是一个类Centos7系统,所以要在麒麟V10操作系统上部署srs,只需要下载所需要的centos7版本就可以。
我所使用的版本是srs-server-4.0-b10.tar.gz。
首先使用
tar -zxvf srs-server-4.0-b10.tar.gz
将压缩包解压,然后通过
cd srs-server-4.0-b10.tar.gz/trunk
进入到trunk目录下,使用
./configure
编译时,报错Your OS Linux is not supported。
通过查找srs安装文件,发现在/trunk/auto/depends.sh中
if [[ $OS_IS_UBUNTU = NO && $OS_IS_CENTOS = NO && $OS_IS_OSX = NO && $SRS_CROSS_BUILD = NO ]]; then
echo "Your OS `uname -s` is not supported."
exit 1
fi
这一行提示的报错信息,这是由于脚本在执行时会通过/etc/redhat-release来查询所部署的系统是属于Cesntos还是Ubuntu。由于所部署的系统是麒麟V10的国产化系统,没有/etc/redhat-release这个文件,所以需要改一下脚本,让软件默认为在centos上安装,只需要将脚本中
if [[ ! -f /etc/redhat-release ]]; then
return 0;
fi
注释掉就可以。