
This is an init.d script for auto mounting your NAS at boot. No apps required here.
Here is a great guide to understanding what init.d is and how it works
You will need
- a root explorer app like Root Browser
- This file that Daemonium kindly made for us (This contains the script below) http://goo.gl/uNl9KE
- Your Rom must be rooted
# Make sure networking is up before mounting
busybox sleep 60
setenforce permissive
# Switch rootfs to read / write
# Be carful after this. Misplaced commands may
# brick your system
busybox mount -o rw,remount /
# Create Mount Points // Edit this part to suit your needs
mkdir /mnt/internal_sd/01_Movies
#mkdir /mnt/internal_sd/02_Series
#mkdir /mnt/internal_sd/03_Documentation
#mkdir /mnt/internal_sd/04_Musical
#mkdir /mnt/05_ThisShareIsNotThePornFolder
# Switch rootfs to read only
busybox mount -o ro,remount /
#SBM Auto Mount // Edit this part to suit your need
busybox mount -t cifs -o user="your username",password="your password" //your.ip.here/yoursharename /mnt/internal_sd/01_Movies
#mount -t cifs -o user="your username", password="your password" //your.ip.here/yoursharenamehere /mnt/internal_sd/02_Series
#mount -t cifs -o user="your username", password="your password" //your.ip.here/yoursharenamehere /mnt/internal_sd/03_Documentation
#mount -t cifs -o user="your username", password="your password" //your.ip.here/yoursharenamehere /mnt/internal_sd/04_Musical
#mount -t cifs -o user="your username", password="your passowrd" //your.ip.here/yoursharenamehere /mnt/internal_sd/05_ThisShareIsNotTheP
Steps:
- Edit the file to suit your needs
- Copy it to /system/etc/init.d and give permissions 755 (execute, read write, read write)
The above step is where you will need the root browser type app.
If you have problems with shares not being mounted, try to change the line :
Comment