Hello,
I just want to know how to initialize the IMachineDebugger object in java? As I am using Virtualbox API 4.3. I want to use dumpGuestCore method of this class. Please help me out.
Problems with IMachineDebugger
-
- Site Moderator
- Posts: 5229
- Joined: 13. Jan 2012, 11:14
- Primary OS: Debian other
- VBox Version: OSE Debian
- Guest OSses: Debian, Win 2k8, Win 7
- Contact:
Re: Problems with IMachineDebugger
Which type of bindings are you using (WebServices, XPCOM, MSCOM)?
Do you already have some code, even if it doesn't work?
Do you already have some code, even if it doesn't work?
Hyperbox - Virtual Infrastructure Manager - https://apps.kamax.lu/hyperbox/
Manage your VirtualBox infrastructure the free way!
Manage your VirtualBox infrastructure the free way!
Re: Problems with IMachineDebugger
I am using XPCOM binding. I am just stuck here on the initialization step.
this what i am trying to do so far
Code: Select all
IMachineDebugger dump = new IMachineDebugger(null);
dump.dumpGuestCore("wal", "s");
-
- Site Moderator
- Posts: 5229
- Joined: 13. Jan 2012, 11:14
- Primary OS: Debian other
- VBox Version: OSE Debian
- Guest OSses: Debian, Win 2k8, Win 7
- Contact:
Re: Problems with IMachineDebugger
Ok, I understand the issue. You cannot create the object yourself, you need to retrieve it from the API objects. Have you read the introduction section in the SKDRef.pdf file that comes with the SDK? Esepcially section 10.3 which deals with Java specifics.
The IMachineDebugger can be obtained via the IConsole object, which is accessible via a mutable IMachine object from a ISession obejct. so in pseudo-code, it would look something like this :
The IMachineDebugger can be obtained via the IConsole object, which is accessible via a mutable IMachine object from a ISession obejct. so in pseudo-code, it would look something like this :
Code: Select all
ISession sess = VirtualBoxManager.getSessionObject();
IMachine vm = IVirtualbox.getMachine();
vm.lock(sess,LockType.Shared);
IMachineDebugger dbg = sess.getMachine().getConsole().getDebugger();
// do stuff
sess.unlockVm(); // very important!
Hyperbox - Virtual Infrastructure Manager - https://apps.kamax.lu/hyperbox/
Manage your VirtualBox infrastructure the free way!
Manage your VirtualBox infrastructure the free way!
Re: Problems with IMachineDebugger
Thanks for your help and yes I had gone that chapter but I will again look through it..
Re: Problems with IMachineDebugger
I am also facing some problems in opening the the dump file which I get using this method.
Can you tell me how to open this output file to whats really in there in the file.
Code: Select all
dump.dumpGuestCore("/home/waleed/asdf","");
-
- Site Moderator
- Posts: 5229
- Joined: 13. Jan 2012, 11:14
- Primary OS: Debian other
- VBox Version: OSE Debian
- Guest OSses: Debian, Win 2k8, Win 7
- Contact:
Re: Problems with IMachineDebugger
I have no knowledge of the dump format. If you need a fast answer, I would suggest you ask on the dev IRC channel or the dev mailing list.
Else, devs tend to come read this forum from time to time.
Else, devs tend to come read this forum from time to time.
Hyperbox - Virtual Infrastructure Manager - https://apps.kamax.lu/hyperbox/
Manage your VirtualBox infrastructure the free way!
Manage your VirtualBox infrastructure the free way!