TurnKey Linux Virtual Appliance Library

Need some suggestions for deployment.

I've been using TKL in a VM now for a little while and really like the fact that it is easy to setup and use. Linux is still very new to me. I've recently been assigned to setup a webserver for my company. The server will be used for many installations of Wordpress, some static sites, and maybe a few other things (shared hosting). I was thinking of using the TKL LAMP stack as a bare metal install on an older server we have sitting around. It's an HP dual processor, a gig of RAM (will be expanding this), and 2 146Gb SCSI drives. Any suggestions on how to configure this or TKL even the right way to go? Thanks!
Jeremy's picture

Sorry for slow reply...

I have been meaning to get back to this post for ages, but keep getting sidetracked... Sorry about that.

Personally I bang on about ProxmoxVE all the time and I still think that if your hardware is up to it, that is the go. Especially now that the TKL appliances are provided in OVZ format (and can even be integrated into the PVE interface).

Existing appliances should be able to be migrated to OVZ containers with TKLBAM.

The beauty of using OVZ is that you get the redundancy, scalability and potential for mobility (ie you can move it) of having all your appliances running independantly without the resource overheads that you would expect. And they still all run on the one physical machine!

I would definately invest in more RAM (I'd probably look at min 4GB perosnally) though the more the better IMO! :)

Thanks for the suggestions.

Thanks for the suggestions.  I ended up installing as is and not in any virtual environment.  I was affraid I might not have resources since it's a little older server.  It's working out pretty well so far.  I'm looking at backup solutions now.

Jeremy's picture

No worries

TBH if you used Proxmox and TKL OVZ images it wouldn't use much more resources than your current setup. I think you'd be surprised. OVZ containers actually share the resources of the host so they use less resources than the same setup would running on bare metal (or on another virtualisation platform) because they piggyback off the host processes (that's why only Linux hosts and guests are supported under OVZ).

I have over a dozen OVZ TKL VMs on an old desktop (2.3GHz Core2Duo) which I boosted the RAM up on (to 8GB). I definately notice it when I have multiple Win machines running (they run under KVM) but it comfortably runs the TKL servers all at the same time, one of them running quite a busy minecraft server of my son's.

Anyway, if you have it all going and working as you want, then it's probably not worth mucking around with it now.

And for backups, I highly recommend TKLBAM. Have a read about it in the docs.

I've been looking at some of

I've been looking at some of the documentation for it.  It looks great and even better it looks cheap and fairly easy.  

One question I have though.  I'm using the LAMP stack with my own installation of Wordpress (and eventually there will be several Wordpress installations on this machine).  Does it automatically backup the entire instance of the server, databases and all non Turnkey appliances?  

icinga/icinga-web/nagvis

It would be nice to see a Turnkey Linux system with Icinga, Icinga-web, and Nagvis already installed and ready to go as a basic server for network monitoring.  Could be set up with private IP addresses initially (i.e., 192.168.x.x)

Chris Musty's picture

Why not use the word press image

Its available in the repository, wordpress is a doddle to update and it backs up nicely. Is there a specific reason why you had to install wordpress your self?

As for servers, Proxmox will deffinately be worth the effort if you upgrade RAM. Once done it is so easy to update and remove instances. If you are only using wordpress for light work you should be able to run many instances on that server. You can backup using TKLBAM in PVE, its so easy!

Chris Musty

Director

Specialised Technologies

Well, I was doing some

Well, I was doing some testing with the Wordpress appliance in my test VM and kept running into issues with multisite installed.  I never really could figure out what the issue was and it may have not really had much if anything to do with the appliance at all.  However, I did know that it worked if I manually installed on the LAMP TKL.  I was under some deadlines so that's the way I went instead of trying to resolve the other.  I'm installing several instances of wordpress on the server anyway so it wasn't a big deal.  Thanks for the reply!

Ok, so I got approval for a

Ok, so I got approval for a new server at work.  I'm really considering your advice now Jeremy.  Some more questions though.  

Is it very common to run shared hosting on a VPS?  I mean, that's essitally what I'll be doing.  mainly because I think it will be easy to maintain and backup.  This is all for a web design service at work.

Also, I haven't looked at Proxmox much yet, but is it essentially just a linux distro with VM built in?  You install it and configure your VMs from the browser?  If so that is awesome and blows my mind that it's open source.

Jeremy's picture

Cool!

I think having the servers separate (ie as separate VMs) would be a sensible way of doing it if you can swing it. Especially if it is for design work. Devs could play to their hearts content and pretty much do whatever they want in the knowledge that it won't have any impact on anyone else's work. And worst case scenario, you could destroy the insance and start again fresh very quickly and easily. You could even give them full root control of their own servers if you wanted. You could also really easily migrate individual instances to the cloud (or to any other place you can install TKL) once your done (using TKLBAM) if you so desired.

And yes, PVE is Debian with a custom kernel (built by them) that runs 2 different virtualisation technologies; KVM which can run anything (inc Win) and OVZ (Linux only) all with a WebUI. Some advanced functions require commandline usage but for general use you can easily get by with just the WebUI. And yes it is an incredible piece of kit that is free and very powerful!

They have a large and very active community as well, with very responsive devs who provide pretty good support (for free too - judging by how helpful they are for free, I imagine that their paid support would be incredible).

They are full steam ahead on v2.0 ATM but it's still in beta and the WebUI is incomplete (many functions only work via commandline). So if you want to give it a try I suggest stick with the stable v1.9 for now. If you just want to have a play with it and get a feel for it, you can download the ISO and install it to VirtualBox.

As an extra PVE bonus, TKL now has official OVZ templates and an easy hack to PVE so they can be downloaded and installed directly from within the PVE WebUI. Have a look at the blog post here.

Chris Musty's picture

Couple of Distinctions

Shared hosting is not Virtual hosting.

Shared hosting (at least in the web hosting sphere) refers to a pool of clients all competeing for the resources allocated to them - usually a bare metal server install but quite often a Virtual Server.

It is not uncommon for a shared host to have 500 clinets on one server! So if everyone wants to upload files or there is a burst of demand, others suffer. So basically its used for low volume webpages.

A virtual server is one in which resources are guaranteed (there are many differences between virtualization technologies but lets not complicate the issue). Also virtualisation isolates the instance (as Jed has discussed above), makes backing up easy and migration a snap.

A simple example of sharing is ISP Config or cPanel. They allow you to setup shared hosting on a bare metal install or a VPS install. Weather its the entire server or a virtual server, every client will compete.

If your server has gobs of ram and multicore processing you will benefit from snappy Virtual servers, especially if using PVE - its just up to you to allocate the resources.

Chris Musty

Director

Specialised Technologies

Thanks Jeremy for the info.

Thanks Jeremy for the info.  I'm the wearing the designer/developer hats as well, something I'm more comfortable with vs. configuring servers.  I've got to cut my teeth at some point though I guess. 

Chris, maybe mispoke a little.  I understand the difference.  I think the thing that doesn't make much sense to me is running a VM for every instance of Wordpress or worse yet, to just serve up a bunch of static page websites.  It seems like I would be better off running a VM that is basically a dedicated shared hosting environment because for every VM it's another OS taking up overhead on the physical machine.  Correct me if I'm wrong as I have no real experience with this from the server admin side of things.

Chris Musty's picture

Power and Security

Even though a simple wordpress install with minimal use seems like overkill you are trading isolation for performance. If you use LAMP baremetal and install wordpress on it several times in individual folders, each user can interfere with the others and worse still they can all be taken offline together.

With PVE you can use minimal resources for each instance of wordpress eg 1 cpu core, 512Mb RAM 10Gb HDD. Modern servers have at least 4 cores, can have over 32Gb RAM and multiple LAN ports so resources are not an issue. 

Virtual platforms can be as good as 2% overhead only but the most compelling argument for using a virtual platform like PVE is that you could run many different appliances like file servers, management systems etc etc. 

Personally I am running a file server a databadse server and a PBX all in one box witha  ton of room for other appliances if I need them.

Stay away from baremetal installs unless you have old hardware, is my opinion. Dont be scared of PVE it is a snap to learn how to use it.

Chris Musty

Director

Specialised Technologies

Jeremy's picture

+1 for what Chris says :)

From my own experience I have found that a TKL LAMP instance serviing simple static content with minimal connections, will run happily under OVZ with a single core and only 256MB of RAM. After a reboot with no connections/load it idles at 0% CPU and 70-80MB RAM usage (although admitedly that was a TKL legacy LAMP, v11.x may use a little more). I suspect that you would struggle to get it to install to a system with only 256MB RAM!

The only OVZ container (ie VM) that I have that ever seems to struggle with a single core allocated is my son's Minecraft server (which cops a hammering from he and all his friends & Minecraft runs on Java) . And more often than not, it's only noticable on his end when I have the PVE server loaded up doing other intensive stuff (esp running multiple instances of Windows or installing systems to KVM VMs). And this is on my 5yo desktop hardware!

A new server would outpreform my system by a huge margin! The amount of headroom you'd have with a quad-core and 16GB of RAM would be phenominal, and these days that's not a super grunty server! Seriously, if you got yourself some decent hardware you could consolodate some of your existing physical machines. I guess if you ever got to a point where you were running out of headroom then you could look at consolidation, but no need to initially IMO. As I suggest by my ramblings, even your old server (running PVE with a RAM upgrade) is probably adequite for your current needs (having ~10+ separate OVZ containers).

The other thing that you don't seem to be factoring into you thinking is the additional Admin maintenance TCO of an all-in-one hardware type setup, as well as the points listed above by Chris. Beyond that, I'm a big beleiver in KISS (keep it simple, stupd!) And the maintenance on the setup we are suggesting, is simple!

Like I say, why not give it a go in VIrtualBox, it's all free and you've got nothing to lose (escept maybe a bit of time). I'm sure you'll find it's worth the effort! :)

Aweseome advice guys!

Aweseome advice guys!  I really appreciate it.  I'm testing ProxMox in VirtualBox now.  Very cool stuff.  

I have a couple other questions if you guys don't mind, a little unrelated.  I plan on setting up shared hosting on one of the VMs.  Probably host a handful of Wordpress sites there.  I've never setup shared hosting before and was wondering if you guys had any suggestions.  I know there are a few ways you can go about it.  I was thinking of just adding FTP users and setting the proper home directories.  I also know there are ways to do it with suEXEC.  

Like I said, not really on topic but you guys have been so helpful I thought I might ask.  Thanks!

Jeremy's picture

I don't know much about it

But if you want to make sure the users can't interfere with each other's stuff you'll need to create a chroot jail for each one. It can certainly be done, even with SSH (although I've heard that there are some idiosyncracies). It may be just easier to set up a separate FTP server and go about it that way.

