Jump to content
ironicbadger

[XEN VM IMG] ArchVM <--- deprecated 01/07/2014

688 posts in this topic Last Reply

Recommended Posts

Question about the CTRL-] switch thingy. For me that only works on the actual machine itself, not on any remote sessions. Do i need to set some terminal emulation in putty or ssh?

Or is there another way to switch to the unraid console from arch? Maybe some logout function or anything?

Share this post


Link to post

 

Got plex running in Arch on a 100gb data.img , but it was annoying!!!!!!! Ty badger and school.

 

My pleasure. Let us know how it works.

 

Plex with database to 100gb data.img is running great and works amazing!

 

Was there a guide posted on how to expand ironics arch.img or has there been another arch.img posted somewhere?

 

Trying to follow all the threads but there are quite a few at the moment

 

 

Sent from my iPhone using Tapatalk

Share this post


Link to post

There was no guide per-say just kinda of a outline to follow here is how i made it work.

 

Guide, Credit to schoolbus for most of it.

 

0. Shutdown Arch VM.

1. Telnet/SSH into unraid and goto the location of your arch.img. For example mine is /mnt/cache/.custom/VMs/ArchVMv3/.

Type:

  cd /mnt/cache/.custom/VMs/ArchVMv3/

  truncate -s 100G data.img

  mkfs.ext4 data.img

2. Change your arch.cfg to reflect the highlighted portion.

-------------------------------------------------------------------------

name = "archVM"

bootloader = "pygrub"

memory = 1024

vcpus = 1

bootloader = "pygrub"

disk = [

  'file:/mnt/cache/VMs/ArchVM/arch.img,xvda,w',

  'file:/mnt/cache/VMs/ArchVM/data.img,xvdb,w' # <--- Uncomment this if adding a "Data Drive"

  ]

vif = [ 'mac=00:16:3e:xx:xx:xx,bridge=br0' ] # <--- Replace xx with random lower case letters and numbers so your MAC Address is unique.

-------------------------------------------------------------------------

3. Load Arch xl create arch.cfg -c

4. Mount the data drive to Arch.

    type: nano /etc/fstab

    Paste /dev/xvdb              /data        ext4      defaults,noatime      0   

5. Reboot Arch and ensure that the /data point auto mounts and the size is correct via df

6. Install plex via pacman -S plexmediaserver.

7. Edit the plex config via nano /etc/conf.d/plexmediaserver

    Change to PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/data/Library/Application Support"

8. cp /opt/plexmediaserver/ /data/

9. systemctl start plexmediaserver

10. Finished.

 

Please let me know if you get errors as i typed this from memory.

 

Share this post


Link to post

 

There was no guide per-say just kinda of a outline to follow here is how i made it work.

 

Guide, Credit to schoolbus for most of it.

 

0. Shutdown Arch VM.

1. Telnet/SSH into unraid and goto the location of your arch.img. For example mine is /mnt/cache/.custom/VMs/ArchVMv3/.

Type:

  cd /mnt/cache/.custom/VMs/ArchVMv3/

  truncate -s 100G data.img

  mkfs.ext4 data.img

2. Change your arch.cfg to reflect the highlighted portion.

-------------------------------------------------------------------------

name = "archVM"

bootloader = "pygrub"

memory = 1024

vcpus = 1

bootloader = "pygrub"

disk = [

  'file:/mnt/cache/VMs/ArchVM/arch.img,xvda,w',

  'file:/mnt/cache/VMs/ArchVM/data.img,xvdb,w' # <--- Uncomment this if adding a "Data Drive"

  ]

vif = [ 'mac=00:16:3e:xx:xx:xx,bridge=br0' ] # <--- Replace xx with random lower case letters and numbers so your MAC Address is unique.

-------------------------------------------------------------------------

3. Load Arch xl create arch.cfg -c

4. Mount the data drive to Arch.

    type: nano /etc/fstab

    Paste /dev/xvdb              /data        ext4      defaults,noatime      0   

5. Reboot Arch and ensure that the /data point auto mounts and the size is correct via df

6. Install plex via pacman -S plexmediaserver.

