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

Re: [Xen-devel] Outreachy Winter Internship



On 11/09/16 11:52, Kavya Sharma wrote:
> Hello Sir,I am Kavya Sharma, an aspiring Outreachy intern.It would be my
> privilege to be an intern with xenproject.org this winter.I have read
> about Xen Hypervisor Userspace Tools and I am interested in your project
> 'golang bindings for libxl'.
> 
> Sir,can you please guide me on this and also give some suggestions so
> that I can work on the bite-sized projects so that I can fulfil the
> requirements.

Kavya,

Thanks for your interest in the Xen Project!  We've actually found
that one of the difficult parts of getting going with our project is
making sure that you understand how to get your whole system and
environment set up.  And another thing we want to see is to what
degree you can balance figuring things out, finding the answers on the
web, and asking for help when you need it.

So with that in mind, we've started experimenting with tasks which
don't contribute very much to the project directly, but provide a
really solid base of knowledge to do further contributions.

So here's my challenge for you.

-------
OUTCOME

Attached is the very beginnings of a set of golang bindings that I
wrote for a project of my own.  They contain an implementation of
Context.Open() and Context.DomainInfo().

Write a simple go program that will take as an argument a single
domain id, and will output something that looks like the output of "xl
info [domid]".

That is, if your program was called "dominfo", then the output of
"dominfo 0" should look similar to the output of "xl info 0".

Please post a copy of your .go program, along with the results of output
both for domain 0, and another running (non-domain-0) domain.

STEPS

1. Set up a system running Linux

If you don't have one, Ubuntu, Fedora, or Debian should all be fine.

2. Download, build, and install the latest development
version of Xen.  The following page should be useful:

https://wiki.xenproject.org/wiki/Compiling_Xen_From_Source

I would recommend using "make debball" or "make rpmball" over the
"make install".

3. You'll need to build an image for at least one guest VM.

There are tons of options here, but one really simple thing would be
to follow this HOWTO from a previous OPW intern:

https://umasharma17.wordpress.com/2015/02/13/creating-guests-using-xl-in-xen/

4. Write your go program

The go program will need to Open() the context, then call DomainInfo()
on the target domain ID, and output the required info based on "xl
list".

libxl.go uses cgo to compile a library againt C.  In order for the cgo
builder to get the right libraries, you'll at least need to set the
CGO_LIBS environmetn variable to include both libyajl and libxl, like
this:

  export CGO_LIBS="-lyajl -lxenlight"

------

That's it!  Remember that the goal of this is to see how well you
balance figuring things out on your own vs asking questions.  So try
to figure things out on your own, but when you run into a bit of
difficultly, don't hesitate to ask questions or clarification --
particularly at the beginning.

You can ask questions either here on xen-devel or on the #xendevel or
#xen-opw channels on freenode IRC.  My nickname is 'gwd'.

Good luck,
 -George

Attachment: libxl.go
Description: Text Data

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
https://lists.xen.org/xen-devel

 


Rackspace

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