General :: Implications Of Bad Blocks When Reinstalling A Disk Image
Mar 17, 2010
Let's say I'm using one of those PCs that uses a SSD flash drive in place of a more regular HDD.
Say I burn my favorite .iso distro and install it on this PC. I install my favorite applications and seek out and install any missing drivers and generally tweak the system like you do. When I am finally happy with it, I make an image of this installation to an external USB drive.
Now, say 9 months later some of those SSD blocks have gone bad because they were erased too often. They're no longer usable. Also, because I'm a sloppy person who can't be bothered to delete redundant stuff and run make-cleans and so forth, the disk is getting pretty cluttered and takes longer and longer to do stuff.
I decide the obvious solution is to remove and save any data I need to keep, then just over-write the disk with the image I made 9 months earlier.
The question is: will the firmware be smart enough to re-map my incoming image to avoid these bad blocks on the SSD? Or am I going to wind up with some parts of the image being located on bad areas of the SSD?
I recently enabled noapic on my laptop because it was experiencing strange input freezes on several distros that I tried.Ok, so it does not use the ioapics. My question is, what does this mean for the system? If it used apics before, what happens now? I am a freshly graduated computer science major, and I have worked with basics pics on projects before, but I am curious how this effects the running system.
I'm setting up a mysql replication system. I usually maximize what's left on my stock before I buy. I do badblocks first to all 2nd hand hard drive to make sure it is in good condition before I install an Operating System.
I pick up a 200GB sata hard disk in the stock room and test it using badblocks. I left it in the office doing the test and just check it tomorrow. When I return to check, the report says it found 30 bad blocks.
I want to find out how many 4096 byte blocks there are on my disk. I used df -B 4096 and it gave me a number but I'm not sure it's correct as I can use dd to read past what should be the final block.
So I do df -B 4096 and it reports this result:
Code: Filesystem 4K-blocks Used Available Use% Mounted on /dev/sda1 15618840 13190294 1635137 89% /
But when I use dd to go past that block, it doesn't report an error or anything. The command I'm using is
My old system disk almost failed me. I dd_rescued the disk onto a new one (_don't_ use dd_rhelp, that one took days and seemed to forget what it had scanned more than once). The condition of the disk was not very good. So naturally I expected the subsequent fsck.ext3 to bomb half of the new disk. But obviously only a few inodes were affected and I lost only about 10 files completely (mostly on the root partition and not the home partition - yeay!).
However, I then ran a badblocks and put all the bad blocks into a file. I could use this to run fsck but I fear that
1. It could undo or even redo worse than what the first fsck run did, and
2. giving the list of bad blocks, fsck might on the one hand rescue/flag damaged files (which is what I want), but I don't want it to flag the bad blocks on the new disk as well (they are not bad blocks anymore, just copies of bad blocks).
So, how can I single out problematic files using my list of bad blocks (which I can then look at one by one if they could be rescued) without flagging the supposedly bad blocks on the new disk.
I have installed ubuntu 10.10 inside windows (windows 7) from the ubuntu home edition CD.I have allocated a disk space of 12GB. How could I increase the disk space to 20 GB without reinstalling ubuntu?
Sorry I am not a linux user at all. I have a linux image that needs to be installed. I have the image on a USB drive. Not really sure what I should be doing, but local disk seemed to make sense, however, when I select the usb drive I get an error, that the image can not be found
This has happened several times now, with 9.10 and 10.04. I back up my photos periodically to external drives, using Nautilus. At the next attempted login Gnome won't start and sometimes gives power manager incorrect installation error.
First time this happened I was stumped and eventually did a clean install. Second time, I found advice elsewhere in this forum to solve this by emptying root trash, which did the trick. This time, however, root trash has nothing in it and 2 users trash were insignificant (I emptied them all anyway with rm -r). Tried looking for enormous directories but couldn't find a smoking gun. I would rather not end up doing another clean install - a painful and extreme solution. I'm continuing to look for solutions to the immediate problem, but my question really is, what causes this and how do I prevent it in the future? I've run Computer Janitor regularly and ran apt-get clean but no help. Should I do all my large scale copying from terminal? I'm not a total noob, but close.
Since the partition of windows7 (C: ) where wubi was installed was too small, I decided to reinstall wubi into another larger partition (E: ), keeping the old root.disk. Sadly when I replaced the root.disk ubuntu cannot boot, the loader says that there is no root.disk file, although it's there... I guess there is some kind of checksum about the virtual disk toward the loader is poiting... So how can I have my old ubuntu installation back?? I still have the old root.disk.
I have a large qcow2 formatted disk image, which I use as storage. Often I need to move data to and from this disk image. I mount the disk using the qemu-nbd tool as follows:
modprobe nbd max_part=63 qemu-nbd -c /dev/nbd0 /host/disk100G.img mount /dev/nbd0p1 /home/rup/disk
But disk access fails every now and then in the midst of some I/O operation with an "Input/output error". At that point I have to manually unmount the disk and re-mount it so that I can run the program again:qemu-nbd -d /dev/nbd0umount joborkhaki/What could be the reason for this? Is there a better tool that I can use to maintain a qcow2 disk image?
I am new to the Linux world and I am not sure if what I am trying to do is achievable or not. I am trying to make an image of my existing drives running Linux on a USB and I want to use the same image off the USB to clone more bootable hard drives. Something like what Ghost does in windows. The problem is using 'dd' the image is too big ( I have 1tb drives ) and then I am not sure how to convert these images back on to new drives so that they boot in the OS as well. i am not sure if there is a utility that would let you do that?
How do I create/boot a ram image from a disk? I'd like to create a linux installation that is booted from a USB or CF drive and after boot does not access the disk.
I downloaded an raw SD card image that has two partitions. It caused some file system errors when I tried to dd it directly into an SD card. I am not sure if the card is defective or the image. Is there a way to examine this image without writing it to a physical card? Like trying to mount the partitions separately or checking the tables?
I recently installed Linux to run a few Linux based tools on a disk images I have, and I can't seem to copy the disk image over to my ext3 partition.
The particular distibution I'm using is BackTrack 4 r2, which is Ubuntu based. I can't seem to find specifically which version of Ubuntu is being used. The disk image is 108GB. It is currently located on a NTFS partition on a SATA hard drive connected directly to the computer. The ext3 partition is located on a second SATA hard drive connected to the same computer. It has 200GB total. I do not remember exactly how much free space it had but "df -h" showed a lot more than 108GB. The computer has 4GB of RAM and I gave it 8GB of swap space.
At this point it has been running for more than 12 hours. This is far longer than I would expect it to take had I been copying the file under Windows. How ever I do not have much experience with Linux, so if it's supose to take this long please let me know. I am planning on letting it run until I wake up tomorrow.
"cp -v" hasn't been very verbose at all. The only sign I have that indicates the computer is still trying to do something is the HDD light on my chasis that has stayed lit this whole time.
Is it possible to boot from a disk image file(containing linux) file that resides inside windows and add a bootloader entry for booting from the disk image.?
I deleted some files on the command line and would like to learn if it's possible to recover them. It's not a terrible thing if they are gone, but I want to see what I can do. The server is configured as a hardware RAID5+1 (ext3, Debian Stable) and I *really* don't want to take a dd of the entire disk.
ls -id gets me the inode value of the directory(155655)
I'd like to create a disk image starting at that specific inode. Then there is the issue of picking an outer boundary of the disk image. I'm hoping there's a dd/ext3 genius out there to advise.
Suppose I have a 80 GB hard disk (sda) with 4GB of contents. Using a dd to copy to a different disk
Code: dd if=/dev/sda of=/dev/sdb copies all the contents (including free space). So sdb also needs to be 80GB.
You will notice that in VMWare or VirtualBox disk images, it is possible to set the disk to use only the amount of space of actual data. So a 80GB virtualbox/vmware image with 4GB of contents will be 4GB.
Is it possible to do that with an actual hard disk (sda) image? I want to create an image of an actual hard disk, copy it to DVD and transport it (in mail) for restoration on another computer (having same hard disk).
I am having a rather strange issue. I have windows 98 installed into a disk image that I use bochs to boot it with. I want to transfer some files to the image but now I am unable to mount it. I will attach the drive to the loopback device but when I go to mount I get wrong fs type bad option ... etc.
The command I used to mount was
Code: #mount -t vfat /dev/loop0 /media/loopdisk cfdisk shows it ok as does fdisk. shows as a fat16 file system. When I attempt to check it for errors using fsck.msdos I get
Code: # dosfsck 3.0.6 04 Oct 2009, FAT32, LFN # Logical sector size (64543) is not a multiple of the physical sector size.
When I boot into windows 98 in bochs and check the disk it tells me there is no problems.
At the Get Slackware page at the Slackware website it gives a list of addresses which when I click one of the addresses it redirects to another page with a list of mirror images. Which address and which mirror image do I need to work with Kubuntu 11.04 on my netbook so I can create a USB startup disk? With my connection speed these mirror image downloads take about an hour and a half and I cannot just be guessing which mirror image to download.
I need little help on live disk creation and disk image backup.
Can I create live disk using my hard drive installation? If yes then, can I restore the fedora from the live disk to the hard drive. I mean to say that from that live disk can I install fedora again in my hard drive.
Second question is, if I create the disk image of my hard drive( including ntfs & FAT32 partition) , can I restore it in a blank drive. If so , then can os will be restored also?
I have a bunch of disk images, made with ddrescue, on an EXT partition, and I want to reduce their size without losing data, while still being mountable. How can I fill the empty space in the image's filesystem with zeros, and then convert the file into a sparse file so this empty space is not actually stored on disk?
For example:
> du -s --si --apparent-size Jimage.image 120G Jimage.image > du -s --si Jimage.image 121G Jimage.image
This actually only has 50G of real data on it, though, so the second measurement should be much smaller.
This supposedly will fill empty space with zeros: cat /dev/zero > zero.file rm zero.file But if sparse files are handled transparently, it might actually create a sparse file without writing anything to the virtual disk, ironically preventing me from turning the virtual disk image into a sparse file itself. :) Does it? Note: For some reason, sudo dd if=/dev/zero of=./zero.file works when cat does not on a mounted disk image.
I know there are many threads about recovering damaged superblocks. I've spent 3 evenings reading them and trying what they suggest. Invariably the commands do nothing except to report bad or missing superblocks. I've removed the physical disk from the machine and am working with a dd image file (/mnt/image). I can mount what used to be hdc1 and read its files with no problem. I'm trying to recover partions hdc6 and hdc7.$ mmls /mnt/image -b
DOS Partition Table Offset Sector: 0 Units are in 512-byte sectors
we have a Win NT4 system used for an important application used at two places. At one place it has gone bad. I want to create an image from good system and restore it at the second location. Is it possible to do this using "clonwzilla live cd"? Does it harm the good system? Can I save the created image to an USB drive?