USB Drive can't go to standby or wakes up seconds after going to standby

Hi

I am trying to use openwrt with my DIR-860L as a DLNA Server.
So far the DLNA is working. But the USB Drive with the Media Files on it can't go to standby or it wakes up from standby just seconds after it went into standby.
This depends on which external USB HDD Case I use.
The LED of the HDD case shows if its
active (LED ON)
or
in standby (LED OFF).

In Standby the Power Consumption is very low, therefore thats what I want.

I have 2 different types of these USB 2.5" external HDD cases.

  • One sends the Drive into standby just after a few minutes without access.
  • The other one doesn't do that and so the drive remains active all time.
    This works wherever I connect the external cases to.
    It does not depend on the actual drive that is used.

It also worked with the DIR-860L before changing the Firmware to openwrt. With openwrt the case which puts the HDD to sleep
is somehow triggert to wake it up again only a few seconds after it went into standby. Every time....

The System and Kernel Log do not show any entries at that time.
Also there is no access through lan. I even disconnected all lan cables and still it happens the same way. W-LAN is also off.
I installed openwrt with only few additional packages for USB, NTFS and DLNA to work.

I was wondering if somebody had a clue which option or package could be responsible for this behavior. Or how I could find out what triggers this.

I am new to oprenwrt but so far manged to get it working.
Unfortunately I only achieved the total opposite of what I was looking for. I wanted a better standby not a worse.
It was working very good for many years on my old DIR-645 but that one is too slow now.
The DIR-860L is faster, but for some reason with the original Firmware it wakes up the USB Drive from Standby every hour.
Probably because the TV checks if the DLNA-Server is still there.
I was trying to solve this by using openwrt. But so far its no improvement.

Thanks for any help.

disable applications on at a time... lsof...

Hello

Thank you for your answer.

I found out that even if the USB Drive in not mounted anymore it is still triggered to wake up after a few seconds only.

Also as far as I can tell there is no access to the files on the USB Drive.

So the drive is woken directly and not just by accessing files on it.

I am not that good with Linux so far but I think that means that the USB Packages or something related to that must be responsible for it ...

Because other file based services like minidlna can not access the files anymore when the drive is not mounted anymore.

I can not remove the USB Packages...because they are needed to work with the USB Drive.

I also tried hdparm but this reports an error which means it doesn’t work.

I also tried hd-idle but this also isn’t doing anyhing at all.

I tried both tools with both my usb hdd cases.

There must be some Linux Way to find out what triggers the USB Device to wake up.

Some USB or Hardware or Drive log or anyting like that.

So what can I do ???

Thank you

Nic

ok, good to see you pretty much isolated the issue from applications.

search up on lsusb and try harder with hdparm...

let us know the controller chipsets involved... at the end of the day... there is information on the web about testing these things....

1 Like

Zwischenablage01

lsusb shows this

Hello

The Problem is solved.
One of the USB Packages was the Problem.
I guess it was this "block-mount" Package.

I tried what wulfy23 suggested, to remove packages one by one. It turned out to be a really bad idea to do this if you have no clue what the packages are needed for.

Therefore I can only recommend to everybody never to do that.

Here is why:
After a few packages were removed, I noticed that something was not working anymore. So I thought, no Problem, just make a Reset and start all over (I did that before).
But:
The Reset (probably also performed by one of the packages) was not working anymore. Most likely because it was a Package I already removed. ... so what now ?
The Router wasn't working anymore.
The Reset wasn't working anymore.
The Router was unable to Start.
Good thing there is an Emergency Option to Flash New Image.
Otherwise the Router would have been dead.

So solved after all and learned a lot of new things :slight_smile:

Glad you solved it.....! And glad your posting your experience for others to learn from...

to be fair, in no way did I advise you to "remove packages one by one"...

for future readers, what I envisaged was something more like

/etc/init.d/DLNAwhatever stop
/etc/init.d/SERVICE stop

( or you can stop them in LUCI too )

it's the toggling of them one by one that is beneficial

Yes, "block-mount" or /etc/config/fstab may play a role in how your OS interacts with disks. That is what it is there for and i'm glad you were able to zero in on it ( without help! )

Also for clarity, anyone reading this at a later date should note that editing /etc/config/fstab should be sufficient.... There should be no need to remove it.

/etc/config/fstab was empty all the time since the mounting was done manually and with NTFS (for testing only).

So that would not have been a solution in my case.

I told you I was new with linux and I had not seen this “stopping services” section.

If such a stopped service would be enabled again with the next system start, then

that would be better working and might not make the system un-startable.

However it would still be difficult to find out if a specific service is needed or not

if you don’t know its purpose. One can not test all functions of the system after

each stop of a new service. So I’m glad too its working now.

Thank you after all, otherwise I would not have found the solution.

Greetings

Nic

1 Like

fair point. all things considered you've done very well

routers definitely can be unforgiving at a lower level... the number of times i've bricked my pc-linux-os whilst "testing" LOL

if anyone hits this thread...

  1. setup working block mount first > test idle

(be careful not to add any unneeded packages too early)

  1. setup hdidle / hdparm if needed > test idle
  2. add file sharing services > test idle
  3. add media sharing services > test idle

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.