Difference between revisions of "User:Pineadmin/OpenMediaVault"

From PINE64
Jump to navigation Jump to search
Line 5: Line 5:


<pre<noinclude></noinclude> style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
<pre<noinclude></noinclude> style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
1. If no output on HDMI, you need to find the IP Address with tools (e.g. [https://www.softperfect.com/products/networkscanner/ netscan]) (hostname: PINE64, PINE64SO)
1. If no output on HDMI, you need to find the IP Address with tools (e.g. [https://www.softperfect.com/products/networkscanner/ netscan]) (hostname: ROCK64, PINE64, PINE64SO)


2. Use the IP Address on PC browser to login to the Web Admin Pages: admin / openmediavault  (Remember to change the default password: System -> General Settings -> Web Administrator Password)
2. Use the IP Address on PC browser to login to the Web Admin Pages: admin / openmediavault  (Remember to change the default password: System -> General Settings -> Web Administrator Password)


3. Plug USB Drive
3. You may want to use Static IP for easy access in future: System -> Network -> Interfaces -> Add


4. Go to Storage -> Physical Disks -> Scan
4. Plug Hard Drive


5. Go to Storage -> File Systems -> select the Partition to mount -> Mount -> Apply
5. Go to Storage -> Physical Disks -> Scan


6. Access Right Management -> User -> Add
6. Go to Storage -> File Systems -> select the Partition to mount -> Mount -> Apply


7. Access Right Management -> Shared Folders -> Add
7. Access Right Management -> User -> Add
 
8. Access Right Management -> Shared Folders -> Add
     - select newly added Shared Folder -> Privileges -> tick Read/Write -> Save
     - select newly added Shared Folder -> Privileges -> tick Read/Write -> Save
</pre>
</pre>
Line 25: Line 27:


<pre<noinclude></noinclude> style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
<pre<noinclude></noinclude> style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
1. Complete the "[[#Basic_Setup|Basic Setup]]" above
1. Go through the "[[#Basic_Setup|Basic Setup]]" above


2. Services -> FTP -> Settings -> Enable -> Save -> Apply
2. Services -> FTP -> Settings -> Enable -> Save -> Apply
                   -> Shares -> Add -> Apply
                   -> Shares -> Add -> Apply
If you constantly hit by "Permission denied", then you may consider: Services -> FTP -> Settings -> Permit root login (enable)
</pre>
</pre>


Line 37: Line 41:
You required 2 devices (e.g. 2 ROCK64, PINE64, SOPINE or etc) to Clone/Backup from master to slave or bidirectional
You required 2 devices (e.g. 2 ROCK64, PINE64, SOPINE or etc) to Clone/Backup from master to slave or bidirectional


1. Complete the "[[#Basic_Setup|Basic Setup]]" above
1. Go through the "[[#Basic_Setup|Basic Setup]]" above


2. [On slave/destination device] Services -> Rsync -> Server -> Settings -> Enable -> Save -> Apply
2. [On slave/destination device]
                                                    -> Modules -> Add -> General then User -> Add
    Services -> Rsync -> Server -> Settings -> Enable -> Save -> Apply
                                -> Modules -> Add -> General
    - Make sure to choose correct "User"
    - Enable "Authenticate users"
    - Fill in "Hosts allow" for more security
                                                  -> User -> Add


3. Services -> Rsync -> Jobs -> Add (Type: Remote, Mode: Push, Destination server: [USER]@[HOST]::[Module])
3. Services -> Rsync -> Jobs -> Add (Type: Remote, Mode: Push, Destination server: [USER]@[HOST]::[Rsync Server Module Name])
     - for testing: select Job -> Run
     - for testing: select Job -> Run
     - for bidirectional Rsync: Add another Job to Pull from slave/destination device (Don't enable Delete because new file/folder will be deleted)
     - for bidirectional Rsync: Add another Job to Pull from slave/destination device (Don't enable Delete because deleted file/folder may be copied over again)


4. Diagnostics -> System Logs
4. Diagnostics -> System Logs
Line 55: Line 64:
You required 2 devices (e.g. 2 ROCK64, PINE64, SOPINE or etc) to Clone/Backup from master to slave or bidirectional
You required 2 devices (e.g. 2 ROCK64, PINE64, SOPINE or etc) to Clone/Backup from master to slave or bidirectional


1. Complete the "[[#Basic_Setup|Basic Setup]]" above
1. Go through the "[[#Basic_Setup|Basic Setup]]" above


[IF YOU KNOW HOW TO SETUP DYNAMIC DNS ON YOUR INTERNET MODEM/ROUTER PLEASE SKIP TO #8]
[IF YOU KNOW HOW TO SETUP DYNAMIC DNS ON YOUR INTERNET MODEM/ROUTER PLEASE SKIP TO #8]
Line 102: Line 111:
8. On your internet modem/router: Port Forward to the slave/destination device with port 873.
8. On your internet modem/router: Port Forward to the slave/destination device with port 873.


9. [On slave/destination device] Services -> Rsync -> Server -> Settings -> Enable -> Save -> Apply
9. [On slave/destination device]
                                                    -> Modules -> Add -> General then User -> Add
    Services -> Rsync -> Server -> Settings -> Enable -> Save -> Apply
                                -> Modules -> Add -> General
    - Make sure to choose correct "User"
    - Enable "Authenticate users"
    - Fill in "Hosts allow" for more security
                                                  -> User -> Add


10. Services -> Rsync -> Jobs -> Add (Type: Remote, Mode: Push, Destination server: [USER]@[<<<CNAME>>>.ddns.net]::[Module])
10. Services -> Rsync -> Jobs -> Add (Type: Remote, Mode: Push, Destination server: [USER]@[<<<CNAME>>>.ddns.net]::[Rsync Server Module Name])
     - for testing: select Job -> Run
     - for testing: select Job -> Run
     - for bidirectional Rsync: Add another Job to Pull from slave/destination device (Don't enable Delete because new file/folder will be deleted)
     - for bidirectional Rsync: Add another Job to Pull from slave/destination device (Don't enable Delete because deleted file/folder may be copied over again)


11. Diagnostics -> System Logs
11. Diagnostics -> System Logs
</pre>
== SSH ==
<pre<noinclude></noinclude> style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
1. Go through the "[[#Basic_Setup|Basic Setup]]" above
2. Services -> SSH -> Permit root login (enable)  (Remember to always disable it back for security reason)
3. SSH to the device with Putty: root / openmediavault  (Remember to change the default password)
</pre>
</pre>

Revision as of 10:21, 1 December 2017

If you are dealing with confidential files transfer/sharing, please make sure your setup is secured with long and hard to guess random password or PKI keys. Make sure you use DUMMY folders/files for testing first to get yourself familiar and comfortable with the settings.


Basic Setup

1. If no output on HDMI, you need to find the IP Address with tools (e.g. netscan) (hostname: ROCK64, PINE64, PINE64SO)

2. Use the IP Address on PC browser to login to the Web Admin Pages: admin / openmediavault  (Remember to change the default password: System -> General Settings -> Web Administrator Password)

3. You may want to use Static IP for easy access in future: System -> Network -> Interfaces -> Add

4. Plug Hard Drive

5. Go to Storage -> Physical Disks -> Scan

6. Go to Storage -> File Systems -> select the Partition to mount -> Mount -> Apply

7. Access Right Management -> User -> Add

8. Access Right Management -> Shared Folders -> Add
    - select newly added Shared Folder -> Privileges -> tick Read/Write -> Save


FTP

1. Go through the "Basic Setup" above

2. Services -> FTP -> Settings -> Enable -> Save -> Apply
                   -> Shares -> Add -> Apply

If you constantly hit by "Permission denied", then you may consider: Services -> FTP -> Settings -> Permit root login (enable)


Rsync Clone/Backup

You required 2 devices (e.g. 2 ROCK64, PINE64, SOPINE or etc) to Clone/Backup from master to slave or bidirectional

1. Go through the "Basic Setup" above

2. [On slave/destination device]
    Services -> Rsync -> Server -> Settings -> Enable -> Save -> Apply
                                -> Modules -> Add -> General
     - Make sure to choose correct "User"
     - Enable "Authenticate users"
     - Fill in "Hosts allow" for more security
                                                  -> User -> Add

3. Services -> Rsync -> Jobs -> Add (Type: Remote, Mode: Push, Destination server: [USER]@[HOST]::[Rsync Server Module Name])
    - for testing: select Job -> Run
    - for bidirectional Rsync: Add another Job to Pull from slave/destination device (Don't enable Delete because deleted file/folder may be copied over again)

4. Diagnostics -> System Logs


Rsync Clone/Backup (Through Internet)

You required 2 devices (e.g. 2 ROCK64, PINE64, SOPINE or etc) to Clone/Backup from master to slave or bidirectional

1. Go through the "Basic Setup" above

[IF YOU KNOW HOW TO SETUP DYNAMIC DNS ON YOUR INTERNET MODEM/ROUTER PLEASE SKIP TO #8]

2. Services -> SSH -> Permit root login (enable)  (Remember to always disable it back for security reason)

3. SSH to the device with Putty: root / openmediavault  (Remember to change the default password)

4. # apt-get install ddclient  (no-ip.com example)

Dynamic DNS service provider: other
Dynamic DNS server: dynupdate.no-ip.com
Dynamic DNS update protocol: dyndns2
Username for dynamic DNS service: <<<USERNAME/EMAIL>>>
Password for dynamic DNS service: <<<PASSWORD>>>
Re-enter password to verify: <<<PASSWORD>>>
Network interface used for dynamic DNS service: web
DynDNS fully qualified domain names: <<<CNAME>>>.ddns.net
Run ddclient on PPP connect? No
Run ddclient as daemon? Yes
Interval between ddclient runs: 300

# dpkg-reconfigure ddclient  (To Re-run configuration wizard above)

5. # vi /etc/ddclient.conf

Change: use=if, if=web
To:     use=web, web=checkip.dyndns.com, web-skip='Current IP Address'

##########
protocol=dyndns2
use=web, web=checkip.dyndns.com, web-skip='Current IP Address'
server=dynupdate.no-ip.com
login=<<<USERNAME/EMAIL>>>
password='<<<PASSWORD>>>'
<<<CNAME>>>.ddns.net
##########

6. # systemctl restart ddclient  (Restart ddclient after changed in configuration)

7. Diagnostics:

# ddclient -daemon=0 -debug -verbose -noquiet
# systemctl status ddclient

8. On your internet modem/router: Port Forward to the slave/destination device with port 873.

9. [On slave/destination device]
    Services -> Rsync -> Server -> Settings -> Enable -> Save -> Apply
                                -> Modules -> Add -> General
     - Make sure to choose correct "User"
     - Enable "Authenticate users"
     - Fill in "Hosts allow" for more security
                                                  -> User -> Add

10. Services -> Rsync -> Jobs -> Add (Type: Remote, Mode: Push, Destination server: [USER]@[<<<CNAME>>>.ddns.net]::[Rsync Server Module Name])
    - for testing: select Job -> Run
    - for bidirectional Rsync: Add another Job to Pull from slave/destination device (Don't enable Delete because deleted file/folder may be copied over again)

11. Diagnostics -> System Logs


SSH

1. Go through the "Basic Setup" above

2. Services -> SSH -> Permit root login (enable)  (Remember to always disable it back for security reason)

3. SSH to the device with Putty: root / openmediavault  (Remember to change the default password)