Externe USB-Festplatte bleibt beim Ausschalten an

    Diese Seite verwendet Cookies. Durch die Nutzung unserer Seite erklären Sie sich damit einverstanden, dass wir Cookies setzen. Weitere Informationen

    • War mein Fehler. Ich hatte zuerst nach rc1d gefragt, brauche aber rc0.d hatte es in Post noch schnell verbessert aber du warst schneller.


      kannst du also rc0.d schicken
    • Ausgabe rc0.d


      Spoiler anzeigen

      root@vuduo4k:~# cd /etc/rc0.d
      root@vuduo4k:/etc/rc0.d# ls -l
      lrwxrwxrwx 1 root root 18 Jan 1 1970 K10dropbear -> ../init.d/dropbear
      lrwxrwxrwx 1 root root 24 Jan 1 1970 K10softwareupdate -> ../init.d/softwareupdate
      lrwxrwxrwx 1 root root 22 Jan 1 1970 K19avahi-daemon -> ../init.d/avahi-daemon
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K20autofs -> ../init.d/autofs
      lrwxrwxrwx 1 root root 22 Jan 1 1970 K20busybox-cron -> ../init.d/busybox-cron
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K20dbus-1 -> ../init.d/dbus-1
      lrwxrwxrwx 1 root root 23 Jan 1 1970 K20inetd.busybox -> ../init.d/inetd.busybox
      lrwxrwxrwx 1 root root 15 Jan 1 1970 K20samba -> ../init.d/samba
      lrwxrwxrwx 1 root root 21 Oct 8 21:01 K20satipclient -> ../init.d/satipclient
      lrwxrwxrwx 1 root root 24 Jan 1 1970 K20shellinabox.sh -> ../init.d/shellinabox.sh
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K20syslog -> ../init.d/syslog
      lrwxrwxrwx 1 root root 24 Jan 1 1970 K20usbtunerhelper -> ../init.d/usbtunerhelper
      lrwxrwxrwx 1 root root 22 Jan 1 1970 K31umountnfs.sh -> ../init.d/umountnfs.sh
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K60smartd -> ../init.d/smartd
      lrwxrwxrwx 1 root root 20 Jan 1 1970 K80networking -> ../init.d/networking
      lrwxrwxrwx 1 root root 25 Jan 1 1970 K89vuplus-bootlogo -> ../init.d/vuplus-bootlogo
      lrwxrwxrwx 1 root root 30 Dec 24 23:43 K90vuplus-platform-util -> ../init.d/vuplus-platform-util
      lrwxrwxrwx 1 root root 18 Jan 1 1970 S20sendsigs -> ../init.d/sendsigs
      lrwxrwxrwx 1 root root 17 Jan 1 1970 S30urandom -> ../init.d/urandom
      lrwxrwxrwx 1 root root 18 Jan 1 1970 S40umountfs -> ../init.d/umountfs
      lrwxrwxrwx 1 root root 14 Jan 1 1970 S90halt -> ../init.d/halt

      Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von jimmyhartwig ()

    • schickst du mir noch den output von

      Quellcode

      1. cat /etc/init.d/halt

      wenn deine externe läuft, geht die dann in den standby, wenn du das hier machst?

      Quellcode

      1. sdparm --command=stop /dev/sdx
      Wie genau heißt deine externe? /dev/sdb ?

      wenn sdparm klappt, baue ich dir ein kleines Script und sage dir dann, was du damit machen sollst
    • output

      Spoiler anzeigen

      root@vuduo4k:~# cat /etc/init.d/halt
      #!/bin/sh
      ### BEGIN INIT INFO
      # Provides: halt
      # Required-Start:
      # Required-Stop:
      # Default-Start:
      # Default-Stop: 0
      # Short-Description: Execute the halt command.
      # Description:
      ### END INIT INFO


      PATH=/sbin:/bin:/usr/sbin:/usr/bin


      # See if we need to cut the power.
      if test -x /etc/init.d/ups-monitor
      then
      /etc/init.d/ups-monitor poweroff
      fi


      # Don't shut down drives if we're using RAID.
      hddown="-h"
      if grep -qs '^md.*active' /proc/mdstat
      then
      hddown=""
      fi


      /usr/bin/turnoff_power


      halt -d -f -i -p $hddown


      : exit 0



      sdb heisst die Platte

      sdparm Befehl funktioniert nicht....

      Spoiler anzeigen

      root@vuduo4k:~# sdparm --command=stop /dev/sdb
      -sh: sdparm: not found
    • geht

      hdparm -y /dev/sdb
      oder
      hdparm -Y /dev/sdb

      und legt die HDD schlafen?

      Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von anudanan ()

    • so, erster Versuch.

      Die in der ZIP Datei enthaltene Datei nach
      /etc/init.d
      kopieren. Dann auf die Kommandozeile gehen und folgende Dinge eingeben
      Spoiler anzeigen

      cd /etc/init.d
      chmod 755 usbhdd-standby.sh
      cd /etc/rc0.d
      ln -s ../init.d/usbhdd-standby.sh S85usbhdd-standby


      danach kannst du mal eingeben
      ./S85usbhdd-standby

      und die HDD müsste in den Standby gehen. Ich habe 2 Sekunden Wartezeit vor dem Standby eingebaut, damit nach dem umount etwas Zeit vergeht, bis die in den standby geht

      Wenn das klappt, kannst du das mal mit dem deepstandby probieren
      Dateien

      Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von anudanan ()

    • zip Anhang habe ich entpackt und in den Ordner kopiert.
      Befehle habe ich alle eingegeben.

      Aber beim letzten Befehl kommt eine Fehlermeldung

      Spoiler anzeigen

      root@vuduo4k:~# cd /etc/init.d
      root@vuduo4k:/etc/init.d# chmod 755 usbhdd-standby.sh
      root@vuduo4k:/etc/init.d# cd /etc/rc0.d
      root@vuduo4k:/etc/rc0.d# ln -s ../init.d/usbhdd-standby.sh S85usbhdd-standby
      root@vuduo4k:/etc/rc0.d# ./S85usbhdd-standby
      -sh: ./S85usbhdd-standby: not found
      root@vuduo4k:/etc/rc0.d#
    • Spoiler anzeigen

      root@vuduo4k:~# cd /etc/rc0.d
      root@vuduo4k:/etc/rc0.d# ls -l
      lrwxrwxrwx 1 root root 18 Jan 1 1970 K10dropbear -> ../init.d/dropbear
      lrwxrwxrwx 1 root root 24 Jan 1 1970 K10softwareupdate -> ../init.d/softwareupdate
      lrwxrwxrwx 1 root root 22 Jan 1 1970 K19avahi-daemon -> ../init.d/avahi-daemon
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K20autofs -> ../init.d/autofs
      lrwxrwxrwx 1 root root 22 Jan 1 1970 K20busybox-cron -> ../init.d/busybox-cron
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K20dbus-1 -> ../init.d/dbus-1
      lrwxrwxrwx 1 root root 23 Jan 1 1970 K20inetd.busybox -> ../init.d/inetd.busybox
      lrwxrwxrwx 1 root root 15 Jan 1 1970 K20samba -> ../init.d/samba
      lrwxrwxrwx 1 root root 21 Oct 8 21:01 K20satipclient -> ../init.d/satipclient
      lrwxrwxrwx 1 root root 24 Jan 1 1970 K20shellinabox.sh -> ../init.d/shellinabox.sh
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K20syslog -> ../init.d/syslog
      lrwxrwxrwx 1 root root 24 Jan 1 1970 K20usbtunerhelper -> ../init.d/usbtunerhelper
      lrwxrwxrwx 1 root root 22 Jan 1 1970 K31umountnfs.sh -> ../init.d/umountnfs.sh
      lrwxrwxrwx 1 root root 16 Jan 1 1970 K60smartd -> ../init.d/smartd
      lrwxrwxrwx 1 root root 20 Jan 1 1970 K80networking -> ../init.d/networking
      lrwxrwxrwx 1 root root 25 Jan 1 1970 K89vuplus-bootlogo -> ../init.d/vuplus-bootlogo
      lrwxrwxrwx 1 root root 30 Dec 24 23:43 K90vuplus-platform-util -> ../init.d/vuplus-platform-util
      lrwxrwxrwx 1 root root 18 Jan 1 1970 S20sendsigs -> ../init.d/sendsigs
      lrwxrwxrwx 1 root root 17 Jan 1 1970 S30urandom -> ../init.d/urandom
      lrwxrwxrwx 1 root root 18 Jan 1 1970 S40umountfs -> ../init.d/umountfs
      lrwxrwxrwx 1 root root 27 Jan 9 19:00 S85usbhdd-standby -> ../init.d/usbhdd-standby.sh
      lrwxrwxrwx 1 root root 14 Jan 1 1970 S90halt -> ../init.d/halt
    • mache mal
      cat S85usbhdd-standby

      Wenn da was ausgegeben wird, dann mache mal den deepstandby, ob es doch geht

      Eigentlich müsste die Datei ausgeführt werden können mit
      ./S85usbhdd-standby
      tut bei mir auch
    • Ausgabe cat S85usbhdd-standby

      Spoiler anzeigen

      root@vuduo4k:/etc/rc0.d# cat S85usbhdd-standby
      #!/bin/sh
      ### BEGIN INIT INFO
      ### END INIT INFO


      PATH=/sbin:/bin:/usr/sbin:/usr/bin
      sleep 2
      hdparm -y /dev/sdb



      deepstandby gemacht vor 5 Minuten, Festplatte läuft aber noch.
    • was zeigt

      ls -l /etc/init.d


      irgendwie scheint die Datei nicht ausgeführt zu werden, so wie auch bei deinem Handtest
    • ls -l /etc/init.d

      Spoiler anzeigen

      root@vuduo4k:~# ls -l /etc/init.d
      -rwxr-xr-x 1 root root 250 Nov 8 2018 alignment.sh
      -rwxr-xr-x 1 root root 2786 Nov 13 2018 autofs
      -rwxr-xr-x 1 root root 4491 Nov 13 2018 avahi-daemon
      -rwxr-xr-x 1 root root 494 Nov 8 2018 banner.sh
      -rwxr-xr-x 1 root root 1997 Nov 13 2018 bootlogd
      -rwxr-xr-x 1 root root 1583 Nov 8 2018 bootmisc.sh
      -rwxr-xr-x 1 root root 681 Nov 13 2018 busybox-cron
      -rwxr-xr-x 1 root root 3581 Nov 8 2018 checkroot.sh
      lrwxrwxrwx 1 root root 33 Jan 5 22:20 current_cam.sh -> /usr/script/oscam-tj-11572_cam.sh
      -rwxr-xr-x 1 root root 2887 Nov 13 2018 dbus-1
      -rwxr-xr-x 1 root root 2480 Jul 11 2017 devicemanager
      -rwxr-xr-x 1 root root 526 Nov 8 2018 devpts.sh
      -rwxr-xr-x 1 root root 353 Nov 8 2018 dmesg.sh
      -rwxr-xr-x 1 root root 3002 Nov 13 2018 dropbear
      lrwxrwxrwx 1 root root 33 Jan 1 1970 functions -> /etc/init.d/functions.initscripts
      -rw-r--r-- 1 root root 2141 Nov 8 2018 functions.initscripts
      -rwxr-xr-x 1 root root 1893 Nov 13 2018 fuse
      -rwxr-xr-x 1 root root 537 Nov 8 2018 halt
      -rwxr-xr-x 1 root root 580 Nov 8 2018 hostname.sh
      -rwxr-xr-x 1 root root 579 Nov 13 2018 inetd.busybox
      -rwxr-xr-x 1 root root 1223 Nov 13 2018 modutils.sh
      -rwxr-xr-x 1 root root 859 Nov 8 2018 mountall.sh
      -rwxr-xr-x 1 root root 1522 Nov 8 2018 mountnfs.sh
      -rwxr-xr-x 1 root root 1956 Nov 14 2018 networking
      -rwxr-xr-x 1 root root 535 Jul 11 2017 ntpupdate.sh
      -rwxr-xr-x 1 root root 2418 Nov 13 2018 openvpn
      -rwxr-xr-x 1 root root 6330 Nov 8 2018 populate-volatile.sh
      -rwxr-xr-x 1 root root 1231 Nov 13 2018 ppp
      -rwxr-xr-x 1 root root 4320 Nov 13 2018 rc
      -rwxr-xr-x 1 root root 525 Nov 13 2018 rcS
      -rwxr-xr-x 1 root root 968 Nov 8 2018 read-only-rootfs-hook.sh
      -rwxr-xr-x 1 root root 289 Nov 8 2018 reboot
      -rwxr-xr-x 1 root root 585 Nov 8 2018 rmnologin.sh
      -rwxr-xr-x 1 root root 25 Nov 8 2018 run-postinsts
      -rwxr-xr-x 1 root root 2488 Nov 13 2018 samba
      -rwxr-xr-x 1 root root 311 Oct 8 14:05 satipclient
      -rwxr-xr-x 1 root root 438 Nov 8 2018 sendsigs
      -rwxr-xr-x 1 root root 1895 Nov 13 2018 shellinabox.sh
      -rwxr-xr-x 1 root root 578 Nov 8 2018 single
      -rwxr-xr-x 1 root root 3273 Nov 13 2018 smartd
      -rwxr-xr-x 1 root root 872 Feb 18 2018 softwareupdate
      lrwxrwxrwx 1 root root 8 Jan 1 1970 stop-bootlogd -> bootlogd
      -rwxr-xr-x 1 root root 660 Nov 8 2018 sysfs.sh
      lrwxrwxrwx 1 root root 26 Jan 1 1970 syslog -> /etc/init.d/syslog.busybox
      -rwxr-xr-x 1 root root 1715 Nov 13 2018 syslog.busybox
      -rwxr-xr-x 1 root root 850 Nov 13 2018 udev
      -rwxr-xr-x 1 root root 2166 Nov 13 2018 udev-cache
      -rwxr-xr-x 1 root root 1003 Nov 8 2018 umountfs
      -rwxr-xr-x 1 root root 877 Nov 8 2018 umountnfs.sh
      -rwxr-xr-x 1 root root 420 Nov 13 2018 update_systemconfig.sh
      -rwxr-xr-x 1 root root 1473 Nov 8 2018 urandom
      -rwxr-xr-x 1 root root 120 Jan 9 18:59 usbhdd-standby.sh
      -rwxr-xr-x 1 root root 520 Nov 13 2018 usbtunerhelper
      -rwxr-xr-x 1 root root 1031 Mar 5 2019 vuhd1080p-default-template
      -rwxr-xr-x 1 root root 485 Nov 13 2018 vuplus-bootlogo
      -rwxr-xr-x 1 root root 1243 Dec 23 16:16 vuplus-platform-util
      -rwxr-xr-x 1 root root 856 Nov 13 2018 wsdd.sh
    • mmh

      klappt denn
      cd /etc/rc0.d
      ./S40umountfs

      Damit würden dann die HDDs abgemeldete.
    • Spoiler anzeigen

      root@vuduo4k:~# cd /etc/rc0.d
      root@vuduo4k:/etc/rc0.d# ./S40umountfs
      Deactivating swap...
      Unmounting local filesystems...
      umount: /etc/auto.network_vti busy - remounted read-only
      umount: /etc/auto.network busy - remounted read-only
      umount: /etc/auto.hotplug busy - remounted read-only
      umount: devpts busy - remounted read-only
      umount: can't remount tmpfs read-only
      umount: can't remount tmpfs read-only
      mount: mounting /dev/root on / failed: Device or resource busy
    • dann mache mal
      cat /etc/rc0.d/S40umountfs

      Vielleicht sind die scripte da anders aufgebaut als bei mir
    • Spoiler anzeigen

      root@vuduo4k:/etc/rc0.d# cat /etc/rc0.d/S40umountfs
      #!/bin/sh
      #
      # umountfs Turn off swap and unmount all local filesystems.
      #


      PATH=/sbin:/bin:/usr/sbin:/usr/bin


      # Ensure /proc is mounted
      test -r /proc/mounts || mount -t proc proc /proc


      echo "Deactivating swap..."
      swapoff -a


      # We leave /proc mounted, the umount of /dev/devpts seems to fail
      # quite frequently, the busybox umount apparently gives up at the
      # first failure, so it is necessary to go file system by file
      # system. It is necessary to go backward in the /proc list, because
      # later things may have been mounted on earlier mounts.
      unmount() {
      local dev mp type opts
      if read dev mp type opts
      then
      # recurse - unmount later items
      unmount
      # skip / and needed virtual filesystems
      case "$mp" in
      /|/dev|/proc|/sys) return 0;;
      esac
      # then unmount this, if possible, otherwise make
      # it read-only
      umount -f -r "$mp"
      fi
      }


      echo "Unmounting local filesystems..."
      unmount </proc/mounts


      mount -o remount,ro /


      # sync to flush pending writes for loop-mounted file system.
      sync
    • puh, ich bin verwirrt

      was passiert bei
      sh /etc/rc0.d/usbhdd-standby
    • Spoiler anzeigen

      root@vuduo4k:/etc/rc0.d# sh /etc/rc0.d/usbhdd-standby
      sh: can't open '/etc/rc0.d/usbhdd-standby'