普通用户没有权限 ulimit, 修改打包名称变成 loongnix

This commit is contained in:
2024-08-15 16:03:10 +08:00
parent 8ac576be68
commit f4fd0189ed
3 changed files with 8 additions and 4 deletions

View File

@ -48,6 +48,8 @@ elif [ X"$kernel" == X"centos" ]; then
dist_version="CentOS"
elif [ X"$kernel" == X"openeuler" ]; then
dist_version="openEuler"
elif [ X"$kernel" == X"loongnix-server" ]; then
dist_version="loongnix"
else
dist_version="Platform"
fi

View File

@ -77,6 +77,8 @@ elif [[ -f "/etc/kylin-release" ]]; then
os_name="Kylin"
elif [[ -f "/etc/asianux-release" ]]; then
os_name="Asianux"
elif [[ -f "/etc/loongnix-release" ]]; then
os_name="loongnix"
else
os_name=$(lsb_release -d | awk -F ' ' '{print $2}'| tr A-Z a-z | sed 's/.*/\L&/; s/[a-z]*/\u&/g')
fi

View File

@ -200,10 +200,10 @@ function set_environment() {
then
echo 'export GS_CLUSTER_NAME=dbCluster' >> ~/.bashrc
fi
if [ X"$(grep 'ulimit -n 1000000' ~/.bashrc)" == X"" ]
then
echo 'ulimit -n 1000000' >> ~/.bashrc
fi
#if [ X"$(grep 'ulimit -n 1000000' ~/.bashrc)" == X"" ]
#then
# echo 'ulimit -n 1000000' >> ~/.bashrc
#fi
# set GAUSSHOME
path_env_line=$(cat ~/.bashrc | grep -n 'export PATH=$GAUSSHOME/bin:$PATH' | awk -F ':' '{print $1}')
ld_env_line=$(grep -n 'export LD_LIBRARY_PATH=$GAUSSHOME/lib:$LD_LIBRARY_PATH' ~/.bashrc | awk -F ':' '{print $1}')