Over time, the installation of Oracle and especially the free XE edition got simpler. Here are some tips how to make the process easier and solve some issues.
When you install the database, make sure that you use a UTF character set. This is not mandatary, but will prevfent some error messages. To check the setting, in Compiere log in as System Administrator, go to the Window Country and search for Japan. We have the Japanese states listed in Japanese. If you see squares or dots instead of the Japanese characters, you will also get now and then some character conversion errors.
Once the database is created in a certain character set, you cannot change that. If you want to fix it, export the Compiere user, drop the database and re-create it and import your data.
Connection errors
A typical one is: ORA-12516 TNS:listener could not find available handler with matching protocol stack. There are a few others and the common cause are insufficient resources.
You need to change some settings in the init.ora file. You do this by using the command line tool sqlplus connecting to the system account.
In Windows: Start - Programs - Oracle Database .. - Run SQL Command Line
C> sqlplus system/password
SQL> ... enter the following commands:
ALTER SYSTEM SET statistics_level = TYPICAL Comment='Compiere' SCOPE=BOTH
/
ALTER SYSTEM SET sga_max_size = 314572800 Comment='Compiere' SCOPE=SPFILE
/
ALTER SYSTEM SET sga_target = 314572800 Comment='Compiere' SCOPE=BOTH
/
ALTER SYSTEM SET open_cursors=900 Comment='Compiere' SCOPE=BOTH
/
ALTER SYSTEM SET processes=300 COMMENT='Compiere' SCOPE=SPFILE;
/
ALTER SYSTEM SET sessions=300 COMMENT='Compiere' SCOPE=SPFILE;
/
The above commands increase the memory size (SGA) used by Oracle to 300 MB, you can decrease it a bit if necessary. The next commands increase the number of connections. The settings here should be good for 10+ users, but you should not decrease the numbers below 200.
After entering the commands, reboot the box or re-start Oracle
In Windows: Start - Programs - Oracle Database .. - Stop Database / Start Database
There some sql commands to check your settings:
SELECT Name, Value, Description, IsDefault, Update_Comment
FROM v$parameter
WHERE Name LIKE '%cursor%' OR Name LIKE '%process%' OR NAME LIKE '%servers%' ORDER BY 1
/
SELECT Name, Value/1024/1024 "MB", Description, IsDefault, Update_Comment
FROM v$parameter
WHERE Name LIKE '%_pool_size' OR Name LIKE 'sga%'
/
You may want to check the file AfterImport.sql in the directory Compiere2/utils/oracle for a few more details.
Good connections ;-)
---------------------------
感谢原博主,博主地址:http://www.jorgjanke.com/cgi-bin/mt/mt-search.cgi?tag=Database&IncludeBlogs=1