Jump to content

[SOLVED] VM access to array


niden

Recommended Posts

Greetings,

 

I am having a bit of a problem and hoping for some pointers.

 

I am using the unRAID server (6) that we recently purchased as a backup storage. It also serves as a replication slave to our master database. For the latter task I have installed a docker mysql container which does what I need it to do.

 

Part of our backup policy is to get a database dump, get all the files from production using rsync or scp, get all the files from our aws s3 storage and then zip all these in a file and store it in the array.

 

I tried installing relevant pieces of code to the main unraid box but that did not work very well since there are a lot of dependencies and I really don't want to "pollute" the core OS. So the solution in my view is to create a virtual machine (centos preferred) where I can install all the necessary packages and in turn be able to create the archive and store it in the array.

 

What I am having problems with is how to access the array from a vm.

 

Thanks!

Link to comment

Greetings,

 

I am having a bit of a problem and hoping for some pointers.

 

I am using the unRAID server (6) that we recently purchased as a backup storage. It also serves as a replication slave to our master database. For the latter task I have installed a docker mysql container which does what I need it to do.

 

Part of our backup policy is to get a database dump, get all the files from production using rsync or scp, get all the files from our aws s3 storage and then zip all these in a file and store it in the array.

 

I tried installing relevant pieces of code to the main unraid box but that did not work very well since there are a lot of dependencies and I really don't want to "pollute" the core OS. So the solution in my view is to create a virtual machine (centos preferred) where I can install all the necessary packages and in turn be able to create the archive and store it in the array.

 

What I am having problems with is how to access the array from a vm.

 

Thanks!

 

Are SMB / NFS not working?

Link to comment

I have them enabled but not sure how I can mount a folder in the VM to a folder in the drive. That part is what confuses me.

 

ifconfig on the unRAID server shows

root@FERRITE:~# ifconfig
bond0: flags=5187<UP,BROADCAST,RUNNING,MASTER,MULTICAST>  mtu 1500
        inet 10.2.1.109  netmask 255.255.254.0  broadcast 10.2.1.255
        ether 0c:c4:7a:33:7c:2e  txqueuelen 0  (Ethernet)
        ....

docker0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 172.17.42.1  netmask 255.255.0.0  broadcast 0.0.0.0
        ether 56:84:7a:fe:97:99  txqueuelen 0  (Ethernet)
        ....

eth0: flags=6147<UP,BROADCAST,SLAVE,MULTICAST>  mtu 1500
        ether 0c:c4:7a:33:7c:2e  txqueuelen 1000  (Ethernet)
        ....

eth1: flags=6211<UP,BROADCAST,RUNNING,SLAVE,MULTICAST>  mtu 1500
        ether 0c:c4:7a:33:7c:2e  txqueuelen 1000  (Ethernet)
        ....

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        loop  txqueuelen 0  (Local Loopback)
        ....

vethc8ac9e9: flags=67<UP,BROADCAST,RUNNING>  mtu 1500
        ether fa:ef:c3:de:17:e5  txqueuelen 0  (Ethernet)
        ....

virbr0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.122.1  netmask 255.255.255.0  broadcast 192.168.122.255
        ether 52:54:00:9f:b5:0a  txqueuelen 0  (Ethernet)
        ....

vnet0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        ether fe:54:00:d2:c9:ef  txqueuelen 500  (Ethernet)
        ....

 

and in the actual VM I have:

eth0: Link encap:Ethernet ....
        ine addrt 192.168.122.76  Bcast 192.168.122.255 Mask:255.255.255.0
        ......

 

Link to comment

I am kinda familiar with NFS (with the help of Google of course :)).

 

Where I am getting stuck is how to access the host (unRAID) from the VM. What IP can I use to access it and mount a share from the array to the VM.

 

What confuses me is the different IP addresses. unRAID is on 10.2.x and the VM is on 192.x.

 

Probably it would be easier to set the networking on the VM to bridge, but I cannot seem to find that section using the UI and editing the VM from the VM manager.

 

So the confusion is mostly on the IP addresses/relationship between host/vm

 

I hope that makes it clearer :)

Link to comment

I am kinda familiar with NFS (with the help of Google of course :)).

 

Where I am getting stuck is how to access the host (unRAID) from the VM. What IP can I use to access it and mount a share from the array to the VM.

 

What confuses me is the different IP addresses. unRAID is on 10.2.x and the VM is on 192.x.

 

Probably it would be easier to set the networking on the VM to bridge, but I cannot seem to find that section using the UI and editing the VM from the VM manager.

 

So the confusion is mostly on the IP addresses/relationship between host/vm

 

I hope that makes it clearer :)

Definitely. I think you should be able to mount to the host IP from the VM without resorting to using an unRAID managed bridge, but if that isn't working, you can enable the unRAID managed bridge by going to the Settings tab, then Network Settings, and enable bridging. Then copy the name of this bridge from that page and go edit your VM. Click the toggle to turn on advanced mode and near the end of the page you will see where you can provide an alternate bridge name for this VM. Paste in that bridge, click update, then start the VM.  Now your VM will get an IP on the same subnet as your host.

Link to comment

Thank you so much for the pointers!

 

I managed to mount a folder from the vm to the array using the unRAID's IP address (10.x). Foolishly I did not set up the "export = true" under the share settings/nfs and that was what was causing the whole thing.

 

Thanks again!!!

Link to comment

Thank you so much for the pointers!

 

I managed to mount a folder from the vm to the array using the unRAID's IP address (10.x). Foolishly I did not set up the "export = true" under the share settings/nfs and that was what was causing the whole thing.

 

Thanks again!!!

Glad you got it working!  Let me know if you have other questions. I'm here to help in whatever way I can.

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...