Getting Discourse installed on OVH VPS

I’ve been trying to get Discourse properly installed for the last few days. Finally caving in on figuring it out on my own (with the help of google). Started off with ServerMania. Server host kernel was 2.6x, would not install no matter what. I was told by tech support it would be impossible to load a kernel version higher than host, so moved on. I know DO is the officially supported and easy way to get it done, but figured I was up for a challenge and OVH seemed to have a better deal. I purchased their cloud 1 package. It’s been hell ever since.

OVH has a kernel that will not play nice with docker. I’ve gone through the standard guides for upgrading the kernel. I’ve installed offical OVH kernel’s that were newer, no dice. I’ve installed the generic kernel, but this always breaks BIND. The furthest I’ve got so far is getting an instance of Discourse to run, but not on the specified subdomain in the configuration file, and smtp is not working locally either. I tried to use gmail with the three different ways it can be done, port 25, 465, 573, none worked. I finally got mail working with Mandrillapp. This is not good enough. The site isn’t even for me, someone is paying me to figure this out, and I’m failing thus far. He wants to run multiple sites on subdomains of the main domain. So I’m a bit stuck at this point.

OVH said no sys admin’s will be available until Monday, and my terribly sleep deprived mind wants this over already so I can rest in peace. I’m going insane. Someone please point me in the right direction. When I look to the DO guide, there is no mention of a control panel, or actually setting up SMTP. subdomains, etc… To what extent is this done for you within the discourse/docker guide? I’ve tried to set everything in manually with a few control panels now: Plesk, Sentora, and EHCP. None of this is working, because again, after I find a solution that will get the docker working correctly to run discourse, this exact thing is what leads to BIND going down. That’s the loading of an alternative kernel.

Not asking for babystepping, but any insight and pointers would be great. I’ve reinstalled at least two dozen times and tried out at least a dozen guides over the last 2-3 days… heck I don’t even know when I started… I need to figure this out before I go grey LOL!

HELP

3 Likes

I’d recommend biting the bullet and going through the official guide using Digital Ocean first.

Get a real feel for how it works as documented there before experimenting further if you’re having this kind of trouble.

Then, start playing around with more advanced stuff, like this multi-site install guide.

There is also an advanced troubleshooting faq and an advanced setup guide.

But again, start with the basic guide first.

And regarding this:

3 Likes

Thanks for the speedy reply. To be clear, I’m all for an easy setup, and have gone through that guide numerous times, but I’m not on DO, and the issues are more than is covered in this guide. It would be nice if things went smoothly, but the problem seems to be mostly surrounding the OVH specific kernel and various services breaking after trying to alter it. I was under the impression that upgrading the kernel in their “cloud” VPS packages would be painless, guess someone sold me hot air.

I have briefly looked through the multi-site install guide some time ago. Will check the rest of your links now.

If anyone has experience with an OVH cloud install of discourse PLEASE help me out.

Thanks again for the speedy reply :smile:

Did you try it with a DO VPS? If not, I think it’s $5 well spent to just fire one up and get an install working there…

What would be the point of that? I have no doubt it would work with a DO install. That doesn’t get me where I need to be. $5, and time wasted.

what does

docker info

return?

1 Like

Try searching for OVH here too, in that case.

Looks like there are a few threads on this forum with some OVH references:

https://meta.discourse.org/t/bootstrapping-errors-on-docker-install-with-ovh/19000

fresh install

apt-get update

wget -qO- https://get.docker.io/ | sh

root@vps34714:~# docker info
Containers: 0
Images: 0
Storage Driver: devicemapper
Pool Name: docker-8:1-656152-pool
Pool Blocksize: 65.54 kB
Data file: /var/lib/docker/devicemapper/devicemapper/data
Metadata file: /var/lib/docker/devicemapper/devicemapper/metadata
Data Space Used: 305.7 MB
Data Space Total: 107.4 GB
Metadata Space Used: 729.1 kB
Metadata Space Total: 2.147 GB
Library Version: 1.02.82-git (2013-10-04)
Execution Driver: native-0.2
Kernel Version: 3.10.23-xxxx-std-ipv6-64-vps
Operating System: Ubuntu 14.04.1 LTS
CPUs: 2
Total Memory: 1.949 GiB
Name: vps34714.vps.ovh.ca
ID: GE7V:5NTX:ZXMS:2UDR:4EZZ:WHMH:HY6P:GT2F:FKCY:EQS2:QSZO:UF7K

mkdir /var/discourse
git clone https://github.com/discourse/discourse_docker.git /var/discourse
cd /var/discourse
cp samples/standalone.yml containers/app.yml

at this point:

root@vps34714:/var/discourse# docker info
Containers: 0
Images: 0
Storage Driver: devicemapper
Pool Name: docker-8:1-656152-pool
Pool Blocksize: 65.54 kB
Data file: /var/lib/docker/devicemapper/devicemapper/data
Metadata file: /var/lib/docker/devicemapper/devicemapper/metadata
Data Space Used: 305.7 MB
Data Space Total: 107.4 GB
Metadata Space Used: 729.1 kB
Metadata Space Total: 2.147 GB
Library Version: 1.02.82-git (2013-10-04)
Execution Driver: native-0.2
Kernel Version: 3.10.23-xxxx-std-ipv6-64-vps
Operating System: Ubuntu 14.04.1 LTS
CPUs: 2
Total Memory: 1.949 GiB
Name: vps34714.vps.ovh.ca
ID: GE7V:5NTX:ZXMS:2UDR:4EZZ:WHMH:HY6P:GT2F:FKCY:EQS2:QSZO:UF7K

seems the same

about to bootstrap

I’m aware that the lack of aufs may be the issue with docker not loading here. I’m willing to try and get aufs without a different kernel if possible?

