LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   does wrong type entry in fstab corrupts the partition ? (https://www.linuxquestions.org/questions/linux-hardware-18/does-wrong-type-entry-in-fstab-corrupts-the-partition-885416/)

ununun 06-09-2011 09:19 AM

does wrong type entry in fstab corrupts the partition ?
 
after a gap of few month i started to using linux again (this time crunchbang on my usb) and mistakenly i added wrong fstype in /etc/fstab (like this )

Code:

#/dev/sda5        /mnt/cdrive        ntfs-3g        defaults,locale=en_IN        0        0
#/dev/sda2        /mnt/mverse        ntfs-3g        defaults,locale=en_IN        0        0

and started to using untill i started to get I/O errors.

now i have possible hard disk corruption and before doing anything i want to make sure that can wrong fstype in fstab cause such problems if not what can cause this (because partitions were working absolutely fine before installing crunchbang).

before posting this question i did unfinished chkdsk /r on both partitions, unfinished because its taking very very long time (mverse [size=200gb] took at least 11hrs).

what should i do ?

alfredo10 06-09-2011 10:37 AM

Hi!
As far as I know, wrong entry in /etc/fstab can not corrupt hd (I never heard that); it is possible - depends on the Linux distribution - that you can't start your Linux.
To help we should know some details:
1. Windows preinstalled on only one internal hd?
2. You installed any Linux on hd? Which one?
3. You are able to boot from a Linux live medium to Desktop?
If not, I recommend to download PartedMagic - it is more than a normal operating system, it contains many useful tools, such as new GParted, UNetbootin,... and you can access your data and edit system files as fstab or menu.lst or grub.cfg or grub.conf.
If yes, please post the output of Terminal - as root -
Code:

fdisk -l
lowercase L like list,
and
Code:

parted -l print
Normally you get root rights on a live medium with
Code:

sudo su
or
Code:

su -
ENTER
before the commands above.
alfredo

Edit: Of course you must burn an image of PartedMagic and boot from it to use the tools on PartedMagic.
URL: http://partedmagic.com/doku.php?id=screenshots

ununun 06-09-2011 11:03 AM

Thanks alfredo10 for reply

i am running crunchbang from usb drive (its not live version, its installed on my usb i.e. sdb).
1. windows xp is on /dev/sda5 and its been there before i installed crunchbang.

2. only linux that i is #! and its on usb drive i.e. flash drive or pen drive.

3. yes #! running perfectly fine. even xp is runningm but its very slow now.
and i have corrected fstab as soon as i got I/O errors.

Code:

sudo fdisk -l
Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x007f007f

  Device Boot      Start        End      Blocks  Id  System
/dev/sda1              2        4296    34499587+  f  W95 Ext'd (LBA)
/dev/sda2  *        4297      30402  209687552    7  HPFS/NTFS
Partition 2 does not end on cylinder boundary.
/dev/sda5              2        4296    34499556    7  HPFS/NTFS

Disk /dev/sdb: 4216 MB, 4216324096 bytes
93 heads, 44 sectors/track, 2012 cylinders
Units = cylinders of 4092 * 512 = 2095104 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x025894b0

  Device Boot      Start        End      Blocks  Id  System
/dev/sdb1  *          1        2012    4115456  83  Linux


Code:

sudo parted -l print
Model: ATA ST3250310AS (scsi)
Disk /dev/sda: 250GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start  End    Size    Type      File system  Flags
 1      8225kB  35.3GB  35.3GB  extended              lba
 5      8258kB  35.3GB  35.3GB  logical  ntfs
 2      35.3GB  250GB  215GB  primary  ntfs        boot


Model: Generic Flash Disk (scsi)
Disk /dev/sdb: 4216MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos

Number  Start  End    Size    Type    File system  Flags
 1      1049kB  4215MB  4214MB  primary  ext4        boot


alfredo10 06-10-2011 03:55 AM

Hi ununun!
Okay, where is the problem?
1.
Quote:

...but its very slow now
I don't know what should help.
2. Maybe it is useful if you post your fstab.
3. I installed crunchbang, but some years ago, so I don't know details.
You have the latest version of it with Grub1.98 - I supppose?
After having booted from your USB o Desktop you could run
Code:

dpkg --list | grep grub
and post it.
alfredo

ununun 06-10-2011 10:13 AM

/etc/fstab
Code:

# /etc/fstab: static file system information.
#
# <file system> <mount point>  <type>  <options>      <dump>  <pass>

proc        /proc        proc        defaults        0        0
#/dev/sda5        /mnt/cdrive        ntfs        defaults,locale=en_IN        0        0
#/dev/sda2        /mnt/mverse        ntfs        defaults,locale=en_IN        0        0
/dev/sdb1        /        ext4        errors=remount-ro        0        1
/dev/sda1        /media/usb0        auto        rw,user,noauto        0        0
firefox        /home/manish/.mozilla/firefox/frw9d2g2.default        tmpfs        size=320M,noauto,user,exec,uid=1000,gid=1000        0        0

#/dev/sdb1        /media/cdrom0        udf,iso9660        user,noauto        0        0

i comment line 6 and 7 to not to do any further damage.

Code:

$dpkg --list | grep grub
ii  grub-common                          1.98+20100804-11                    GRand Unified Bootloader, version 2 (common files)
ii  grub-pc                              1.98+20100804-11                    GRand Unified Bootloader, version 2 (PC/BIOS version)

i got "passed" in smartctl -t short /dev/sda.

is there any chkdsk-like utility for linux ?

thanks for the help

alfredo10 06-11-2011 04:06 AM

Hi!
As I wrote in my irst reply/ edit, PartedMagic contains many useful tools, as
- GParted (to create partions etc.)
- UNetbootin (making USB live)
- Testdisk...
http://partedmagic.com/doku.php?id=programs
alfredo

TobiSGD 06-11-2011 04:36 AM

A wrong entry in fstab can not corrupt your disk. If Windows runs slow, and you did get I/O-errors I would assume that this is an hardware error. Try the following:

1. Backup all your data.
2. Download and burn the diagnosis tool from the harddisk's manufacturer.
3. Run it.
4. Download and burn Memtest86+.
5. Run it.

ununun 06-15-2011 06:33 AM

i run seatools dos until hd passed long test with no error and that was about five times.
then i run chkdsk on both partitions.

now i have two new problems
1. i cannot detect my hd in crunchbang.
2. windows seems to freezs after logo with black screen and mouse cursor.

thanks.

jefro 06-15-2011 03:35 PM

1. Backup all your data.
2. Download and burn the diagnosis tool from the harddisk's manufacturer.
3. Run it.
4. Download and burn Memtest86+.
5. Run it.


Go to step 4 and 5

ununun 06-16-2011 02:47 AM

Quote:

Originally Posted by jefro (Post 4386873)
1. Backup all your data.
2. Download and burn the diagnosis tool from the harddisk's manufacturer.
3. Run it.
4. Download and burn Memtest86+.
5. Run it.


Go to step 4 and 5

ok, i did memtest86+ and my mem aced it.

ununun 06-16-2011 02:53 AM

ok now i can mount with ntfs-3g. but still nothing is shown in either fdisk -l or parted -l about sda which is the hd.

what can cause that ?

and about the second question,
i think i have to repair with xp cd.

thanks for all your help


All times are GMT -5. The time now is 08:04 PM.