Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Ok this might be a question, but i logged into my slack 10.1 server and when i tried to mount my second hard drive (primary hdd is 40gb, secondary is 160gb..backup hard drive) i got this error:
Code:
root@slackserv:/mnt# mount -t ext2 /dev/hdb1 /mnt/hdb
mount: wrong fs type, bad option, bad superblock on /dev/hdb1,
missing codepage or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
so i said..alright..i'll do e2fsck..i did and i keep getting this error:
Code:
root@slackserv:/mnt# e2fsck /dev/hdb1
e2fsck 1.35 (28-Feb-2004)
/dev/hdb1 contains a file system with errors, check forced.
Error reading block 13 (Attempt to read block from filesystem resulted in short read). Ignore error<y>?
Does this mean that all of my data got lost on my filesystem? I'm pretty sure the reason this came up was because my roommate went to take the server home and didn't shut the server down properly. Are those errors really bad? Thanks.
Location: At the 100th Meridian where the great plains begin
Distribution: Debian Testing on T60 laptop
Posts: 105
Rep:
Did you let fsck finish running through it? Maybe all it needs is to run through it once or twice and then it'll be fixed. I usually just do something like
e2fsck -fp /dev/hdb1
or
e2fsck -fy /dev/hdb1
or
e2fsck -fcy /dev/hdb1
etc.
Then you don't have to bother with answering all the time to what it's asking. As far as I know this has not caused harm to my system . I usually just put my faith in the people that write those things since they seem to be pretty smart and definitely know more about it than I do.
I don't know if your error's bad, but one way to find out would be to let fsck finish, unless you have already done so.
fsck is a front-end for your specific file system checker. The checker for ext2fs or ext3fs is e2fsck. See man pages for fsck and for e2fsck.
I like to add the -C parameter as well. That will tell fsck or e2fsck to print progress messages and a progress "meter". Don't get discouraged if the progress appears to stall from time to time. When I fsck my 60GB ext2 partition it stops for about 5 minutes several times in the process. The 60Gb partition is encrypted and it takes 40 minutes to do an fsck.
If you want to know the status of an ext2 partition/file system you can use the tune2fs command with the -l parameter as follows:
tune2fs -l /dev/hda1
This will give you a lot of information. You should look for a line labeled "Filesystem state". It will tell you if the file system needs to be checked. If the file system state is clean then it doesn't need to be checked. If the tune2fs command gives you an error then you may have another type of file system or the ext2/ext3 filesystem is corrupt.
Last edited by stress_junkie; 12-24-2005 at 08:41 AM.
i just went through and did a e2fsck -y /dev/hdb1 and now every single file is in lost+found. What do I do now if I want to have it back to the way it was?
hmm, well it's repaired as best it could so I would suggest a reboot (to umount and mount the drive again, just in case), then move all the files back to where they were if you can remember that is!
Remember: in unix a file is a file, simple as that!
hmm, well it's repaired as best it could so I would suggest a reboot (to umount and mount the drive again, just in case), then move all the files back to where they were if you can remember that is!
Remember: in unix a file is a file, simple as that!
Yeah I did do a reboot...its all still there in lost+found. I have like 86gb of stuff...this is going to suck
This is going to sound like a stupid question and i'm not saying windows is better, but how come when you don't properly shut down a windows machine the filesystem doesn't seem to get screwed up but after one time of not properly shutting my linux machine down the whole drive got f*#cked up?
I've had a bad experience with ext2/3 on a couple of occasions. I have now settled on ReiserFS and not had an issue. This includes a powercut while encoding.
The other issue could well be that your second drive is on it's way out. Do a check just to be on the safe side.
Just bad luck I suppose, I've lost stuff on vfat, ntfs, ext2 and ufs before.
I've never lost anything on reiser before, maybe try that.
edit: Actually the best answer to that is..... BACKUP YOUR DATA!!
Merry commercial gains season
Actually..that was my network backup drive for my windows machine. I was thinking a linux filesystem would be safe enough for my files. I dont think the drive is going out though. It's fairly new.
It seems like after a power failure or after an improper shutdown, i always get some sort of error after the power comes back on a ext2 filesystem. I don't mean just on this machine..on any machine i've had linux on with an ext2 filesystem. I have used reiserfs in the past and maybe i'll use that again because i remember not having that many problems that i have had with ext2. It just seems like I would have to run fsck every time i boot with a ext2 filesystem...or run it at least twice a day just to make sure my filesystem isnt dieing.
Yes I have lost data using fat32 and ntfs before. My one friend used disk defragmenter in windows xp on his raid 0 array and his computer blue screened and he lost data. I've seen it happen on windows filesystems..so i know it happens, but I haven't had this machine up for more than like 3-4 months and have this happen..it sucks.
It do suck - lots sry I didn't realise it was a backup. Reiser is definitely more robust though, or even ext3 as it basically adds journaling to the ext2 fs. If you want something really hardcore go for xfs or jfs, there's plenty of documentation out there for your pleasure. Good luck in the future.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.