Ufsrestore


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Ufsrestore
# 43  
Old 01-09-2018
You boot from DVD into single user.

You use 'format' to label and slice the disk. This determines what sectors on the disk the 's0' (slice 0) occupies. At this time there is no filesystem on that slice (and therefore no Lost+Found).

You use 'newfs' to write a new filesystem to s0 so that the OS can mount it. It contains a proper UFS filesystem with superblock, inode table, etc. This step creates the Lost+Found at the top level of s0 and nothing else.

Now you know the device node of the root filesystem that you are trying to restore to this new clone, eg, c0t0d0s0???, you need to mount this on /a mountpoint, eg,

Code:
# mount /dev/dsk/c0t0d0s0 /a

(As previously discussed, you cannot be in /a when mounting otherwise you get 'busy'.)

After the mount has completed without error, if you go into /a directory you should see the Lost+Found. If you don't, then either the newfs didn't work, or the mount didn't work.

/a will be empty if the mount didn't work because you are simply looking at the /a directory on the DVD. After the mount, you should be looking at the apex of c0t0d0s0.

Try issuing the command:

Code:
# mount

to check that c0t0d0s0 is indeed mounted on /a
This User Gave Thanks to hicksd8 For This Post:
# 44  
Old 01-09-2018
1. You prepare your empty hard disk root filesystem and mount it on /a.

2. You plumb, configure and up your network interface and mount your remote NAS on /mnt.

These are separate operations and it matters not which order you do them in.

You then check that in /mnt you can see your NAS files.
You then check that in /a you can see Lost+Found on the empty new root filesystem.
If all is well then you stay in /a and issue the ufsrestore.

Last edited by hicksd8; 01-09-2018 at 01:32 PM..
This User Gave Thanks to hicksd8 For This Post:
# 45  
Old 01-09-2018
Thanks! It worked and I have a recognizable root partition. So- don't format and mount the other partitions now? Do this?:

10. 'sync' and 'umount' the NFS storage and the root hard disk and do an orderly shutdown.
11. System should now boot.

Note that if your /usr filesystem is separate from the root filesystem you should consider backing up that for emergency recovery too since without being able to mount /usr the recovered system will probably go into maintenance if it cannot mount /usr
# 46  
Old 01-09-2018
Yes, is your /usr filesystem a separate filesystem????

If so, you'll need to ufsrestore the dump of that too, otherwise the clone will go into "maintenance mode" when it boots. All other filesystems you can restore (by whatever means, eg, ufsrestore, cpio, tar) after the system is on its feet.

To enable the system to boot from the disk you will need to install the boot blocks into sectors 0 & 1 of the disk (like MBR on Windows). There's an 'installboot' command on the DVD to do that. Search this forum for that. Any questions post back here.

Is the clone hardware identical to the production box? If not, there may be some adjusting to do, modifying /etc/vfstab, modifying /etc/system, setting up new device nodes eg, /dev/dsk/c4t1d1s0 if the hardware is different.

Unmount your NAS connection with:

Code:
# umount /mnt

unmount your hard disk root filesystem with:

Code:
# umount /a

Once you've installed the boot blocks close the system down in an orderly manner:

# init 0

I'm sure you'll have more questions but perhaps you should start a thread as this one's already quite long.
This User Gave Thanks to hicksd8 For This Post:
# 47  
Old 01-10-2018
Ehh.. Don't know if I screwed up or not here- but I could not
Code:
umount /a

because it was busy. I made sure I was not in that directory as well. Did the
Code:
init 0

anyway and now the machine keeps rebooting over and over saying something like
Code:
cannot mount to root

# 48  
Old 01-10-2018
Is this hardware the same as from where the dump was taken?

If not, it's quite possible that you need to recreate the root filesystem device node. Also, it's possible that because root did not umount cleanly it now needs to be fsck'd before it will mount. I suggest that you:

Code:
# cd /

to place you on the DVD before you attempt to umount /a or /mnt.

You can boot from DVD and see if you can mount the hard disk root filesystem on /a without it complaining.

