[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MirageOS-devel] Struggling a bit with the Hello World applications

On 5 May 2014, at 21:34, André Næss <andre.naess@xxxxxxxxx> wrote:

> On Mon, May 5, 2014 at 7:26 PM, Anil Madhavapeddy <anil@xxxxxxxxxx> wrote:
>> Below is what happened:
>> On 14.04 I got this while running opam init:
>> ERROR] The compilation of base-bigarray.base failed.
>> [ERROR] The compilation of base-threads.base failed.
>> [ERROR] The compilation of base-unix.base failed.
>> ===== ERROR while installing base-bigarray.base =====
>> Internal error:
>>  Sys_error("rm -rf /home/vagrant/.opam/system/lib/base-bigarray: Cannot 
>> allocate memory")
>> ===== ERROR while installing base-threads.base =====
>> Internal error:
>>  Sys_error("rm -rf /home/vagrant/.opam/system/lib/base-threads: Cannot 
>> allocate memory")
>> ===== ERROR while installing base-unix.base =====
>> Internal error:
>>  Sys_error("rm -rf /home/vagrant/.opam/system/lib/base-unix: Cannot allocate 
>> memory")
> To ask the obvious question: how much memory does this VM have?
> I just tried reproducing this on a fresh Ubuntu 14.04 VMWare Fusion:
> Ok, I'm slightly embarrassed now. I bumped the memory on the VM to 1024. The 
> Vagrant default is pretty low. It works fine now.

Thanks for confirming it works (phew).  This does touch on the important point 
of us distributed tested Vagrant boxes.

I just signed up for the Vagrant cloud that's in beta at the moment, and will 
look into publishing an OPAM-friendly image with all the bits'n'bobs installed.

I've also got a Docker trusted build at 
https://index.docker.io/u/avsm/docker-opam/, although that's less useful since 
we have no way to get the build result out of the container.

> I think I figured this out. On 12.04 the mirage installation instruction tell 
> you to install opam because it's not in the ubuntu repo. So you are guided to 
> the quick installation at http://opam.ocaml.org/doc/Quick_Install.html. This 
> tells you to add a repo and run ppa:avsm/ppa. This is where it goes wrong. I 
> skipped this step and installed one of the opam binaries instead, and now it 
> works. At first I thought the problem was aspcud because by following the 
> instructions it's installed but by just using the opam binary it is not. To 
> test I just installed aspcud  and the mirage configure step still works fine. 
> So maybe it's something about the ocaml that gets pulled in from that repo?

Hm, not sure what the problem is here without more information.  The avsm/ppa 
is pretty widely used in hundreds of Travis tests by the wider OCaml community, 
whereas the binary OPAM releases are questionable.

> The stackv4 example fails during "mirage configure --unix" due to a missing 
> libssl. That's easy to fix I guess, but the weird thing (to me) is that after 
> failing the mirage command is gone again. It does say that it is to be 
> recompiled, so I guess it was removed and then never recompiled since ssl 
> 0.4.7 failed.

I think the easiest solution here is to provide a `mirage` binary that's 
independent of the library installation being used for the Mirage build.  We 
should be able to do this in the Vagrant image fairly easily...

> Looks like I'm finally off to the races :)



MirageOS-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.