Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

I was able to use --file version to copy a small file and test on the vm . But the issue is its not able to take the package file (unixbench.gzip)

this is the error i am getting

  File "/usr/local/lib/python2.7/dist-packages/novaclient/client.py", line 433, in request
    raise exceptions.from_response(resp, body, url, method)
novaclient.exceptions.OverLimit: Over limit (HTTP 413) (Request-ID: req-567955bf-dbc9-4f52-bcb5-1068f5a969b7)

and this is roughly the code i am using

movefile = "unixbench-5.1.2.tar.gz"
fp = gzip.open(movefile)
contents = fp.read() # contents now has the uncompressed bytes of foo.gz
fp.close()
u_str = contents.decode('utf-8') # u_str is now a unicode string
files = {"/testub":u_str}

server = nova.servers.create(name = vmName, image = image.id, flavor = flavor.id,  nics = nics, availability_zone  = availability_zone , userdata = user_data, key_name = key_pair.name , config_drive = True, files = files )

either i am doing passing the contents of the gzip incorrectly of this is not permissible ( to copy a big file on vm ) any pointers???