and the break:

root@vps34714:/var/discourse# ./launcher bootstrap app
Unable to find image ‘samsaffron/discourse:1.0.7’ locally
Pulling repository samsaffron/discourse
time=“2014-12-21T01:17:40-05:00” level=“fatal” msg=“Get https://index.docker.io/v1/repositories/samsaffron/discourse/images: dial tcp: lookup index.docker.io: no DNS servers”
Your Docker installation is not working correctly

See: How do I debug docker installation issues

devicemapper is not supported, you need to get aufs or btrfs going.

Absolutely for this, but this seems to be not possible with the current kernel, is this incorrect?

Every attempt so far to change the kernel has resulted in a breaking of services needed for the subdomain (BIND, at a minimum is not working afterwards) to be accessible.

if you are on a kernel with no support for aufs or btrfs you are on your own private little adventure. I doubt you will get either to work on a 2.x series kernel, that is ancient.

I’ve tried this as well.

Totally uninstalled docker

check

Changed kernel to a generic kernel (away from the default OVH kernel)

check

I had to tweak DNS resolution settings (What I have now is a temporary workaround, still going to be working on this)

I have added these two lines to get DNS resolution, however this does not allow bind9 to start:

echo “nameserver 8.8.8.8” | sudo tee /etc/resolv.conf > /dev/null
echo “nameserver 8.8.8.8” | sudo tee /etc/resolvconf/resolv.conf.d/base > /dev/null

Reinstalled Docker using the wget script from the installation guide.

check

I verified that my settings were still intact in app.yml

check

Finally got bootstrap to run

check

Started App

App will start. I can visit it from the either the subdomain or the main domain. I can’t get BIND9 to load, and won’t be able to add more sites as needed. This would work if I would resign to having only discourse on the cloud VPS, and using an external mail service. I don’t think he’ll mind the mail issue, but the need for properly working sub-domains is a must.

Right, that’s why I gave up on ServerMania. The current kernel is 3.1x

It does seem I am on my own to figure this out sigh

Well if I do figure it out, will be sure to post a guide. I don’t want anyone else to go through what I’ve subjected myself to.

Thanks

3 Likes

FWIW, my solution was to separate stacks, and ditch OVH for everything BUT a simple VPS which utilizes their amazing bandwidth/traffic at a low $2.99. That’s running our radio broadcasting stations and rss feeds.

I actually run an ESXi 5.5 rig with 13 static IPs on a Xeon with 32GB at my residence. I spun up two VM instances of 14.04.1 LTS, allowed godaddy to host the nameservers, and pointed the main directory to the LAMP stack VM, and discuss subdomain to the Ruby Stack docker/discourse instance.

No issues, and it’ll only cost us $3 a month.

Might be overkill, but is clean, and simple.

I currently have multiple instances of discourse on an OVH server with no problems!

But unlike the procedure mentioned above, I install docker from ubuntu / debian (jessie) repositories. The package name is docker.io. Then you just clone the discourse docker repository and follow the steps in the guides. All should work fine!

3 Likes

Good for you. When you say, “OVH server”, I’m guessing you mean a dedicated.

Here’s what I’ve noticed. The older servers will be used for VPS classic. Discourse is out of the picture there. You need at least later versions of 3.13x to run docker, as aufs is not provided with the older kernels.

With the VPS cloud, it seems the standard kernel which they will give out is an earlier 3.10 kernel, which will not work. Some people have reported success by recompiling the kernel, but I’m seeing no confirmation that their working version properly addresses a sub-domain specifically, and therefore would work for multiple instances.

I have a kimsufi ks-3, and had no issues getting the later kernel flipped without breaking bind9. It seems the issue is with the “cloud” environment. With the VPS cloud, I did try the ubuntu repository for docker.io, but that didn’t work out. You can’t load docker without aufs. Aufs is not available on some of the earlier kernels.

My guess is that the majority, if not all, of the dedicated servers either have the later kernel already installed with their selected distributions, else can easily be upgraded. The problem seems isolated to the VPS from OVH.

2 Likes

I didn’t get it, the problem is that the kernel in the VPS Cloud is too old or too recent?

The problem is that the kernel does not support AUFS, which is needed for docker. There are specific kernels which do not support AUFS. The OVH kernel that comes with the cloud package is a 3.10x. In that instance, it is too old, and new. Some kernels both before, and after support AUFS. It seems all kernels after 3.13x support AUFS. For simplicity sake, I said that a newer kernel was needed, but this is not entirely correct.

1 Like

If you’re looking for OVH VPS, you should use runabove.com instead. They are now the flagship OVH brand and prices are similar to traditional OVH VPS. Plus they’re giving a month’s trail for free, worth a try IMO.

2 Likes

Thanks, I wasn’t aware this brand of OVH even existed. I wonder how recently it was implemented. This beats out a DO offering of similar specs in regards to pricing, and they specifically mention the ease of use with docker. I’m interested to see how a power8 chip will perform on various tasks for myself. Will go ahead and get the monthly trail for their lowest offering to check it out.

The “cloud” is a bit pricey, though. You could get a better spec setup for less. If it were my decision, and I wanted to get a discourse (or multiple) instance, plus other sites on LAMP/LEMP, and various services on the side, I’d go with the ks-3 from Kimsufi. You have two limitations here. 1IPV4/1IPV6, and a single 7200rpm hdd. Neither is truly an issue. If you’re clever you don’t need more IPs, and can set cron jobs for incremental nightly rsyncs offsite.

Still, there may be more to this “cloud” that I’m not yet registering. I’m curious about openstack as well, so will give it a spin. Thanks again!

EDIT: Actually the most efficient route would be to purchase multiple sandbox packages from runabove if you were able to spread out the resources well.