Alrighty then, let's have a look at this. For expediency's sake, I shall give you the commands and tell you precisely how to use them, but i would have a look at the man pages for them, too, to double what we're gonna do =)
First off, a manual disk check:
1. I do manual checks (when necessary) from a boot disk (you can use disk 1 of your Slackware system for our purposes), but I feel sure you should be able to do it from within the system. Anyway, it doesn't hurt using a boot disk, since you'll be checking the root partition, and you don't really want it mounted at the time anyway.
2. Boot Slack disk1, you should find yourself at a console. The command you need is `fsck`. fsck itself is only a frontend to the other file checkers, check the man pages to be sure you know what you're after. I'll run through an example, below.
Because I don't know what filesystem you're using or how your box is set up, I will make the assumptions that you're using ext2 and your root partition is /dev/hda1. It should cover the basics enough to get you started, at any rate. If you need more help, we can cross that bridge when we get to it.
The filesystem check on ext2 is called either `fsck -t ext2`, `fsck.ext2` or it's actual binary `e2fsck`. I wil be using e2fsck, which has it's own associated man-page, and you won't get too confused then, I hope
The commands that are used to check consistency in the boot scripts can be found in /etc/rc.d/rc.S .
3. We want to check a disk for errors and attempt recovery on any errors we find.
I highly recommend you `man e2fsck` to see what I'm doing; but basically we're running a badblock checker, in verbose mode, that will attempt to automatically fix any errors.
Please please please, if anyone knows better - tell me! I would be happy running this on my machine, but, I don't wanna wreck someone elses!
Secondly, reinstallation (and location!) of updatedb
Basically, `cat /var/log/packages/* | grep updatedb` will get you the location of updatedb, but ... i always found that a bit of a pain, so I adapted it and turned it into a script:
Code:
#!/bin/bash
for nfile in $1
do
if [ -f "$nfile" ]
then
if [ `cat $nfile | grep $2 | wc -l` -ge 1 ]
then
echo "Found in ${nfile}:"
cat $nfile | grep $2
fi
fi
done
This copy that into a file (I call mine "findme") and then run it like this:
Code:
#findme "/var/log/packages/*" updatedb
It'll return something that looks like this:
Code:
piete@Melchior:~$ scripts/findme "/var/log/packages/*" updatedb
Found in /var/log/packages/dcron-2.3.3-x86_64-1:
dcron: with cron, such as the nightly indexing with updatedb.
Found in /var/log/packages/slocate-2.7-x86_64-1:
etc/updatedb.conf.new
usr/man/man1/updatedb.1.gz
So, I reckon you need to reinstall the slocate package (uhm, please ignore the fact that I'm using a 64-bit machine, you want to reinstall slocate-i486) to fix updatedb.
I
hope I've covered everything you need to set you straight, but you know where we are if you need additional help!
Good luck, and I hope to hear you're problems are all gone next time I read a message from you
- Piete "Oh no not another essay" ...
=D