INSTALL ENTWARE ON WD MY CLOUD HOME (SSH ACCESS, NFS SERVER, OPKG install packages)

Hello dr3mro,
On the web page of entware, it is mentioned that you have to start the Entware service after restarting with init.d/su.d

I did not find init.d, here is how I proceeded with the help of CRON:
mount the /system partition Read and Write :

/system/bin/mount -o rw,remount /system
nano /system/bin/entware.sh

copy paste the following text :

#!/system/bin/sh

PIDFILE="/opt/var/run/dropbear.pid"

dropbear_status ()
{
        [ -f $PIDFILE ] && [ -d /proc/`cat $PIDFILE` ]
}


start()
{
        unset LD_PRELOAD
        unset LD_LIBRARY_PATH
        sleep 3
        /system/bin/mount -o rw,remount /
        sleep 1
        /system/bin/mkdir /opt
        /system/bin/mount -o ro,remount /
        sleep 3
        /system/bin/mount -o bind /data/entware.arm /opt
        sleep 2
        /opt/etc/init.d/rc.unslung start
        sleep 2
}

stop()
{
        kill `cat $PIDFILE`
}
case "$1" in
        start)
                if dropbear_status
                then
                        echo dropbear already running
                else
                        start
                fi
                ;;
        stop)
                if dropbear_status
                then
                        stop
                else
                        echo dropbear is not running
                fi
                ;;
        status)
                if dropbear_status
                then
                        echo dropbear already running
                else
                        echo dropbear is not running
                fi
                ;;

        restart)
                stop
                sleep 3
                start
                ;;
        *)
                echo "Usage: $0 {start|stop|restart|status}"
                ;;
esac

Save the file.
make it executable:

chmod 755 /system/bin/entware.sh

edit the CRON :

nano /system/etc/cron/root

Insert the following line:

# lancement du logiciel entware au démarrage
*/1 * * * * /system/bin/entware.sh start

Save te file.

file system in read :
/system/bin/mount -o ro,remount /

enjoy :wink:

1 Like