linux系统安装oracle 11g时,由于希望复制配制文件 在修改/etc/profile文件添加内容时用了网上文件复制内容如下
if [$USER = "Oracle"] ; then
if [ $SHELL = " /bin/ksh" ]; then
suulimit -p 16384
ulimit -n 65535
else
ulimit -u 16384 -n 65536
fi
fi
有没有看出来 在if [$USER = "Oracle"] ; then
符号[ 与$user 之前没有空格 "oracle"与符号]也没空格
如果是 这样更换了profile文件那么你的linx系统将会出错如下
[root@localhost ~]# su - oracle
-bash: [oracle: command not found
这样你的安装oracle就加载不了用户的坏境变量 所有在安装oracle的时候要特别认真才行.
解决方案就是把那两个空格补上就好了 再用 source /etc/profile 立即生效再切换就正常了
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/27252036/viewspace-768684/
,如需转载,请注明出处,否则将追究法律责任。