7. Edit the plex config via nano /etc/conf.d/plexmediaserver

    Change to PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/data/Library/Application Support"

8. cp /opt/plexmediaserver/ /data/

9. systemctl start plexmediaserver

10. Finished.

 

Please let me know if you get errors as i typed this from memory.

 

Much appreciated. Not attempted v6 yet as only have 1 unraid server but have been busily playing with arch VMs on another system following ironics and sbds info.

 

I will have a separate VM for plex so will most likely keep it as a larger VM and not use a separate data.img

 

 

Sent from my iPhone using Tapatalk

Share this post


Link to post
truncate -s 100G data.img

mkfs.ext4 data.img

 

:o

 

i should have known that an hour ago.. would have saved me some time from using dd and fdisk

as i was about to install plex, using my newly created data drive, i will follow this guide and report back

 

edit: i am actually thinking that it would not be nessecarry when you mount that data drive to /opt.. yeah, lazy i know  :-X

edit2: first attempt didn't work very well

[root@ArchApplianceVM_v3 plexmediaserver]# Error: Unable to set up server: boost::filesystem::copy_file: No such file or directory: "/opt/plexmediaserver/Resources/com.plexapp.plugins.library.db", "/mnt/data/plexmediaserver/Library/Application Support/Plex Media Server/Plug-in Support/Databases/com.plexapp.plugins.library.db"

there is no "Plug-in Support" directory created

it is a permission problem that keeps popping up, it is creating files as plex and as root, but plex has no access to those root files it seems

 

Share this post


Link to post

Was there a guide posted on how to expand ironics arch.img or has there been another arch.img posted somewhere?

 

You have 4 options...

 

Option A

 

Shrink / Expand Ironics image.

 

Issues:

 

1. You can't do it in unRAID. You have to do it in a regular Linux Distro.

 

2. It's very COMPLICATED and not noob friendly.

 

Option B

 

1. Create a 25GB, 50GB, 100GB, etc. whatever image file ("data drive").

 

cd /mnt/cache/VMs/ArchVM/ # <--- Location of where you VM Appliance is stored

truncate -s 100G data.img # <--- Enter the size of the of your "data drive" for your VM Appliance

 

2. Format your "data drive" with ext4.

 

mkfs.ext4 /mnt/cache/VMs/ArchVM/data.img

 

3. Add this "data drive" to your VM Appliance cfg file.

 

Example:

name = "archVM"

bootloader = "pygrub"

memory = 1024

vcpus = 1

bootloader = "pygrub"

 

disk = [

'file:/mnt/cache/VMs/ArchVM/arch.img,xvda,w',

# 'file:/mnt/cache/VMs/ArchVM/data.img,xvdb,w' # <--- Uncomment this if adding a "Data Drive"

]

vif = [ 'mac=00:16:3e:xx:xx:xx,bridge=br0' ] # <--- Replace xx with random lower case letters and numbers so your MAC Address is unique.

 

4. Start your VM Appliance and login as root.

 

5. Create a data folder in the root.

 

mkdir /data

 

6. Change ownership and permissions

 

chown -R nobody:users /data

chmod - R 777 /data

 

7. Edit fstab and mount the "data drive" to /data

 

nano /etc/fstab

 

Example of what to add:

 

/dev/xvdb              /data        ext4      defaults,noatime      0      2

 

8. Users will configure Plex, sabnzbd, Sickbeard, Transmission, etc. to use /data in the VM for where they store Plex stuff. Plus where they download, unrar, etc. stuff before it's moved to unRAID.

 

Option C

 

Ironic post several images of various sizes (5GB,10GB, 50GB, 100GB, etc.) for his All In One VM Appliance. (or add this to page one on how to create a "data drive" in a VM)

 

Option D

 

Ironic has a Plex, XBMC, Usenet Indexer, Owncloud, etc. VM Appliance of various sizes (5GB, 10GB, 50GB, 100GB, etc.) or use Option B above. (or add this to page one on how to create a "data drive" in a VM)

 

Issues:

 

I mentioned separating things like Plex and creating a Plex VM Appliance (like you would an XBMC one) but Ironic doesn't want to create / support more than one VM Appliance and he did not think it was a good idea for running several VM Appliances either. He prefers an All In One approach.

 

