Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6614925
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T20:23:53+00:00 2026-05-25T20:23:53+00:00

I want to add a DVD drive to VM on xenserver using Python. I

  • 0

I want to add a DVD drive to VM on xenserver using Python. I created a VM using Python and now I want to add the DVD Drive attached to host to be accessible in VM also. So I need to create a VBD for the DVD Drive as well. But I am unable to get which property I need to set in VBD.Record as in attaching disk, I set up the VDI property and it got attached. But for the DVD Drive, I am unable to figure out which property I need to set to attach that CD Drive to the XenServer. Do help me regarding this…..

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T20:23:54+00:00Added an answer on May 25, 2026 at 8:23 pm

    I have written about this on my blog:

    sr=session.xenapi.SR.get_by_name_label("DVD drives")
    record_dvd=session.xenapi.SR.get_record(sr[0])
    VDI_dvd=record_dvd["VDIs"]
    vbdconnectcd={'VDI':VDI_dvd[0],
                      'VM':VM_ref,
                      'userdevice':"1",
                      'mode':"RO",
                      'type':"cd",
                      'bootable':True,
                      'unpluggable':True,
                      'empty':False,
                      'other_config':{},
                      'qos_algorithm_type':'',
                      'qos_algorithm_params':{}}
    vbdref1=session.xenapi.VBD.create(vbdconnectcd)
    

    Here, VM_ref refers to the uuid of newly created VM to which we want
    to add the DVD Drive. Every physical DVD Drive has its VDI which is
    stored in its properties and one can get it and pass it as one of the
    parameters to create a VBD linking DVD Drive with the VM.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want add new user from another script and I need create password for
I want to create an custom control (descendant of TRichEdit). I simply want add
I have created a shortcut of my .exe file. I want add to '.exe'
I build my action for create image thumbs, and I want add to the
Given Two text Boxes. (TextBox1 & TextBox2), I want add two numbers (using the
I've created new content type. And I want add new custom non-standard field. The
I'm using Sharepoint 2010 and I need to add custom notification such as send
I want edit out put of django runserver ... i want add now object
I write some simple article scripts. Now I want add some article counter. If
I have dbml with single table users i want add partial class for User

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.