- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- File Recovery on DAT
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
04-09-2005 01:29 AM
04-09-2005 01:29 AM
File Recovery on DAT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2005 04:13 AM
04-09-2005 04:13 AM
Re: File Recovery on DAT
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2005 04:41 AM
04-09-2005 04:41 AM
Re: File Recovery on DAT
Thanks for your help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2005 05:54 AM
04-09-2005 05:54 AM
Re: File Recovery on DAT
dd if=/dev/rmt/TAPEDRIVENAMEHERE bs=1024 count=1 | od -bc
then post the output here
also try
dd if=/dev/rmt/TAPEDRIVENAMEHERE bs=1024 count=1 | what
live free or die
harry d brown jr
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2005 11:50 AM
04-09-2005 11:50 AM
Re: File Recovery on DAT
pax -v -f /dev/rmt/0m
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2005 01:29 PM
04-09-2005 01:29 PM
Re: File Recovery on DAT
output = a ton of files, to many to post.
dd if=/dev/rmt/TAPEDRIVENAMEHERE bs=1024 count=1 | what
output = 1+0 records in,1+0 records out
ran pax -v -f /dev/rmt/0m
output = a ton of files. ran for 15 minutes and had to halt.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2005 02:24 PM
04-09-2005 02:24 PM
Re: File Recovery on DAT
pax -v -f /dev/rmt/0m > /var/tmp/mytape.index
and go have dinner. tar/cpio/pax do not have a central index so the entire tape must be read to create the index file. When the command is done (plan for an hour or so), do this:
grep etc/hosts /var/tmp/mytape.index
It will report either /etc/hosts or ./etc/hosts or maybe etc/hosts. The leading / is a problem because tools like tar will try to restore in right back where it came from. If this is the case, you'll need to restore using the pax options -k (to prevent accidental overlay of existing files), and -s to rename the /etc/hosts file to something like /tmp/oldhosts.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-09-2005 10:56 PM
04-09-2005 10:56 PM
Re: File Recovery on DAT
grep pulls up 3 files containing "etc/hosts"
How can I view these files to see if this is what I want to restore? If it is, what would the command be?
I also noticed a file in /var/tmp called index.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2005 12:20 AM
04-10-2005 12:20 AM
Re: File Recovery on DAT
so from the index file have to restore the file first before you can view is.
as long as the file you require does not have the absolute path ie /etc/hosts then go to /tmp and do
tar xvf /dev/rmt/0m etc/hosts
then the file will be in /tmp/etc/hosts.
if this is the file then move it into place.
HTH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2005 12:38 AM
04-10-2005 12:38 AM
Re: File Recovery on DAT
tar xvf /dev/rmt/0m etc/hosts says;
Tar: blocksize = 10
directory checksum error
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2005 01:35 PM
04-10-2005 01:35 PM
Re: File Recovery on DAT
cd /var/tmp
pax -r -k -i -f /dev/rmt/0m etc/hosts
The above command will prevent accidental overwrite of etc/hosts. and will pause to ask you what to call the restored file. If will say something like:
rename etc/hosts?
(don't answer yes or no) just answer the new name like: /var/tmp/host1
Since you said there were several copies, the tape was recorded in append mode so when the next copy is found, answer with another name like /var/tmp/host2 and so on.
Multiple backups on the same tape are almost as bad as no written information on the tape. There is no command to get the 2nd or 3rd file, just quick fingers typing CTRL-C. It is definitely not a recommended practice to store the same files on the same tape.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2005 11:15 AM
04-11-2005 11:15 AM
Re: File Recovery on DAT
ran pax -r -k -i -f/dev/rmt/0m etc/hosts & it did exactly what you said. What do the switches mean? I looked at etc/hosts & found 127.0.0.1 & 192.168.0.1. How do I get 127.0.0.1 into the IP addresses? What file contains the gateway info?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2005 02:34 PM
04-11-2005 02:34 PM
Re: File Recovery on DAT
man pax
The switches are:
-r recover (read) files
-k do not overlay existing files on disk
-i interactive renaming of files
-f name-of-tape-devicefile
The hosts file is simply: IP-addr hostname
so your entire hosts file would be this:
127.0.0.1 localhost loopback
192.168.0.1 mycomputer
Now 192.168.0.1 looks suspiciously like a router address, not a computer address. The best way to configure your LAN settings is to run this command (after you have the required information):
set_parms inital
You need the following address information:
hostname (lowercase, no FQDN like name.company.com)
IP address for your computer
subnet mask (ask your network administrator or use the standard 255.255.255.0)
gateway IP adress
DNS server information (ask your network administrator)
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-13-2005 12:30 PM
04-13-2005 12:30 PM