Last edited by hicksd8; 01-10-2018 at 01:47 PM..
This User Gave Thanks to hicksd8 For This Post:
# 49  
Old 01-10-2018
Also, something that we haven't mentioned so far, have you allocated a swap slice?? Look at the production system VTOC to see how big that swap space is.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Ufsrestore on Solaris 9

Good Morning, I'm running through a Solaris 9 ufsrestore process on a Sunblade 2500 that folks here helped me write a year ago. Here: https://www.unix.com/303011447-post11.html Hicksd8 tells me to # rm restoresymtable. I see this file in the other slices as well. Do I remove it from... (8 Replies)
Discussion started by: Stellaman1977
8 Replies

2. Solaris

ufsrestore T5240

Hi Friends we have sun T5240 server, we have taken ufsdump of this server remotely with scsi tapedrive, If we need to do ufsrestore means what we have to do, since T5240 has not having scsi port, any procedure is there? Regards Rajasekar (5 Replies)
Discussion started by: rajasekg
5 Replies

3. Solaris

How do you ufsrestore the fast way?

hi, on my sol9 box i create my backup using the below command: /usr/sbin/ufsdump 0uf /dev/rmt/0n /u1 /usr/sbin/ufsdump 0uf /dev/rmt/0n /u2 /usr/sbin/ufsdump 0uf /dev/rmt/0n /u3 /usr/sbin/ufsdump 0uf /dev/rmt/0n /u4 now on the new sol10 box, to restore i use this commands: cd /u1... (3 Replies)
Discussion started by: pinoy43v3r
3 Replies

4. Solaris

ufsrestore will not boot

hey all, i did a ufsdump/restore from a mirrored system and i'm not able to get the new system to boot off of the dump. system 1 is a v245 mirrored with disk suite. metadb's are in place d3 -m d23 d13 d33 1 d23 1 1 c1t1d0s3 d13 1 1 c1t0d0s3 d33 1 1 c1t2d0s3 d0 -m d20 d10 d30 1 d20 1... (3 Replies)
Discussion started by: em23
3 Replies

5. Solaris

What is volume in ufsrestore

Hi Gurus, Can you guys please explain what is volume in ufsrestore? Thanks (2 Replies)
Discussion started by: kumarmani
2 Replies

6. Solaris

ufsrestore

Hi , I accidentally deleted crontab entries and I need to restore back urgently ! we use a ufsdump with 0cfu option. I like to know how to restrore / retrieve to different location for crontab file only from the backup. Thanks. (4 Replies)
Discussion started by: skully
4 Replies

7. Solaris

Using ufsdump and ufsrestore

HI Gurus, I have a sunfire V445 server running SAP ECC 6.0 with an Oracle database on Solaris 9 (SunOS 5.9). I recently completed a ufsdump to tape of the following files:- /, /usr, /oracle, /export, /sapr3, I want to restore these files from tape onto a different server of the same... (5 Replies)
Discussion started by: charleywasharo
5 Replies

8. Solaris

ufsrestore?

I'm trying to restore a server from a backup tape. I've partitioned my drive, and I've run into a problem; After extracting everything from the tape, It seems as if only the directory structure is intact. Here are my steps: 1. booted from cdrom to single user mode boot cdrom -s 2. used... (3 Replies)
Discussion started by: ECBROWN
3 Replies

9. Solaris

ufsrestore

on sparc solaris 2.8 hosts, HOSTB, after changing to /dir1 need to: connect to tape drive on HostA. change directory to /dir0/dir1 on tape and restore everything under that path to /dir1 directory. could i get help?. (1 Reply)
Discussion started by: S26+
1 Replies

10. UNIX for Dummies Questions & Answers

ufsrestore -i

Hi there, I have a problem at the moment trying to restore a directory from a Super DLT tape with about 3 weeks worth of backups on it. I need to be able to get the last backup performed on this tape but using ufsrestore -i it only restores the first backup which is no good to me. There is... (4 Replies)
Discussion started by: gerwhelan
4 Replies
Login or Register to Ask a Question