restoring old /etc permissions


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers restoring old /etc permissions
# 1  
Old 10-26-2001
restoring old /etc permissions

A co-worker inadvertently changed all the permissions in /etc by doing 'chmod *' ....

Anyway, we have a backup tape to restore from, but I'm not sure how to use the 'restore' command and options to just restore the permissions.

Would appreciate any recommendation/suggestion.

Thanks in advance
# 2  
Old 10-28-2001
/etc chmod

It would help us understand better if you gave us the OS version and what tools you have to use for the restore.

In HPUX, restoring from an Ignite tape is very easy.
If using a tar ball, it is equally as easy with a few options that you will need to use.
With dump and restore, it shouldn't be too hard either.


I had the same thing happen about a month ago on a live production box. Someone did "chmod 444 *", very bad!! All of my executables were disabled as well as several daemons like telnet, sendmail, inetd, and others.

I did mine by hand, instead of using a backup. But now that I look back it could have been easier using a backup tape to restore.

It was time consuming, took the better part of a day, but I could not take the box down at the time.

There are several linked executables from /etc to /usr/sbin and then to /bin as well. You will also have to look at subordinate directories as well. There exe parms are probably wrong as well.

As to your question, there should be a parameter of the restore command to keep date and time stamps as well as permissions and ownership.

Now that I think about it, permissions shouldn't change when restoring, but time and date stamps may.

It took me the better part of a day to straighten my 2 systems out, but I did it without using a restore tape. Primarily by comparing the corrupted system to one that was similar and in good order.

After you have restored this box, check it against another box just to be sure.

Also, check to ensure that all of your pertinent daemons are running, namely sendmail, inetd, init, etc...


Smilie Smilie
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Restoring deleted file with rm -rf

Is there a way I could recover a deleted text file with "rm -rf" command. Running CentOS 6.5. Thank you. (5 Replies)
Discussion started by: galford
5 Replies

2. UNIX for Dummies Questions & Answers

Copying/Restoring UNIX O/S

can someone shed just a little light in the broadest sense, not actual commands, on what is involved in copying a UNIX install from one HD to another, or if that is even possible Can I use DOS as a frame of reference or is that at all relevant? With DOS (and early Windows versions) You could... (4 Replies)
Discussion started by: chrishouse
4 Replies

3. Shell Programming and Scripting

Restoring problem on tape!

hi all , a messages appeared to me when i was checking my /var/adm/messages and the below code was in it Oct 6 13:15:21 medprod scsi: /pci@3,700000/SUNW,emlxs@0/fp@0,0/st@w21000024ff305234,7 (st1): Oct 6 13:15:21 medprod Restoring tape position at fileno=320,... (5 Replies)
Discussion started by: semaan
5 Replies

4. UNIX for Advanced & Expert Users

Restoring files from CVS !

I have accidently removed a file using the command rm -r "file.txt" (I have removed it locally !) I need to restore the file.txt to my existing CVS version.How can I do it ? Please help. Thank you. :wall: (5 Replies)
Discussion started by: gameboy87
5 Replies

5. UNIX for Dummies Questions & Answers

Restoring tape files...

Hi all, I have kinda inherited this problem, but was wondering if anyone else had any ideas. Currently all our backup rentention periods are set to 2 weeks, so that we can cycle through tapes (save money etc...). Anyhow the guys next door in IT, decided one day long long ago, that it would... (0 Replies)
Discussion started by: B14speedfreak
0 Replies

6. Shell Programming and Scripting

Restoring a file

I'm new to Unix and have just wrote a little program to move files to a recycle bin (a Directory i created) and restore them. The problem is that i need to keep track of all the full filenames so that i can restore them to the right place. I did this by creating a file called delreg and putting the... (4 Replies)
Discussion started by: zoolz
4 Replies

7. UNIX for Dummies Questions & Answers

restoring deleted files

I had a user run, by accident, the following line command on our UNIX server: rm -f /usr/* This apparently deleted some needed files on your system. Having very limited knowledge in UNIX, I thought I would ask the group if anyone knows how I can recover these file? The version of UNIX is... (3 Replies)
Discussion started by: mikem
3 Replies

8. AIX

restoring mksysb urgent

Guys, Got a very urgent question here. I accindently deleted everything on my RS600, with the rm -R command. Now I want to restore an mksysb tape but I get the following error. format on /dev/rmt1.1 is not in backup format please mount /dev/rmt1.1 and press enter. Can anyone help me... (7 Replies)
Discussion started by: Erik Rooijmans
7 Replies

9. UNIX for Dummies Questions & Answers

restoring backups

okay.. pple.. say now i got an aix box. of course i could restore a backup done in aix environment. 1) now how about doing a restore from sun, hp from the aix box.? 2) can we install a sun, hp os into an aix box? 3) if (1) prohibits, then how about doing an sun, hp os installation on... (1 Reply)
Discussion started by: yls177
1 Replies

10. UNIX for Dummies Questions & Answers

Restoring a file from Tape

help please i have "inherited" a Sco Server (the administrator departed in a hurry...yes we are chasing him..) and haven't used Unix for 8 years. i have a file that i need to retrieve from a tape. i have been able to find the file on tape using the cpio -ivt command. however... the problem I... (3 Replies)
Discussion started by: mfischer
3 Replies
Login or Register to Ask a Question