I still think that unless you particularly want to learn how to do all that stuff then I'd just give each user their own OVZ appliance.

Chris Musty's picture

Use ISPConfig

Its a free "shared" hosting framework.

I also believe that there is a patch available for it...

Chris Musty

Director

Specialised Technologies

Thanks again.

I've been looking into ISPConfig and it looks nice.  I've also found ZPanel.  I'm going to do some testing in Virtual box before I commit to anything.

Chris Musty's picture

Curious?

How did PVE work in Virtual Box?

I have not relaibly tested nexted virtualisation platforms and I am guessing its not a great idea.

I think some VE's even test to see if they are baremetal before allowing install?

Chris Musty

Director

Specialised Technologies

Jeremy's picture

It probably doesn't work great

But it does work. I have done it myself, and it seems to work ok.

AFAIK it's what Alon used for development and testing of his OVZ patches/PVE integration. Also I have PVE v2.0beta installed (under KVM) on one of my PVE v1.9 hosts and although it's a bit laggy (mostly cause I didn't allocate a lot of resources) it installs and runs ok.

Chris Musty's picture

ZPanel looks good

Thanks for the link, never knew it existed!

Anyone made a patch for it?

Chris Musty

Director

Specialised Technologies

Jeremy's picture

Good thinking guys...

Sorry I was still thinking devlopment, not hosting... Doh!

Yeah ZPanel does look pretty nice. And no AFAIK there isn't a patch for ISPconfig (or ZPanel either). I was thinking about having a crack at an ISPconfig patch but have been busy doing other stuff...

Haven't tested too much.

Chris, I mainly just set up PVE in VirtualBox and connected to the OZC templates and deployed one just to see how it all worked.  I can't really comment about how "great" it was from the view of PVE in VirtualBox but it worked as far as I could tell.  

Couple of other control panels I ran across in my research.  OpenPanel and EHCP.  I tried EHCP but ran into some issues.  ISPConfig looks to be one of the more feature rich open source control panels at the moment.  Plus it isn't as hard on the eyes out of the box as some others.

I know shared hosting on Turnkey may not be a very desired thing considering it sort of goes against the point.  There may be a few people interested though.

Chris Musty's picture

shared hosting has its place

if it weren't for shared hosting you would not get your hosting for $2.95 per month. but on the otherhand it can be bad for several reasons, especially if you have higher traffic volumes than average. one account can directly affect all accounts. i have been through many hosts nbut none were able to offer what i need so the conclusion is, you pay for what you get.

i know people on shared hosts for years and years and are very happy. its all about the end user and what they want.

turnkey is definately a desired solution for a shared server setup. thanks fir the other links.

Chris Musty

Director

Specialised Technologies

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account, used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <map> <area> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <address> <code> <cite> <strike> <caption>

More information about formatting options

Leave this field empty. It's part of a security mechanism.
(Dear spammers: moderators are notified of all new posts. Spam is deleted immediately)