The DroidSSH is always stable on my two device, it never complain any problem to me, it is a option of my goal and it is only success of my trying, ok let beginning.
1. Install the DroidSSH from Google Play and launch it, it will spend more time at first run, the others procedure you may setting your device with DroidSSH or your terminal emulation.
2. Create the directory /data/local/userinit.d
3. Create file /data/local/userinit.d/90sshd and edit it.
4. paste the contents bellow
# ================ start ===================
#!/system/bin/sh
umask 077
/data/data/berserker.android.apps.sshdroid/dropbear/dropbear -H /data/user -Y "PASSWORD" -S -p 22 -r /data/data/berserker.android.apps.sshdroid/dropbear/dropbear.key.rsa -d /data/data/berserker.android.apps.sshdroid/dropbear/dropbear.key.dss
#================= end ===================
4. paste the contents bellow
# ================ start ===================
#!/system/bin/sh
umask 077
/data/data/berserker.android.apps.sshdroid/dropbear/dropbear -H /data/user -Y "PASSWORD" -S -p 22 -r /data/data/berserker.android.apps.sshdroid/dropbear/dropbear.key.rsa -d /data/data/berserker.android.apps.sshdroid/dropbear/dropbear.key.dss
#================= end ===================
5. Change the permission and group
chmod 755 /data/local/userinit.d/90sshd
chgrp shell /data/local/userinit.d/90sshd
Ok, it finish, reboot your device, it will start as service.
Note:
1. -H mean the home directory of user.
2. -Y specify the password, you should change it.
My reference:
沒有留言:
張貼留言