Postgresql dev setup improvement

104 views
Skip to first unread message

benmccann

unread,
Oct 14, 2012, 3:39:42 AM10/14/12
to vcap...@cloudfoundry.org
Hi,

I can't install Cloud Foundry on Ubuntu 12.04 as easily as I'd like to be able to. The issue is that the version of libpq used is not available on Ubuntu 12.04, but was added to dev_setup/cookbooks/essentials/recipes/default.rb.  This library is used only for the installation of postgresql. Would it be possible for someone to move the install of this library to dev_setup/cookbooks/postgresql/recipes/default.rb where I believe it's better suited to reside?

Thanks,
Ben

gandalf.co...@gmail.com

unread,
Oct 14, 2012, 5:59:08 AM10/14/12
to vcap...@cloudfoundry.org
Il giorno domenica 14 ottobre 2012 09:39:42 UTC+2, benmccann ha scritto:
I can't install Cloud Foundry on Ubuntu 12.04 as easily as I'd like to be able to. The issue is that the version of libpq used is not available on Ubuntu 12.04, but was added to dev_setup/cookbooks/essentials/recipes/default.rb.  This library is used only for the installation of postgresql. Would it be possible for someone to move the install of this library to dev_setup/cookbooks/postgresql/recipes/default.rb where I believe it's better suited to reside?


I don't think that Ubuntu 12.04 is supported by dev_setup.
Every docs talks about a pristine ubuntu 10.04 installation. 

Adam C. Greenfield

unread,
Oct 14, 2012, 11:44:37 AM10/14/12
to vcap...@cloudfoundry.org
This is definitely seems to be the case. I've done some work to get a dev_setup box running on 12.04 and here is what I have so far.

Attached is a patch I made to deal with the libpq issue on 12.04 that seems to work for me and allows installation to complete. 

You will also run into an issue compiling ones of the dependencies (if I remember correctly it is erlang/otp) that requires you to use gcc 4.4 as your default system compiler (I did so using the information here: http://stackoverflow.com/questions/7832892/how-to-change-the-default-gcc-compiler-in-ubuntu)

YMMV, I haven't used a 12.04 based node in anything close to production with CloudFoundry yet. 

-Adam

ubuntu-12-04-fixes.patch

Ben McCann

unread,
Oct 14, 2012, 1:49:12 PM10/14/12
to vcap...@cloudfoundry.org
Great. Will you be submitting your patch?

Thanks,
Ben

Adam C. Greenfield

unread,
Oct 14, 2012, 2:25:33 PM10/14/12
to vcap...@cloudfoundry.org
On Sun, Oct 14, 2012 at 1:49 PM, Ben McCann <b...@benmccann.com> wrote:
Great. Will you be submitting your patch?

 
Absolutely, I'll be honest - I am having a hell of a time getting all of the BVTs to pass at the moment (either on 10.04 or on 12.04) on a dev_setup box.

I want to make sure I didn't cause an unintended issues and after I can figure out my testing problems I'll get the patch into gerrit for discussion.

-Adam

res...@gmail.com

unread,
Oct 15, 2012, 1:49:51 AM10/15/12
to vcap...@cloudfoundry.org
I have read your patch and I'm glad to say we are approaching the same thing. But could you please tell me if you have test the servece part of dev_setup, I encounted some error there?

Adam C. Greenfield

unread,
Oct 15, 2012, 8:30:45 AM10/15/12
to vcap...@cloudfoundry.org
On Mon, Oct 15, 2012 at 1:49 AM, <res...@gmail.com> wrote:
I have read your patch and I'm glad to say we are approaching the same thing. But could you please tell me if you have test the servece part of dev_setup, I encounted some error there?



If you are referring to the BVTs, I'm seeing failures all over at the moment. I haven't spent a lot of time digging through them yet but they occur on a normal 10.04 dev_setup as well.

If I recall correctly, after applying that patch and making the GCC change I mentioned, uploading a basic test application and using a service worked fine on 12.04.

-Adam

benmccann

unread,
Oct 28, 2012, 3:13:50 PM10/28/12
to vcap...@cloudfoundry.org
Hey Adam,

How's it going with your patch?  It looks like it should essentially be a no-op on 10.04 so I don't imagine you'd have much difficulty getting it committed. 

-Ben

Adam C. Greenfield

unread,
Oct 28, 2012, 9:57:49 PM10/28/12
to vcap...@cloudfoundry.org
On Sun, Oct 28, 2012 at 3:13 PM, benmccann <benjamin...@gmail.com> wrote:
Hey Adam,

How's it going with your patch?  It looks like it should essentially be a no-op on 10.04 so I don't imagine you'd have much difficulty getting it committed. 



You are probably right, I just haven't gotten time to get all the bvts passing (in either Ubuntu version 10.04 or 12.04 using a dev_setup instance) myself and I don't really want to pass the buck on that part to someone else. I don't think it is something that the jenkins testing would catch (but if someone knows I'm wrong PLEASE let me know)

In the back of my head, I wonder if dev_setup will continue to be a "supported" deployment method for much longer with so much attention shifting to bosh based deployment. If anyone inside the relavent VMware team would like share the current thinking on that - I would appreciate it.

Assuming the Hurricane doesn't cause major life problems I'll try to get the catch wrapped up in the next few days.

-Adam

Toriq Pria Dhigfora

unread,
Oct 28, 2012, 10:38:52 PM10/28/12
to vcap...@cloudfoundry.org
Dear All , I've successfully install CF on my ubuntu 12.04 VM for 64 bit. 

It can be access from paas.azure4j.us 
Sample app on yamashowcase.azure4j.us 

So I downgrade gcc to gcc4.4 , rubby to 1.8 , installing postgresql 8.4 , libpq5 , and still there another steps.

I'am writing a document about it now.



Fangzhou Ark Xu

unread,
Nov 3, 2012, 3:22:51 AM11/3/12
to vcap...@cloudfoundry.org
I've made it work under Ubuntu 12.04 (with a smaller deployment set devbox_mini.yml). 

You can find the working fork at: 


Forget the other unrelated commits, the only changes are:


BTW, I did not install erlang (I know that cookbook for erlang does not work in 12.04), but I tried to install manually with version R15B02, it works with those libs change:



ark

Adam C. Greenfield

unread,
Nov 3, 2012, 3:34:18 AM11/3/12
to vcap...@cloudfoundry.org
Changing things to use a newer version of erlang on newer deployments seems to me like a more elegant solution than the gcc version swap hack I've been using.


Reply all
Reply to author
Forward
0 new messages