- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: moving raw device to filesystem
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 03:29 AM
09-22-2002 03:29 AM
i have an oracle database that seets on raw devices .
i want to move this data to file systems .
i think that i need to create the a new logical colume and file system and to do a dd from the raw device to the raw device of the new filesystem , but what about all the file header of the file system ,
so i m lost .
how can it be done ( from someone that did it )
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 05:16 AM
09-22-2002 05:16 AM
Re: moving raw device to filesystem
Normally one would export the database, recreate your database in a filesystem, and then import.
I'm not sure that dd'ing a raw device file to some filename is going to work, but then again, I've never tried to either.
live free or die
harry
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 05:40 AM
09-22-2002 05:40 AM
Re: moving raw device to filesystem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 05:50 AM
09-22-2002 05:50 AM
Re: moving raw device to filesystem
I hit the submit button by mistake.
Doing a dd from the Oracle raw device to another raw device will (at best) create another raw Oracle database (and destroy the filesystem). I have not done a such database move but I think you must do a Oracle export, create a complete new database and import the data to the new database.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 08:55 AM
09-22-2002 08:55 AM
Re: moving raw device to filesystem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 09:46 AM
09-22-2002 09:46 AM
Re: moving raw device to filesystem
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 05:21 PM
09-22-2002 05:21 PM
Re: moving raw device to filesystem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 07:43 PM
09-22-2002 07:43 PM
SolutionThere is another way besides EXPORT/IMPORT. IT CAN BE DONE!
Below a quote from Oracle:
goal: How to convert datafile from raw device to file system
fact: Oracle Server - Enterprise Edition
fix:
Use RMAN to move datafiles from raw devices to file system.
1. Connect to the database:
$ sqlplus system/manager@orcl
2. Put the tablespace with the datafile, which should be converted, offline:
SQL> alter tablespace test_ts offline;
3. Start rman and connect it to the database:
$ rman nocatalog target rman/rman@orcl
4. Move the datafile to file system:
RMAN> run {
2> allocate channel c1 type disk;
3> copy datafile '/dev/raw1' to '/u01/oradata/orcl/test_ts.dbf';
4> }
5. Rename the moved datafile:
SQL> alter database rename file '/dev/raw1' to '/u01/oradata/orcl/test_ts.
dbf';
6. Put the tablespace back online:
SQL> alter tablespace test_ts online;
Notes:
======
1. If you are using RMAN as the backup tool then a backup after the performed
steps is recommended, because otherwise RMAN treats the copied file as a
backup.
2. Usually Oracle datafiles are moved from filesystem to raw devices using
the dd command. Using dd is the fastest method to accomplish it. However, it is
necessary to know how many blocks to skip in the raw device (e.g. it is
necessary to skip 64K on Tru64 Unix), so that the information necessary for
the Operating System is not overwritten. The information on how many blocks to
skip is different on the different platforms. Using RMAN there's no necessity
to know such platform specific information.
Hope this helps!
Best Regards
Yogeeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 10:42 PM
09-22-2002 10:42 PM
Re: moving raw device to filesystem
you can bring down the database take a full cold backup.
Then you can use dd to copy the data from the raw datafiles to filesystem.
Like
dd if=/dev/r.... of=
Then you can do a
svrmgr>statup mount
svrmgr>alter database rename file '
The above command is to move a single datafile to another location.
If you have multiple files for each datafile you have to repeat the step.
Then you can do a alter database open
svrmgr>alter database open
If you have datafiles on raw devices for only one or two non-system tablespaces then you can follow the link given by Yogeeraj.
Taking the tablespace offline,moving the datafiles and again bringing back the tablespace online.
Also if you have less number of users then you can take a user level export and import it.
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-22-2002 10:52 PM
09-22-2002 10:52 PM
Re: moving raw device to filesystem
First , thanks a lot for the reply .
i think that i will go with the way of T G Manikandan .
this was what i was thinking .
i will let you know which way i deside to do and if it work fine .
again thanks a lot for replying and helping me
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-23-2002 12:57 AM
09-23-2002 12:57 AM
Re: moving raw device to filesystem
You can even use cp instad of dd. Example:
cp
Good luck!
Marcin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2003 01:17 AM
09-01-2003 01:17 AM
Re: moving raw device to filesystem
Rman is the preferred way as id does not care about the lvm reserved blocks.
If you use dd, maybe you have to use dd skip=xx bs=xx.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2003 07:37 AM
09-01-2003 07:37 AM
Re: moving raw device to filesystem
Can you drop me a quick Email? (I could not find you in the HP ldap) Hein at hp dot com.
Bill: The only possible way to convert is to export the entire database. Note that the exported data may need a bit more space than the raw device since general-purpose HP-UX directories must be created.
I beg to differ, a block of data is a block of data. They are exactly the same whether in a file or on a raw device. The only gotcha is that raw devices (on some platforms) skip the disk header / label and thus when moving data you need to skip 64kb (dd skip / iseek / oseek).
I do agree that export/import is the only SUPPORTED way.
miki,
Just to satisfy our curiosity... why move?
Anyway, be sure to TRY with a TEST tablespace!
Just create a fresh (LVM) raw devive, plop in a table, transfer and see if you find your data back no?!
Also, check out the relatively unknown "TRANSPORTABLE TABLESPACES" as a supported way to perform bulk moves, and copies even between databases. (must have enterprise edition). See chapter 11 in the Database Administrators's guide: Managing Tablespaces... Transporting Tablespaces.
Finally, always use (soft) links for your DB files, such that you can avoid the 'alter database... rename' or 'create control file for'.
Regards,
Hein.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-01-2003 11:44 PM
09-01-2003 11:44 PM
Re: moving raw device to filesystem
Why are you saying I am wrong? Miki Leon was asking for a reply from a person who did it and I did it several times without any problem.
So nevertheless it is not a supported solution, you can use dd or even cp. It works.