- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Migrate Old FileSystem to new 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
Discussions
Discussions
Discussions
Forums
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
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
тАО03-28-2006 09:47 PM
тАО03-28-2006 09:47 PM
# bdf
Filesystem kbytes used avail %used Mounted on
/dev/vg00/lvol3 204800 140128 64560 68% /
/dev/vg00/lvol1 298928 214936 54096 80% /stand
/dev/vg00/lvol8 4710400 4426560 28215294% /var
/dev/vg00/lvol7 2244608 1305632 93166458% /usr
/dev/vg00/lvol4 204800 8912 194576 4% /tmp
/dev/vg00/lvol6 2727936 2418512 30704889% /opt
/dev/vg00/lvol5 24576 2336 22072 10% /home
/dev/vg01/lvol1 18432000 14461856 3924392 79% /db
/dev/vg01/lvol2 16384000 11346282 4894200 70% /app
/dev/vg02/lvol1 46080000 3680 45716360 0% /db1
/dev/vg02/lvol2 24576000 19035464 5454008 78% /app1
I want to copy out all content in /db FS to the new /db1 FS. How can i do this? tar? cpio?
in /db contains the oracle db server daemon, so after copyying all the files, how can i mount back /db1 as /db?
I'm seeking guru's help as i'm new in HP-ux.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-28-2006 09:59 PM
тАО03-28-2006 09:59 PM
Re: Migrate Old FileSystem to new FIleSystem
please have aread of thread:
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=786133
In summary:
Copy old filesystem to the new filesystem (via tar, cpio or cp -pr)
Then edit the fstab file to rename the mount point.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-28-2006 10:00 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-28-2006 10:00 PM
тАО03-28-2006 10:00 PM
Re: Migrate Old FileSystem to new FIleSystem
If you can stop the applications during operations, this could be done by:
- backup to tape (e.g. dump, fbackup)
- restore to new device (e.g. restore, frecover)
- umount /db
- mount /dev/vg02/lvol1 /db
Another way, (possibly on-line if using On-line JFS), would be to extend /dev/vg01, /dev/vg01/lvol1, /db instead of moving to a new vg.
consider lvextend, fsadm commands for that.
antonio.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-28-2006 10:11 PM
тАО03-28-2006 10:11 PM
Re: Migrate Old FileSystem to new FIleSystem
I'm thinking of using ur method. In this case, can i use these cmd?
# cd /db
# find . ├в depth |cpio ├в pvd /db1
then, in fstab can i swap the mountpoint for /db to /db1 and /db1 to /db? like this:
/dev/vg01/lvol1 18432000 14461856 3924392 79% /db1
/dev/vg01/lvol2 16384000 11346282 4894200 70% /app
/dev/vg02/lvol1 46080000 3680 45716360 0% /db
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-28-2006 10:24 PM
тАО03-28-2006 10:24 PM
Re: Migrate Old FileSystem to new FIleSystem
find . ├Г┬в├В ├В depth |cpio ├Г┬в├В ├В pvd /db1
It is a bit difficult to read your command options, use the -u and the -m too otherwise your file dates will be changed.
I normaly use
find . | cpio -pcmudv
can i swap the mountpoint for /db to /db1 and /db1 to /db?
Yes you are correct.
Robert-Jan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-28-2006 10:39 PM
тАО03-28-2006 10:39 PM
Re: Migrate Old FileSystem to new FIleSystem
it should look like this
#find .-depth |cpio -pvd /db1
so for safety, i should execute this cmd
#find .-depth |cpio -pvdmu /db1
and 1 more thing, if i want to change the /db1 mount point to other name, can i just simply change it in fstab? for example
change the name /db1 mountpoint to /newfs mountpoint?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-28-2006 10:49 PM
тАО03-28-2006 10:49 PM
Re: Migrate Old FileSystem to new FIleSystem
before change:
/dev/vg01/lvol1 /db vxfs largefiles,rw,suid 0 2
/dev/vg02/lvol1 /db1 vxfs log,nodatainlog,largefiles,rw,suid 0 2
after change:
/dev/vg01/lvol1 /db1 vxfs largefiles,rw,suid 0 2
/dev/vg02/lvol1 /db vxfs log,nodatainlog,largefiles,rw,suid 0 2
Just don't forget to unmount the filesystems :-)
so umount -> change fstab -> mount
Best regards,
Robert-Jan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-29-2006 12:41 AM
тАО03-29-2006 12:41 AM
Re: Migrate Old FileSystem to new FIleSystem
first shutdown the oracle databae
then take the backup of /db from root
#tar -cvf
then
#umount /db
#umount /db1
#vi /etc/fstab
change the mount point of /dev/vg02/lvol1 from db1 to db
and comment (put one# in front of /dev/vg01/lvl1 entry)
and save the modified /etc/fstab
#mount -a
and
restore thae backup from tha tape using tar-xvf
up the oracle database
please enable all the largefiles support options in /etc/fstab
regards
Baiju Kumar.B
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-29-2006 11:03 AM
тАО03-29-2006 11:03 AM
Re: Migrate Old FileSystem to new FIleSystem
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-29-2006 11:11 AM
тАО03-29-2006 11:11 AM
Re: Migrate Old FileSystem to new FIleSystem
I'd much rather do a disk-to-disk copy than disk-to-tape-to-disk copy. It's faster and less likely to have errors.
I've used the 'cpio' method many times to migrate data from one set of disks to another as Robert-Jan shows.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-29-2006 10:27 PM
тАО03-29-2006 10:27 PM
Re: Migrate Old FileSystem to new FIleSystem
From his post:
# cd /db
# find . -xdev | cpio -pcmudv /db1
# umount /db
You will need to do a cd
Also, if there are any open files on either filesystem the umount commabnds will not work, so you might have to use the fuser command if the umount commands fail to determine what processes are still using the filesystem.