Typically XenServer and ESXi people have Usenet Indexers, MakeMKV (converting, ripping, etc. Blurays / DVDs / Video Files), Plex, XBMC, etc. running in their own VM Appliance. Why do we do that?

 

1. Some Applications are more memory, CPU, network, database, etc. intensive than others. It's best you separate those if you can and have more "control" over the VM and the resources you assign to them.

 

2. With Plex, Usenet Indexers, MakeMKV, XBMC, sabnzb, sickbeard all running at once along with copying / moving files to unRAID via Samba / NFS, etc... EVERYTHING is going through ONE NIC and you have no option to split that traffic between multiple NICs. (See: Networking inside Xen)

 

3. Usenet Indexers, XBMC, Plex, owncloud, etc. can / do have their own database that you run in Mysql (Mariadb) and many of us do not want every app all in one Mysql instance but prefer separate ones. Usenet Indexer would be a great example of this. The data is HUGE and where everything is stored. It also makes backing up your MySQL database easier too.

 

4. When you update / upgrade the underlying Linux Distro or complex programs like Usenet Indexers, XBMC, Plex, etc. you could break one App, several or all of them. What is the point of being able to run multiple VMs and keep your unRAID "clean" but duplicate the orginal problem and put all your eggs (all your apps) into one VM Appliance. If it breaks, has issues, etc... You lose one, several or all the Apps that you run in an All In One.

 

Hopefully others will post VM Appliances in the near future... Some we could use are:

 

pfSense

XBMC

Usenet Indexer

Owncloud

unTangled

Tvheadend

VDR

A Hardened / Secured VM Appliance where users can have it sit outside their Firewall and add Apps they want to have access from the Web. 

Etc.

Share this post


Link to post

Have to agree that the point of the VMs (for me at least) is to not replicate the problem that exists for the addons in unRAID today. A few can be easily combined but not all.

 

Option C or including this guide in the FAQs would be the lowest maintainable method for ironics repo then users are free to add whatever apps they like

 

 

Sent from my iPhone using Tapatalk

Share this post


Link to post

Grumpy makes excellent points as per. BUT, for the record I'm not against supporting / maintaining multiple images but its a question of time / motivation I guess for doing multiple imgs. I don't want to have to host 4x VMs per appliance for example. That would get £££ quick for me, which isn't ideal!

 

I agree putting all apps into one VM is dumb. But users can just download this appliance 4 times if they want and customise it accordingly.

 

I'm working on an owncloud appliance as this is quite fiddly to setup at the moment.

 

Sent from my Nexus 5 using Tapatalk

 

Share this post


Link to post

 

Got plex running in Arch on a 100gb data.img , but it was annoying!!!!!!! Ty badger and school.

 

My pleasure. Let us know how it works.

 

Plex with database to 100gb data.img is running great and works amazing!

 

Was there a guide posted on how to expand ironics arch.img or has there been another arch.img posted somewhere?

 

Trying to follow all the threads but there are quite a few at the moment

 

 

Sent from my iPhone using Tapatalk

 

Just the YouTube videos and the bit in the first post ;)

 

Sent from my Nexus 5 using Tapatalk

 

 

Share this post


Link to post

Forget to look back for edits at times. Any chance of option c or sbds post? Easiest option for users and minimal work for you (apart from all the work you've already done!)

 

 

Sent from my iPhone using Tapatalk

Share this post


Link to post

Command is poweroff in arch

 

Works in unraid too when I didn't notice that it exited the telnet session with the VM.

Share this post


Link to post

Re ironic: "I'm working on an owncloud appliance as this is quite fiddly to setup at the moment."

 

Great, I'll wait for you then.  I did get this working under Unraid 5, but still had a few issues I couldn't resolve - eg secure access.

 

Thanks again for the great work :-)

 

 

Share this post


Link to post

What happened to one of Grumpys other recommendations, creating a blank VM and letting people install what they want.

 

