Operating System - HP-UX
1838192 Members
4262 Online
110125 Solutions
New Discussion

Re: /usr accidently destroyed.

 
Nigel Green
Advisor

/usr accidently destroyed.

When extending the /usr filesystem, I accidently ran the newfs command rather than extendfs, as a result /usr is now empty.

is there any way of recovering this FS from the recovery CD or is this a straightforward re-install.
10 REPLIES 10
Victor Fridyev
Honored Contributor

Re: /usr accidently destroyed.

Hi,

Do you have a similar machine ? You can copy /usr from it.
Additionally, if you have a make_recovery backup, you can use it as follows:
mt -f /dev/rmt/0mn fsf 1
cd /
tar xv ./usr (or tar xv /usr You have previously check the output tar tv ) I don't remember exactly how the files are backed up.
If you don't have any of these options, so install mini system and restore the computer from full backup.

8((((

HTH
Entities are not to be multiplied beyond necessity - RTFM
Patrick Wallek
Honored Contributor

Re: /usr accidently destroyed.

Well there are a couple of options for you.

If you have a recent backup, say tar or fbackup, you can use the statically linked binaries in /sbin/ to restore it.

If you have a make_tape_recovery tape you might be able to restore from it, but there is no 'mt' command in /sbin, which you need to skip over the boot header.

You could also boot from a make_tape_recovery tape and restore your OS from it.

Good luck.
Hilary Nicholson
Frequent Advisor

Re: /usr accidently destroyed.

Restore /usr from last good backup.

Regards,

Hilary
Nigel Green
Advisor

Re: /usr accidently destroyed.

There are a couple of things I neglected to mention in the original post. This a new server which we haven't yet backed up as we don't have a tape drive attached.

We can't just copy /usr from another machine because we can't get the network services started as it won't boot past single user mode.

thanks
RJ
Sanjay_6
Honored Contributor

Re: /usr accidently destroyed.

Hi,

If you don't have a backup from this server, ignite or some other backup, then there is no choice, but reinstall.

Hope this helps.

Regds
Pete Randall
Outstanding Contributor

Re: /usr accidently destroyed.

Nigel,

If you're that early on in the install process, it would be faster to just begin again than it would to experiment with prospective solutions.


Pete

Pete
Patrick Wallek
Honored Contributor

Re: /usr accidently destroyed.

Yep, I'd agree with Sanjay here. Reinstall is probably your best option.
Hilary Nicholson
Frequent Advisor

Re: /usr accidently destroyed.

Looks like a re-install situation.

Can't think of any other way round this.

Once you re-install it would be an idea to backup across the network, or use make_net_recovery to get an ignite abckup

Regards,

Hilary
Nigel Green
Advisor

Re: /usr accidently destroyed.

Thanks for the input guys....and Hilary..i thought that may be the case, but you never know. I'll dig out the install CD's!
Nigel Green
Advisor

Re: /usr accidently destroyed.

.