fixdisk can't unmount hd2

Wildebeest

Member
I have a horrible feeling I am missing something obvious but here goes:

My HDD is dying and has been for some time, so I am planning on replacing it - probably with a 3 or 4 TB as it sounds straightforward according to https://wiki.hummy.tv/wiki/Very_Large_Hard_Drive. Prior to this I wanted to run fixdisk just to put a sticking plaster on it to minimise problems copying media files off it later - however it keeps giving me an error saying
Code:
Checking disk sda (4096 byte sectors)
Unmounted /dev/sda1
umount: can't umount /mnt/hd2: Device or resource busy
fix-disk: session terminated with exit status 1
I'm not clear exactly what disk or partition hd2 is referring to.

Is there a way of getting round this? It's not the end of the world if the disk is unrecoverable - it's only telly as these pages remind us - but it would be nice if I could get the recordings off it.

Supporting info:
  • versions: [ Humax HDR-Fox T2 (humax) 1.03.12/3.13 ];
  • existing disk is a 2TB HDD I put in some years ago;
  • stats have been getting gradually worse for a long tme so it's demise is not a surprise;
  • box is accessed via wifi dongle;
  • box is configured for use with a NAS drive but I have turned that NAS drive off and removed the USB stick from the Humax;
  • the HDD is now so flaky the box doesn't always recognise it and the web interface now sometimes says "No internal disk found."
 
Thanks BH. I read through that thread but couldn't see anything that helped unfortunately (unless I'm missing something): I still can't figure out what the hd2 mount physically relates to.

I tried "umount /mnt/hd2" from the CLI but got "umount: can't umount /mnt/hd2: Device or resource busy".

"diskattr" completed ok with the expected stats but nothing there I can see that helps.

"stat" gave the following:
Code:
/mod/webif/lib/settings.class:6: Error: unable to open database file
in procedure 'require' called at file "/mod/bin/status", line 5
at file "/mod/webif/lib/setup", line 8
in procedure 'require' called at file "/mod/webif/lib/epg.class", line 6
at file "/mod/webif/lib/setup", line 8
at file "/mod/webif/lib/settings.class", line 6

Looks like I'll just have to replace the disk and hope for the best with the old one putting it in a USB caddy and linking to the laptop.

Quick question: is installing a large (3 or 4TB) disk as easy as it sounds from https://wiki.hummy.tv/wiki/Very_Large_Hard_Drive - install drive, install CF from a USB stick (I assume it installs to non-volatile memory rather than disk?!), run the gptf option?
 
This should show which processes have files open on /mnt/hd2 (if procps is installed).
Code:
ps -p $(fuser -m /mnt/hd2)
 
Looks like I'll just have to replace the disk
That should not be necessary, there are enough experts here to work out what the problem is (with your co-operation)... starting with an answer to the above which will (hopefully) reveal what has locked the hd2 partition from being unmounted.

Quick question: is installing a large (3 or 4TB) disk as easy as it sounds from https://wiki.hummy.tv/wiki/Very_Large_Hard_Drive - install drive, install CF from a USB stick (I assume it installs to non-volatile memory rather than disk?!), run the gptf option?
Yes, it should be that easy... but why do you think you need to re-install the CF? As you have already noted, it's not on the HDD.
 
This should show which processes have files open on /mnt/hd2 (if procps is installed).

Thanks @xyz321 , here is the output it gave:
Code:
humax# ps -p $(fuser -m /mnt/hd2)
  PID TTY      STAT   TIME COMMAND
  292 ?        Sl    14:22 /usr/bin/humaxtv
 1684 ?        Ss     0:00 udhcpc -t 5 -T 10 -p /var/lib/humaxtv/udhcpc.wlan0.pid -i wlan0

So I changedthe wifi settings from hdcp to manual ip and restarted using the remote and ran again: this time I got:
Code:
humax# ps -p $(fuser -m /mnt/hd2)
  PID TTY          TIME CMD
 1684 ?        00:00:00 udhcpc

I was hopeful this might be freed once in maintenance mode so I tried running fixdisk again and yay, it's working! Thank you. This may be worth noting in case anyone else has this issue.

So fixdisk is now running. The last time I ran it - perhaps 6 months ago - it took days rather than hours so I'm expecting the same this time. After fixing a number of bad blocks the display is currently stuck running the short disk self test, I'll leave it running for a while and see what happens.

Yes, it should be that easy
Excellent news, thank you @Black Hole
Regarding disk replacement, the current one has been been in many years and has been degrading for a long time as evidenced by what's been a fairly constant stream of notifications in recent months, so at this point I think fixdisk will be just a sticking plaster on a terminally sick drive.
but why do you think you need to re-install the CF? As you have already noted, it's not on the HDD.
A good point well presented! Sometimes I worry about my brain...
 
I still can't figure out what the hd2 mount physically relates to.
It's the second partition (media) on the internal hard disk.
I was hopeful this might be freed once in maintenance mode
You were supposed to run the command xyz321 gave you when you were already in maintenance mode. That fact that humaxtv was running seems to imply you weren't.
What DHCP has to do with any of this I can't imagine.
 
That was not stated. I ran it from CLI.
I think you are getting confused between Maintenance Mode, CLI, and WebIF. You might be using WebIF >> Diagnostics >> Command Line to access the CLI, but you can also access the CLI from the Telnet menu (available via the WebIF browser page while in Maintenance Mode).

fixdisk is supposed to be run while in Maintenance Mode; Maintenance Mode frees up the hard drive partitions by stopping the humaxtv process (or, actually, not allowing the humaxtv process to start at boot), and also the WebIF.

I was hopeful this might be freed once in maintenance mode so I tried running fixdisk again and yay, it's working!
...so basically any processes you saw running while not in maintenance mode were irrelevant to the problem.
 
I am at a loss to understand how the problem arose in the first place. If fixdisk (actually fix-disk) is run from the command line when not in maintenance mode, this is the result...
Code:
pvr# fix-disk 
Running /var/lib/humaxtv_backup/mod/fix-disk
Fix-disk can only be used in maintenance mode.
Restart this unit in maintenance mode via the web interface or telnet
menu.

pvr#
 
Last edited:
Back
Top