To me this makes the most sense as far as being able to run multiple VMs with different apps.  Then, the time spent making 10 vms and maintaining them can instead be used to write what is needed for each app.  Obviously the part that takes the most time is creating a new vm and installing/updating/configuring it before you can install an app.  Therefore, imagine there is a blank vm ready to go, the tracks are in place, so all someone needs to do is upload and boot the vm the same way as now.  Once online, update the vm and maybe the timezone.

 

Once that is in place, we have the commands needed to get an application working.  Most are pretty basic, pacman -S plexmediaserver, systemctl start plexmediaserver.  I know, super complicated.  Even with the appliance if someone wants to do any configuring they will need help finding and edit the right files, otherwise they good to go.

 

SAB and sick on one vm, plex another, and xbmc a third.  SAB, sick and plex can be installed and running in 10 minutes, go to the web config and maybe 10 minutes each.  The actual aaplication setup from the web gui is something that will be done regardless.  xbmc can maybe be its own appliance as I suspect it is more involved.  If not, then we post the commands for it too.  I know grumpy has a guide pretty much ready as it is.

 

Personally this just makes the most sense from a KISS perspective.  I mean the time it take for me to load the appliance, boot and disable apps is a few keystroke shorter than loading a blank vm, installing and starting an app.  The only thing we would need to maintain then is the repository of applications, but otherwise people have control of what they load and don't.  This might even shrink the size of the base appliance as there are no applications installed, I did plexe yesterday and the download said it was 120MB, so that right there is a savings for a person that doesn't need plex.

 

just a thought...it was grumpy's thought, I am just supporting it.

Share this post


Link to post

Agreed. Owncloud excepted on Arch. Maybe I'm just being dumb but I couldn't get it work after a couple of hours messing on, so I've created a Debian appliance just for that one specific task.

 

It'll be uploaded soon I think.

 

What you described above is exactly what this VM appliance I have made is / does right now. I agree not maintaining several VMs would be ideal, and I don't anticipate the owncloud appliance needing much as it is even more KISS than this one is!

 

 

Share this post


Link to post

 

What you described above is exactly what this VM appliance I have made is / does right now. I agree not maintaining several VMs would be ideal, and I don't anticipate the owncloud appliance needing much as it is even more KISS than this one is!

 

Oh, I thought there was still discussion about a single vm and 10 apps...

Share this post


Link to post

As I see it, this vm image is all the average user will need.

 

I think the average user will struggle with owncloud install on arch, hence why I'm splitting that one out. However, there is nothing stopping people installing  it in arch if they so wish.

 

All I've provided here is a blank VM with the relevant xen Pv drivers and a simple installation method with access to a repo full of apps which aren't hosted in the official arch repo's that I thought would be useful for a media server.

 

If users wish to run the same vm 2 or 3 times concurrently to split the functionality out between different VMs to reduce the risk of a single point of failure, then just download this VM 2 or 3 individual times.

 

 

Sent from my iPad using Tapatalk

Share this post


Link to post

I give my devices a static IP based upon their mac address in my router. Works 100% of the time.

 

I've been looking to set a static IP inside the VM and have been unsuccessful using Arch guides online. I'm not able to set an IP by Mac ID with my router.

Share this post


Link to post

As I see it, this vm image is all the average user will need.

 

I think the average user will struggle with owncloud install on arch, hence why I'm splitting that one out. However, there is nothing stopping people installing  it in arch if they so wish.

 

All I've provided here is a blank VM with the relevant xen Pv drivers and a simple installation method with access to a repo full of apps which aren't hosted in the official arch repo's that I thought would be useful for a media server.

 

If users wish to run the same vm 2 or 3 times concurrently to split the functionality out between different VMs to reduce the risk of a single point of failure, then just download this VM 2 or 3 individual times.

 

 

Sent from my iPad using Tapatalk

 

Perfect.  seems to make the most sense.  I was reading this post and thought it was all still one as opposed to a blank slate VM with only that apps I want.

 

http://lime-technology.com/forum/index.php?topic=31687.msg290264#msg290264

Share this post


Link to post

I give my devices a static IP based upon their mac address in my router. Works 100% of the time.

 

I've been looking to set a static IP inside the VM and have been unsuccessful using Arch guides online. I'm not able to set an IP by Mac ID with my router.

 

This is from memory so forgive any mistakes.

 

