LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   replacing cd drives: filesystem corruption (https://www.linuxquestions.org/questions/slackware-14/replacing-cd-drives-filesystem-corruption-694683/)

tramni1980 01-03-2009 09:25 AM

replacing cd drives: filesystem corruption
 
Hello!
I have been using Slackware Linux for 2 years now. I notice that almost each time (not sure if actually 100% each) when I remove, add or replace some of my optical drives or hard drives, I end up with a filesystem corruption. After the manipulation with the hardware, on booting dma is usually disabled for the hard drives. I seem to solve this issue by manually removing the /etc/udev/rules.d/70-persistent-cd.rules file, as suggested by Changes and Hints. However this is not the only issue. Sometimes the filesystems on some of my hard drive partitions get corrupted. In the worst case scenario so far the "ldconfig" command gave "segmentation fault" and my only option was to reinstall: installpkg did not work. Today I removed my dvd drive because it is out of order - I will have it repaired. After the removal I checked that in BIOS everything is ok. When I rebooted, I encountered the usual no dma errors. I edited the /etc/udev/rules.d/70-persistent-cd.rules by removing the entry for the missing drive. This did not seem to work, as on the next reboot lilo was messed, there was again no dma. I tried to remove the file but got the message: "Cannot remove: stale NFS file handle". Luckily googling suggested running "fsck -f" on the affected partition. This solved almost all the issues. However some settings of my desktop have disappeared.(?)

Now I tend to be afraid to mess up with the hardware. Why do such things happen? Do I have to check and repair the filesystems each time I open the box?

Regards and best wishes,
Martin Ivanov

onebuck 01-03-2009 10:53 AM

Hi,

It sounds like you are corrupting your filesystem possibly by not performing shutdowns or flushing the buffers properly. Or other issues like memory faults or such. Run 'memtest86' to check that out. This could cause faults within a filesystem whenever buffers are flushed an the data is not valid.

The hardware configuration should not corrupt the filesystem when a ROM device is removed from the chain unless the filesystem is on that device. :)

tramni1980 01-03-2009 11:08 AM

Quote:

Originally Posted by onebuck (Post 3395768)
Hi,

It sounds like you are corrupting your filesystem possibly by not performing shutdowns or flushing the buffers properly. Or other issues like memory faults or such. Run 'memtest86' to check that out. This could cause faults within a filesystem whenever buffers are flushed an the data is not valid.

The hardware configuration should not corrupt the filesystem when a ROM device is removed from the chain unless the filesystem is on that device. :)

I ran memtest for 4 hours when I had segmentation fault from ldconfig. This was the nastiest experience I had with my computer :(. There was no error found. The issue only occurs after messing with the hardware. After regular shutdowns no problems actually occur. Previously I was with reiserfs and now I use jfs, as the poll on this forum suggested it to be the best filesystem.

I do remember however, one thing associated with my RAM memory chip. When I bought it I tried incorrectly inserting it into the slot on the motherboard which resulted in a small capacitor (condensator) detaching from the memory chip. However, the memory is correctly recognized at its full capacity. And memtest does not find any faults. Could that be the reason for those strange issues I am having whenever I replace my hard or optical drives?

guanx 01-03-2009 12:44 PM

Do your drives support hot-plug? Seems you are removing drives without turning off your computer.

Also plese don't use corrupted hardware, e.g. your memory module.

tramni1980 01-03-2009 01:14 PM

Quote:

Originally Posted by guanx (Post 3395875)
Do your drives support hot-plug? Seems you are removing drives without turning off your computer.

Also plese don't use corrupted hardware, e.g. your memory module.

Of course I power off my computer before I replace drives.

onebuck 01-03-2009 07:39 PM

Hi,
Quote:

Originally Posted by tramni1980 (Post 3395780)
I ran memtest for 4 hours when I had segmentation fault from ldconfig. This was the nastiest experience I had with my computer :(. There was no error found. The issue only occurs after messing with the hardware. After regular shutdowns no problems actually occur. Previously I was with reiserfs and now I use jfs, as the poll on this forum suggested it to be the best filesystem.

I do remember however, one thing associated with my RAM memory chip. When I bought it I tried incorrectly inserting it into the slot on the motherboard which resulted in a small capacitor (condensator) detaching from the memory chip. However, the memory is correctly recognized at its full capacity. And memtest does not find any faults. Could that be the reason for those strange issues I am having whenever I replace my hard or optical drives?

Yes, the surface mount capacitor on the stick being damage can cause you problems. 'memtest' is a fair memory utility but not a full stress testing utility. How much memory do you have on the system board? You could try an remove the stick in question then see if the problems still pops up. The capacitor is for chip Vcc filtering. So the effect will be only noticeable with a oscilloscope or spectrum analyzer to view the supply at that point. You could re-attach the cap but if you never worked with surface mount then you would probably do more damage then good.

As for filesystem selection, that is personal taste. I prefer ext2/3, old and reliable. I've rarely had a problem with my filesystem when using ext2/3. (knock on wood ...) :)

Try ext2/3 for your filesystem an see what happens. You could use your backup to restore to the new space. :)

tramni1980 01-04-2009 03:18 AM

Thank you for your replies. Onebuck, this is my meminfo:
Code:

marto@marto:~$ cat /proc/meminfo
MemTotal:      1292868 kB
MemFree:        644368 kB
Buffers:          2492 kB
Cached:        261344 kB
SwapCached:          0 kB
Active:        334824 kB
Inactive:      190192 kB
HighTotal:      391424 kB
HighFree:          744 kB
LowTotal:      901444 kB
LowFree:        643624 kB
SwapTotal:      506008 kB
SwapFree:      506008 kB
Dirty:            1340 kB
Writeback:          0 kB
AnonPages:      261180 kB
Mapped:          59576 kB
Slab:            29752 kB
SReclaimable:    21540 kB
SUnreclaim:      8212 kB
PageTables:      2816 kB
NFS_Unstable:        0 kB
Bounce:              0 kB
WritebackTmp:        0 kB
CommitLimit:  1152440 kB
Committed_AS:  1051044 kB
VmallocTotal:  114680 kB
VmallocUsed:      9564 kB
VmallocChunk:  104436 kB
DirectMap4k:    114688 kB
DirectMap4M:    802816 kB

I have one 512 MB memory chip and one 1 GB chip both at 266 MHz. The chip without one of the capacitors is the 1 GB one, which is Kingston.

It seems that I should take my computer to a service, do I not? However I have no problems at all unless I open the box.

onebuck 01-04-2009 08:53 AM

Hi,
Quote:

Originally Posted by tramni1980 (Post 3396501)
<snip>

I have one 512 MB memory chip and one 1 GB chip both at 266 MHz. The chip without one of the capacitors is the 1 GB one, which is Kingston.

It seems that I should take my computer to a service, do I not? However I have no problems at all unless I open the box.

Take out the 1GB stick an try it to see if the problem persists.


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