Home » Infrastructure » Unix » Adding Data_file
Adding Data_file [message #282626] Thu, 22 November 2007 12:17 Go to next message
youngb912
Messages: 44
Registered: October 2007
Location: New York
Member
Happy Thanksgiving to you all....

I need helping creating/adding datafile to a tablespace.
Below is the comman I have just used to create my logical volume. The logical volume is now created. I need to know how do I get the datafile created. I am using raw device as you can see. Or is the LV the datafile?

mklv -U oracle -G dba -P 600 -t raw -y rmandb_0032_003stagevg 1
Re: Adding Data_file [message #282694 is a reply to message #282626] Fri, 23 November 2007 00:59 Go to previous messageGo to next message
Michel Cadot
Messages: 59087
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
create tablespace
But if you don't know that, you have to first read Database Concepts

Regards
Michel
Re: Adding Data_file [message #282779 is a reply to message #282694] Fri, 23 November 2007 07:29 Go to previous messageGo to next message
youngb912
Messages: 44
Registered: October 2007
Location: New York
Member
I do know how to create tablespace. My question was "how to create datafile in AIX platform"?

Thanks

[Updated on: Fri, 23 November 2007 07:29]

Report message to a moderator

Re: Adding Data_file [message #282781 is a reply to message #282779] Fri, 23 November 2007 07:30 Go to previous messageGo to next message
Michel Cadot
Messages: 59087
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
How is this an Oracle question?
What is an AIX datafile. I only know files in Unix.
"touch filename" creates a file, for instance.

Regards
Michel

[Updated on: Fri, 23 November 2007 07:31]

Report message to a moderator

Re: Adding Data_file [message #282784 is a reply to message #282781] Fri, 23 November 2007 07:37 Go to previous messageGo to next message
youngb912
Messages: 44
Registered: October 2007
Location: New York
Member
Maybe, I needed to explain myself. Sorry for any confusion.
In Oracle database administration, (raw device in UNIX) a DBA is task with creating a datafile, creating tablespce and adding the datafile to the tablespace. In most shop a UNIX Administrator might do the datafile creation.

Firstly, I created the volume group
Next the logical volume
Later created a tablespace

My question now is how do I create a datafile to add to the the tablespace or is the logival volume preceded by a letter the datafile?

To answer this question you must be a dba with UNIX experience.

Re: Adding Data_file [message #282788 is a reply to message #282784] Fri, 23 November 2007 07:44 Go to previous messageGo to next message
Michel Cadot
Messages: 59087
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:

a DBA is task with creating a datafile

No never, this does not exist (but in very few recovery cases).

Quote:

creating tablespce and adding the datafile to the tablespace

Yes: create tablespace, alter tablespace

Quote:

In most shop a UNIX Administrator might do the datafile creation.

He does not have to "create tablespace" and "alter tablespace add" does it for you.

Regards
Michel


Re: Adding Data_file [message #282789 is a reply to message #282788] Fri, 23 November 2007 07:55 Go to previous messageGo to next message
youngb912
Messages: 44
Registered: October 2007
Location: New York
Member
Let me stretch my luck one more time!

Procedure I am following to add datafile to this tablespace base on my environment is:

CREATE a logical volume as root

1.
mklv -U oracle -G dba -P 600 -t raw -y rmandb_0032_003stagevg h1

RUN the following to add a datafile

2.
Alter tablespace tablespace_name add datafile ‘/dev/<device_name>’ seize ##;

In this case what will my device_name be? The device name is what I have been referring to as datafile all this time. I hope you understand my question now.

To rephrase….I have created the LV above and need to add a datafile to a tablespace. Where does the datafile name/device name come from?

Please send me any question that will enable you help me.

Thanks



[Updated on: Fri, 23 November 2007 07:57]

Report message to a moderator

Re: Adding Data_file [message #282793 is a reply to message #282789] Fri, 23 November 2007 08:11 Go to previous messageGo to next message
Michel Cadot
Messages: 59087
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Don't you have a sysadmin to do that?
Once again it is not an Oracle question but an Unix one.

Quote:

Where does the datafile name/device name come from?

Ask you SA to give it to you.

Regards
Michel
Re: Adding Data_file [message #282796 is a reply to message #282793] Fri, 23 November 2007 08:22 Go to previous message
youngb912
Messages: 44
Registered: October 2007
Location: New York
Member
I finally got everything done. The device I created while creating the logical volume is the one I aded to the tablespace as datafile....just preceded the device_name by r for raw.

Thanks moderator.....your responses gave me the courage to dig deeper.

[Updated on: Fri, 23 November 2007 09:07]

Report message to a moderator

Previous Topic: Helpless in basic shell sorting
Next Topic: Running multiple Oracle database instance on single machine
Goto Forum:
  


Current Time: Tue Sep 16 23:33:24 CDT 2014

Total time taken to generate the page: 0.05314 seconds