Systemctl disable dhcpcd

CD /etc/netctl

Cp examples/ethernet-static Ethernet

Edit that new file if required (nano ethernet)

Netctl enable Ethernet

Reboot

 

Sent from my Nexus 5 using Tapatalk

 

 

Share this post


Link to post

Hi,

 

I have got the same issue. I would like to use a static IP.

My DHCP server (Win 2003) recognizes the MAC of my new Unraid server and the MAC of archVM with 36 digits. the first 24 are trash and only the remaing 12 are correct. I'm not able to reserve this long MAC.

I read a lot about it and all say it might have something to do with Linux some say it is because of a "duplicate" Unique ID.

 

I tried the following:

 

Systemctl disable dhcpcd

cd /etc/netctl

cp examples/ethernet-static Ethernet

Edit that new file if required (nano Ethernet)

netctl enable Ethernet

Reboot

 

Inside the new File:

 

Description='A basic static ethernet connection'

Interface=eth0

Connection=ethernet

IP=static

Address=('192.168.1.23/24' '192.168.1.87/24')

#Routes=('192.168.0.0/24 via 192.168.1.2')

Gateway='192.168.1.1'

DNS=('192.168.1.1')

 

I changed

Address=('192.168.1.200/24' '192.168.1.87/24')

tried also:

Address=('192.168.1.200')

 

But during the archVM boot I received :

[FAILED] Failed to start A basic static ethernet connection.

See 'systemctl status netctl@Ethernet.service' for details.

 

The error details in there tells me:

The interface of network profile 'Ethernet' is already up.

 

I also tried to change the VM cfg file to:

vif = [ 'ip = "192.168.1.200", mac=00:16:3e:a1:b2:c3, bridge=xenbr0' ]

 

But this doesn't help/ gets ignored.

 

Any Ideas how to get rid of the 24 wrong digits or how to get the static ip up and running?

 

 

Share this post


Link to post

Is anyone else having trouble with NFS mounts from the ArchVM to unraid?...I'm having a problem where one folder on a share (seems to be my sabtemp folder) becomes inaccessible...it shows ownership and permissions as "? ? ? ? ? ? ? ? ? ? ? ?".

 

It seems to resolve itself after some time (hours?)...but in the mean time sabnzbd returns all kinds of errors and basically either looses the dl, or is uanble to run the sickbead post-process script...leaving me to clean up...

 

It's happening on a regular basis now...daily...Not sure if this is the stale nfs file issue that's been seen in the past due to Fuse inode cleanup... I haven't tried remounting to see if it clears...

 

I tried setting up the mount as SMB, but ran into permissions issues that just seemed silly to have to work through (why use smb to mount linux to linux?)....

 

I'm just doing a basic mount with no options...so perhaps there's something I need to add to help prevent this...?

 

Any suggestions?

Share this post


Link to post

Is anyone else having trouble with NFS mounts from the ArchVM to unraid?...I'm having a problem where one folder on a share (seems to be my sabtemp folder) becomes inaccessible...it shows ownership and permissions as "? ? ? ? ? ? ? ? ? ? ? ?".

 

It seems to resolve itself after some time (hours?)...but in the mean time sabnzbd returns all kinds of errors and basically either looses the dl, or is uanble to run the sickbead post-process script...leaving me to clean up...

 

It's happening on a regular basis now...daily...Not sure if this is the stale nfs file issue that's been seen in the past due to Fuse inode cleanup... I haven't tried remounting to see if it clears...

 

I tried setting up the mount as SMB, but ran into permissions issues that just seemed silly to have to work through (why use smb to mount linux to linux?)....

 

I'm just doing a basic mount with no options...so perhaps there's something I need to add to help prevent this...?

 

Any suggestions?

 

I'm having the same kind of issues. Basically, I have to cd to that directory to make it work again.

 

And transmission seems to lose track of my download folder. Same solution : a cd to that directory makes the voodoo work again.

 

I also have my unRAID shares mounted over samba, but I really don't want to use that...

 

Envoyé de mon Nexus 5 en utilisant Tapatalk

 

 

Share this post


Link to post
Guest
This topic is now closed to further replies.