Are you sure that this is a frozen machine, rather than one that
simply doesn't have a getty on the console?
iustin
What's the console type in your domU?
Have a look at the /etc/inittab file and make sure, you have "hvc0" in
your first getty console (and *not* tty1)
To change that, just shutdown the instance and activate it's disk, mount
it and change the inittab file.
hth
cheers,
thomas
On 27.08.2010 14:06, RaSca wrote:
> On 27 Ago, 12:53, Iustin Pop <ius...@google.com> wrote:
> [...]
>> Are you sure that this is a frozen machine, rather than one that
>> simply doesn't have a getty on the console?
>> iustin
>
> Hi,
> I've created the vm with this command:
>
> gnt-instance add -t drbd -n debian-lenny-nodo1.cutaway.local:debian-
> lenny-nodo2.cutaway.local --disk=0:size=500m --net=0 -o debootstrap
> +default vm1.cutaway.local
>
> So is a bootstrap installation, anything else. These are the infos
> about the instance:
[...]
The disks are partitioned, you need to activate the partition via
kpartx first. Please read the documentation at
http://ganeti-doc.googlecode.com/svn/ganeti-2.1/html/admin.html#accessing-an-instance-s-disks
> Note that ganeti is configured to work with lvm,
> but is impossible to mount also the logical volume:
>
> # mount /dev/xenvg/97181d91-638e-4e1c-be7b-717a8594f61f.disk0_data /
Never *ever* do this, since you will introduce corruption in the secondary node.
regards,
iustin
On 27.08.2010 15:17, RaSca wrote:
> On 27 Ago, 14:59, Thomas Rieschl <tho...@rieschl.com> wrote:
>> hi!
>> What's the console type in your domU?
>> Have a look at the /etc/inittab file and make sure, you have "hvc0" in
>> your first getty console (and *not* tty1)
>> To change that, just shutdown the instance and activate it's disk, mount
>> it and change the inittab file.
>> hth
>> cheers,
>> thomas
>
> Hi Thomas,
> I've activated the disks in this way:
>
> # gnt-instance activate-disks vm1.cutaway.local
> debian-lenny-nodo1.cutaway.local:disk/0:/dev/drbd0
>
> But I can't mount drbd device:
>
> # mount /dev/drbd0 /mnt/
> mount: you must specify the filesystem type
>
> or
>
> # mount -t ext3 /dev/drbd0 /mnt/
> mount: wrong fs type, bad option, bad superblock on /dev/drbd0,
> missing codepage or helper program, or other error
> In some cases useful info is found in syslog - try
> dmesg | tail or so
hm, that's weird. did you shutdown the instance before activating the disks?
looks like the device is used. also, you have to mount the disk on
debian-lenny-nodo1.cutaway.local (the disk is activated on the primary
node of the instance)
try to deactivate the disks, make sure the instance shut down and then
activate the disks again.
what does "tune2fs -l /dev/drbd0" say?
if nothing works, that could be a disk problem. you could try to remove
the instance and recreate it again if it's just an instance for testing.
>
> What am I missing? Note that ganeti is configured to work with lvm,
> but is impossible to mount also the logical volume:
>
> # mount /dev/xenvg/97181d91-638e-4e1c-be7b-717a8594f61f.disk0_data /
> mnt/
> mount: /dev/mapper/xenvg-97181d91--638e--4e1c--
> be7b--717a8594f61f.disk0_data already mounted or /mnt/ busy
be careful with that. you're not supposed to do that, you could destroy
the disks. if you have to mount the disk that way mount it read-only
(mount -o ro ...)
cheers,
thomas
On 27.08.2010 15:26, Iustin Pop wrote:
> On Fri, Aug 27, 2010 at 15:17, RaSca <rasc...@gmail.com> wrote:
[...]
>>
>> What am I missing?
>
> The disks are partitioned, you need to activate the partition via
> kpartx first. Please read the documentation at
> http://ganeti-doc.googlecode.com/svn/ganeti-2.1/html/admin.html#accessing-an-instance-s-disks
[...]
oh, sorry,
did not know about that.
new behavior in ganeti 2?
ganeti 1.2.9 just used whole-disk filesystems, right?
cheers,
thomas
Not even read-only mounts are safe, since on journalled filesystems it
*might* trigger some journal replay.
To stay safe, just don't do it, or do it on a snapshot of the LV if
you just want to read data off it.
cheers,
iustin
Yes, just edit /etc/default/ganeti-instance-debootstrap (if I remember
the path correctly).
regards,
iustin
It's actually a new behaviour in recent versions of
ganeti-instance-debootstrap. Ganeti per se doesn't care, except for
passing the root device to the instance (for Xen PVM).
(It might also be that it only works on Ganeti 2)
So it depends on what you configure the OS scripts with…
regards,
iustin
Probably means that you have a filesystem directly inside the virtual
disk, without having partitions inside. What you did to fstab probably
didn't help, but also doesn't prevent starting the machine, as the
kernel anyway has a working root filesystem. What you did inside
ganeti was the actual solution, pointing the kernel to the actual
device holding your root filesystem. Had you had a partition table
inside the virtual disk, xvda1 would have been correct. All boils down
to what your instance script does at create time.
Regards,
Guido