Solved

Oracle XE database directory

Posted on 2006-11-13
12
2,063 Views
Last Modified: 2008-01-09
I just wanna learn more about oracle, download oracle xe and install it in mysql windows xp

the problem is when i try to deploy it in my class i don't know how to set directory for "database data" since default install of oracle in drive C.

Deepfreeze will delete any new data that come to database via web interface (http://127.0.0.1:8080/apex)

My question is how to configure directory of database data in oracle xe ? for example d:\oracle

thanks in advance



0
Comment
Question by:hendri2
  • 6
  • 4
  • 2
12 Comments
 
LVL 47

Expert Comment

by:schwertner
ID: 17929327
The Database Data are placed in the directory you choose for this.
It is pointed by ORACLE_BASE environment variable.
The software is placed in ORACLE_HOME directory.
You have to choose it also.

So an example is:
ORACLE_HOME in c:\oraclehome\
ORACLE_BASE in c:\oraclebase\
0
 

Author Comment

by:hendri2
ID: 17935512
Sorry, I'm not familiar with oracle configuration file , can you guide , which file do i have to edit . I'm mysql user . I can see c:\mysql\data all database user and mysql.cnf is place for changing setting of database data.
0
 
LVL 13

Assisted Solution

by:anand_2000v
anand_2000v earned 100 total points
ID: 17936444
If you have installed ORacle 10g Express edition want to remind you that XE will create a database in the name of XE and it will create the all thedefault  tablespaces and you can see all that in the path where you hav installed,

As you mentioned you have installed XE in c drive. Look into the c: oracle directory and if you get into that you will able to find the folder named oradata,if you open it you can able to find the datafiles into it,which is the physcial storage of database it will be logically named a tablespace which you can see by queriing thro sql.


 for getting the sql command line,

 go to,
 
 Start >> programs >> oracle 10g express edition >> run sql command line  ( open it )

 sql > conn sys/passwd as sysdba

 sql > connected to 10g express editon lik this you will get

after this

 if you isses


sql > select file_name,tablespace_name from dba_data_files ;

where file_name is the physical location where the datafiles resides

tablespace_name is the logical name representing it in database.

0
 
LVL 47

Expert Comment

by:schwertner
ID: 17936509
These parameters in Windows are created automatically and can be seen in the Registry, in the Oracle section.

MySQL is a simple DB. Oracle is corporate product.
To see the users you have to remember the password of the "root" SYS user. You have to find the tnsnames.ora file and to see the alias of the connection string (it is the SID name you gave the DB!!!)

Invoke SQL*Plus (either from Start menu or from ..../bin file)

SQL>connect sys/password@alias as sysdba

To see the users:

SQL>descr dba_users    --- show the structure of this view
SQL> select username from dba_users;  --- to see all user names

SQL>create user myuser identified by myuserpass; --- cerates a new user
SQL>connect myuser/myuserpass@alias    -- connects as the new user
0
 

Author Comment

by:hendri2
ID: 17936644
thank you anand_2000v and schwertner,

so I must change registry to force oracle to save file into d:\oracle for example ?

is there any other way to do it ?

thanks
0
 
LVL 13

Expert Comment

by:anand_2000v
ID: 17936846
may i know which files you are mentioning about ?
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 47

Accepted Solution

by:
schwertner earned 400 total points
ID: 17936874
No!
When yo plan to install a new instance you have to decide two major things:

A)  Where will be the Oracle software be placed. This directory (with many subdirectories) will be recorded automatically (in Windows!!)
in the registry entry ORACLE_HOME. This is the name of this disk location.


B) Where will be the Oracle datafiles (database) placed. The same   ... ORACLE_BASE.

These variables in Windows are automatically set (the GUI asks you).
Nevertheles (because on one computer can be many Oracle software sets)
the installer names the ORACLE_HOME (e.g. HOME1,  HOME2, ....) entries.
0
 

Author Comment

by:hendri2
ID: 17937162
MySQL has my.ini file

#This File was made using the WinMySQLAdmin 1.3 Tool

#Uncomment or Add only the keys that you know how works.

#Read the MySQL Manual for instructions


[mysqld]
skip-locking
skip-innodb
set-variable    = max_connections=16384
default-character-set=latin1
basedir=C:\AppServ/mysql
#bind-address=
datadir=C:\AppServ/mysql/data
#language=C:/AppServ/mysql/share/your language directory
#slow query log#=
#tmpdir#=
#port=3306
#set-variable=key_buffer=16M
[client]
default-character-set=latin1
[WinMySQLadmin]
user=mysql
password=mysql

datadir=C:\AppServ/mysql/data ==> place for all database file create by user

change to D:\mydata , restart mysql

I see, maybe I must install dedicated server for our student .

thank very much  for all reply



0
 
LVL 47

Expert Comment

by:schwertner
ID: 17937698
Yes, dedicated Oracle server for the students.
Create user for every student.

First create a tablespace for all students:

CREATE TABLESPACE students DATAFILE
  c:\....\students.dbf' SIZE 25M AUTOEXTEND ON NEXT 10M MAXSIZE UNLIMITED
LOGGING
ONLINE
PERMANENT
EXTENT MANAGEMENT LOCAL AUTOALLOCATE
BLOCKSIZE 8K
SEGMENT SPACE MANAGEMENT AUTO
FLASHBACK ON;

For every students (xxxx is ID):

CREATE USER stxxxx
  IDENTIFIED BY stxxxx
  DEFAULT TABLESPACE students;
 
  GRANT UNLIMITED TABLESPACE TO stxxxx;
  -- 1 Tablespace Quota for AUTHR
  ALTER USER stxxxx QUOTA UNLIMITED ON students;

GRANT create procedure, create session,create table,create type,create view,create synonym TO stxxxx;

Do this for every student.

I do the same for our students :)
0
 
LVL 47

Expert Comment

by:schwertner
ID: 17937713
Oracle has also init file - init....ora
But mainly it uses SPFILE.ora - but never change it by editor because the installation will colapse!!!!!!!!!!!!!!
0
 

Author Comment

by:hendri2
ID: 17938131
thanks schwertner,

very helpfull

if you don't mind would you share your server environment

we use freebsd 6.1 ,1GB memory, PIV 3.0G in Pre Entry Intel Board to  serve mysql and postgresql for appoximately 1000 student

I'm still study install process in freebsd since many tutorial use linux or windows :-(

0
 
LVL 47

Expert Comment

by:schwertner
ID: 17938752
Initially we tried to install Oracle on a small Sun server machine, but failed to do this, because
we hadn't enough space for the swap partition.
So were forced to install Oracle on Windows XP machine with 2 GB RAM and over 120 GB HDD.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Join & Write a Comment

Introduction A previously published article on Experts Exchange ("Joins in Oracle", http://www.experts-exchange.com/Database/Oracle/A_8249-Joins-in-Oracle.html) makes a statement about "Oracle proprietary" joins and mixes the join syntax with gen…
Cursors in Oracle: A cursor is used to process individual rows returned by database system for a query. In oracle every SQL statement executed by the oracle server has a private area. This area contains information about the SQL statement and the…
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now