1)在建立用戶的時候可能遇到下面的問題 useradd: warning: the home directory already exists. Not copying any file from skel directory into it. 原因: 系統(tǒng)添加用戶的標(biāo)準(zhǔn)步驟 1.編輯/etc/passwd與/etc/group 2.創(chuàng)建用戶主目錄 3.從/etc/skel拷貝文件與目錄 4.讓新用戶獲得其主目錄與文件的擁有權(quán)限 5.給新用戶一個密碼 <!--[if !ppt]--><!--[endif]-->
解決辦法: 依舊使用上面的腳本建用戶,然后手動拷貝配置文件(3個)到/home/oracle下。如: [root@esri ~]# cp /etc/skel/.bash_profile /home/oracle 或者刪掉用戶 重新建立 Useerdel –r 這樣就可以將家目錄等和用戶相關(guān)的信息全部刪掉 2)可能會遇到下面的錯誤 cannot restore segment prot after reloc: Permission denied 編輯/etc/sysconfig/selinux,找到: # This file controls the state of SELinux on the system. # SELINUX= can take one of these three values: # enforcing - SELinux security policy is enforced. # permissive - SELinux prints warnings instead of enforcing. # disabled - SELinux is fully disabled. SELINUX=enforcing 如果SELINUX已經(jīng)是 SELINUX=disabled,那么就不用改了,否則就把SELINUX=enforcing 注釋掉,新加一行: SELINUX=disabled 3)可能會遇到下面的錯誤: could not open parameter file '/home/app/oracle/product/11.2.0/db_1/dbs/initorcl.ora 這是因?yàn)樵?/font>oracle9i和oracle10g中,數(shù)據(jù)庫默認(rèn)將使用spfile啟動數(shù)據(jù)庫,如果spfile不存在,則就會出現(xiàn)上述錯誤。 解決方法: 將$ORACLE_BASE/admin/數(shù)據(jù)庫名稱/pfile目錄下的init.ora.012009233838形式的文件copy到$ORACLE_HOME/dbs目錄下initorcl.ora即可。(注:initorcl.ora中的oracle為你的實(shí)例名 ORACLE_SID Startup mount pfile=’ $ORACLE_HOME/dbs/initorcl.ora’ 創(chuàng)建一個實(shí)例進(jìn)行最后測試 注意:在數(shù)據(jù)庫操作中都是用oracle用戶執(zhí)行命令.
輸入
[oracle@computer ~]$ sqlplus /nolog
SQL*Plus: Release 11.1.0.6.0 - Production on Tue Dec 11 15:32:23 2007
Copyright (c) 1982, 2007, Oracle. All rights reserved.