USB storage devices are unmounted when I close the lid of the laptop

3

1

I'm running an ubuntu 12.04 on my laptop. And, I'm going to use it as a home server.

I have 3 TiB-hard disk connected through a usb port. This disk is necessary. But, every time I close the lid of the laptop, I can't use it because it is disconnected from the laptop.

How can I keep the usb-disk mounted on my laptop.

My laptop has an atom CPU, and it is 2 yrs old.

19 Lee

Posted 2012-07-02T12:47:32.503

Reputation: 95

Does the laptop enter some kind of sleep mode when you close the lid, or is it still fully up and running? – a CVn – 2012-07-02T13:18:34.597

In general, laptops tend to not be very well suited as (even low-powered) servers because of limited heat dissipation capability. This will almost certainly become a concern if you run it 24/7. – a CVn – 2012-07-02T13:19:29.337

I forgot I mentioned it. It doesn't fall into sleep since I prevent it from sleeping. I put my laptop upside down to help it cooled a little bit. It is still too warm as you mentioned. I'm looking for the coldest place in my house for now. – 19 Lee – 2012-07-02T14:46:42.527

Answers

2

# disable external wake-up; do this only once
echo disabled > /sys/bus/usb/devices/usb1/power/wakeup
# turn USB power on
echo on > /sys/bus/usb/devices/usb1/power/level
# turn suspend off
echo suspend > /sys/bus/usb/devices/usb1/power/level

also go to bios and check usb settings.Some bios have option named always on usb. enable it. references: https://askubuntu.com/questions/99474/suspend-usb-power-to-a-laptop-cooling-pad-when-going-to-suspend-mode

https://stackoverflow.com/questions/4702216/controlling-a-usb-power-supply-on-off-with-linux

arundevma

Posted 2012-07-02T12:47:32.503

Reputation: 1 404

You're a genius! I guess the following is working: echo disabled > sudo /sys/bus/usb/devices/usb5/power/wakeup – 19 Lee – 2012-07-02T13:26:14.307