Home directory gone/wiped out for 2nd time

Hi! new FreeBSD user here. I'm loving the experience and using it now as a "test ground" on a Samsung N130 Netbook, so far pleased with performance and use.

But today, for the second time in 2 weeks, my home directory has simply disappeared. I've looked in threads here just to see if this is something that can actually happen, but to no avail.

The last thing I did was listening music in MOC player and then shutting off (it has a switch that if you flick it, the system will do a normal poweroff command, nothing harsh).

The hard disk is an HDD that SOMETIMES makes clicks, it's probably a bit "overused", but can be this a possible cause? Also, it just wipes out the /usr/home/username directory, too much coincidence?

Anyone knows where to start looking/diagnosing? first time it happened I just reinstalled for observing if this could repeat (and it did...), but this time I would like to investigate a bit more and learn things.

BTW, my hard disk is encrypted using GELI (GPT BIOS and SWAP encrypted also)

Thanks in advance :)


UPDATE: Misteriously, after rebooting normally (with the flick of the switch again) it appeared again! Before that I even checked out the size of the /home/ directory, it was 512kb (empty), but now the folder has been "restored" and it's 5gb again! I'm now checking /var/log/messages for checking out if something has happened between reboots. If I see something, I will report and document it. If someone knows what CAN have happened or suffered this before, I'm all ears! :3
 
The hard disk is an HDD that SOMETIMES makes clicks, it's probably a bit "overused", but can be this a possible cause?
It can be an indication the drive is about to die. Doesn't necessarily have to happen though, some drives are just noisy. Having probably used hundreds of disk drives over the past 30 or so years you learn to hear the differences. The kind of clicks it makes can differ from brand to brand, or even model. But if a particular 'noisy' drive begins to make different clicking sounds than usual, that's when you really need to start paying attention.

Also, it just wipes out the /usr/home/username directory, too much coincidence?
Could happen if the 'bad' bit of the disk just happens to have the references to the directory. Failure to read those references would make the directory 'disappear'.

Anyone knows where to start looking/diagnosing?
De facto standard tool; sysutils/smartmontools. Run smartctl -a /dev/<drive> and check the SMART information of the drive.

Misteriously, after rebooting normally (with the flick of the switch again) it appeared again! Before that I even checked out the size of the /home/ directory, it was 512kb (empty), but now the folder has been "restored" and it's 5gb again! I'm now checking /var/log/messages for checking out if something has happened between reboots.
This sounds more like a failure to mount the filesystem than anything bad with the disk itself. If the filesystem isn't mounted the directory would (and should) be empty.
 
De facto standard tool; sysutils/smartmontools. Run smartctl -a /dev/<drive> and check the SMART information of the drive.
Did it short before posting it because my GF told me the same, I didn't remembered that tool. Thanks! TLDR the disk seems to have some bad sectors and quite used, but still kicking.
This sounds more like a failure to mount the filesystem than anything bad with the disk itself. If the filesystem isn't mounted the directory would (and should) be empty.
This seems the most plausible explanation. Thank you again! Now I need to check out why it doesn't mount properly the filesystem...

My hopes is that if this happens to someone else, at least it's documented and registered.

I keep checking things :) but at least I have where to start.
 
you could try logging in as root, check /home if not there, try mounting it manually to see what you see.
Did it and it was nowhere to be found, but I didn't try to mount it per se, just logged in as root. How you do it, just mounting the hard disk or something else?.
 
Did it and it was nowhere to be found, but I didn't try to mount it per se, just logged in as root. How you do it, just mounting the hard disk or something else?.
well that should work too. one time I found home I think it was under /var or /run . I just mounted mine under Linux I cannot reproduce that again .

but being logged in root no /home/user try creating a new user in root is everything on the same partition / slice or did you separate them.

if seperate slices then the system might not be mounting home every time like it should for some strange reason.
 
How about fsck.
Maybe you crashed and user profile is lost. SU journal may bring it back.
Try going into single user mode and fsck the partitions.
 
Back
Top