Hi. I have dom0 - debian Lenny, xen 3.3.1, domU - debian Lenny as PV(based on host-kernel system). Root password of domU was lost(or Hacked) and I need imidiately restore domU. Now I can just connect by console to my domU(but I can''t logging to system without password), VNC not avaible in PV. I have no control of system and don''t know what can I do. Need help really. -- Best Regards, alex.faq8@gmail.com _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On 26/10/09 12:14, alex wrote:> Hi. I have dom0 - debian Lenny, xen 3.3.1, domU - debian Lenny as > PV(based on host-kernel system). > Root password of domU was lost(or Hacked) and I need imidiately > restore domU. Now I can just connect by console to my domU(but I can''t > logging to system without password), VNC not avaible in PV. I have no > control of system and don''t know what can I do. Need help really.You can''t boot the guest in single-user mode to change the password? I think that''s what you''re saying. Anyway, it''s easy enough to get to the guest''s disk without booting it. Search the archives for "kpartx" (or look it up in the man page) -- that''ll give you a way of mounting the guest''s filessystem(s) in the host so you can edit the password file directly. I feel compelled to point out that kpartx has nothing to do with X or KDE, despite the name :-) jch _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
alex wrote:> Hi. I have dom0 - debian Lenny, xen 3.3.1, domU - debian Lenny as > PV(based on host-kernel system). > Root password of domU was lost(or Hacked) and I need imidiately restore > domU. Now I can just connect by console to my domU(but I can''t logging > to system without password), VNC not avaible in PV. I have no control of > system and don''t know what can I do. Need help really. > > -- > Best Regards, > alex.faq8@gmail.com <mailto:alex.faq8@gmail.com> > > > > ------------------------------------------------------------------------ > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-usersCan you mount the domU image with -o loop and then chroot to that mounting point? _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
I have still a script around that can do this by mounting and chrooting to the disk. Mail me in private if you want it. Stefan Op 26 okt 2009 om 13:22 heeft John Haxby <john.haxby@oracle.com> het volgende geschreven:\> On 26/10/09 12:14, alex wrote: >> Hi. I have dom0 - debian Lenny, xen 3.3.1, domU - debian Lenny as PV >> (based on host-kernel system). >> Root password of domU was lost(or Hacked) and I need imidiately >> restore domU. Now I can just connect by console to my domU(but I >> can''t logging to system without password), VNC not avaible in PV. I >> have no control of system and don''t know what can I do. Need help >> really. > > You can''t boot the guest in single-user mode to change the > password? I think that''s what you''re saying. > > Anyway, it''s easy enough to get to the guest''s disk without booting > it. Search the archives for "kpartx" (or look it up in the man > page) -- that''ll give you a way of mounting the guest''s filessystem > (s) in the host so you can edit the password file directly. > > I feel compelled to point out that kpartx has nothing to do with X > or KDE, despite the name :-) > > jch > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi Alex, maybe it works for you: add extra=" vga=normal init=/bin/sh xencons=tty" temporary to the vm config file than create the domain with console like (you have to delete if you had it added with the new option first) xm create linuxvmtocrack -c you will get into the domain but the hdd will be readonly (the os shows like it would be rw but the tools reading /etc/mtab which is readonly since the last reboot, so the tools not changed the state to ro) so you have to: mount / -o remount,rw and than you can change the password with passwd and poweroff the vm poweroff and remove the extra settings and you can start the vm with the new password set. -- Mit freundlichen Grüßen: Udo Attila Fischer Max Born Straße 2 D-75015 Bretten Tel: +49 3222 3328935 Email: udo@udo.hu _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users