吉山@新幹線です。
お問い合わせの件、下記情報を提供願います。
* /etc/nova/nova.conf の中身
* file /var/lib/nova/instances/instance-0000000d/disk の結果
* /var/lib/nova/instances/instance-0000000d/libvirt.xml の中身
* VM インスタンスのコンさソール出力全て
* df -h の出力
2011/05/19 18:39 "tacky1052" <takiguchi...@gmail.com>:
qemuだと同じ症状がでました。
KVMだと問題なく起動できたので放置しています(ry
以上参考になれば幸いです
2011-05-19 (木) の 02:39 -0700 に tacky1052 さんは書きました:
吉山です。
戴いた情報を確認しました。
Nova の設定が KVM ではなく QEMU になっていま&#> 吉山さん
吉山です。
メッセージの送信がうまくいかなかったようです。失礼しました。
瀧口さん:
一度
--libvirt_type=kvm
で試して頂けますでしょうか?
吉山です。こんにちは。
コンソール出力を見る限り、仮想HDDが /dev/vda, vdb ではなく
/dev/sda, sdb として認識されているのではないかと思われます。
~nova/virt/libvirt.xml.template の 36 行目にある以下の箇所を変更
してみて下さい。
変更前:root=/dev/vda
変更後:root=/dev/sda
色々情報を見直してみました。
ルートファイルシステムがマウントされていないのが原因かと思いましたが、違っていました
(mountall はルートファイルシステムマウント後の処理)。失礼しました。
色々調べていて、下記のバグレポートに類似している事に気付きました。
https://answers.launchpad.net/nova/+question/145316
関連するかどうか不明ですが、ネットワーク設定を FlatDHCPManager に変えてみて
ください。
変更前: --network_manager=nova.network.manager.FlatManager
変更後: --network_manager=nova.network.manager.FlatDHCPManager
--
吉山あきら <akirayo...@gmail.com>
2011年5月20日18:52 tacky1052 <takiguchi...@gmail.com>:
FlatManagerの時にMetaDataを取得できないのは、FlatDHCP/Vlanなどでは設定される項目が
設定されないからです。
ざっとパッチを作ってみましたので添付します。
問題なさそうでしたら本家にコミットしようかと思っています。
#bzrの使い方がわからん(笑
On Sat, 21 May 2011 00:47:01 +0900
Akira Yoshiyama <akirayo...@gmail.com> wrote:
> 吉山です。こんばんは。
>
> 色々情報を見直してみました。
> ルートファイルシステムがマウントされていないのが原因かと思いましたが、違っていました
> (mountall はルートファイルシステムマウント後の処理)。失礼しました。
> 色々調べていて、下記のバグレポートに類似している事に気付きました。
>
> https://answers.launchpad.net/nova/+question/145316
>
Hisashi Ikari <igoi...@gmail.com>
patch
-----------------------------------------------------------------------------------
Index: network/manager.py
===================================================================
--- network/manager.py (revision 8)
+++ network/manager.py (working copy)
@@ -121,17 +121,24 @@
super(NetworkManager, self).__init__(service_name='network',
*args, **kwargs)
- def init_host(self):
+ def init_host(self,add_snat=True):
"""Do any initialization that needs to be run if this is a
standalone service.
"""
- self.driver.init_host()
+ self.driver.init_host(add_snat)
self.driver.ensure_metadata_ip()
# Set up networking for the projects for which we're already
# the designated network host.
ctxt = context.get_admin_context()
for network in self.db.host_get_networks(ctxt, self.host):
self._on_set_network_host(ctxt, network['id'])
+
+ if not isinstance(self,FlatManager):
+ self.init_floating_ip(ctxt)
+
+
+
+ def init_floating_ip(self,ctxt):
floating_ips = self.db.floating_ip_get_all_by_host(ctxt,
self.host)
for floating_ip in floating_ips:
@@ -143,6 +150,8 @@
self.driver.ensure_floating_forward(floating_ip['address'],
fixed_address)
+
+
def periodic_tasks(self, context=None):
"""Tasks to be run at a periodic interval."""
super(NetworkManager, self).periodic_tasks(context)
@@ -389,15 +398,14 @@
"""
timeout_fixed_ips = False
- def init_host(self):
+ def init_host(self,add_snat=False):
"""Do any initialization that needs to be run if this is a
standalone service.
"""
#Fix for bug 723298 - do not call init_host on superclass
#Following code has been copied for NetworkManager.init_host
- ctxt = context.get_admin_context()
- for network in self.db.host_get_networks(ctxt, self.host):
- self._on_set_network_host(ctxt, network['id'])
+ super(FlatManager, self).init_host(False)
+ self.driver.metadata_forward()
def setup_compute_network(self, context, instance_id):
"""Network is created manually."""
@@ -435,11 +443,11 @@
like FlatDHCPManager.
"""
- def init_host(self):
+ def init_host(self,add_snat=True):
"""Do any initialization that needs to be run if this is a
standalone service.
"""
- super(FlatDHCPManager, self).init_host()
+ super(FlatDHCPManager, self).init_host(add_snat)
self.driver.metadata_forward()
def setup_compute_network(self, context, instance_id):
@@ -492,11 +500,11 @@
instances in its subnet.
"""
- def init_host(self):
+ def init_host(self,add_snat=True):
"""Do any initialization that needs to be run if this is a
standalone service.
"""
- super(VlanManager, self).init_host()
+ super(VlanManager, self).init_host(add_snat)
self.driver.metadata_forward()
def allocate_fixed_ip(self, context, instance_id, *args, **kwargs):
Index: network/linux_net.py
===================================================================
--- network/linux_net.py (revision 8)
+++ network/linux_net.py (working copy)
@@ -358,11 +358,12 @@
iptables_manager.apply()
-def init_host():
+def init_host(add_snat=True):
"""Basic networking setup goes here"""
# NOTE(devcamcar): Cloud public SNAT entries and the default
# SNAT rule for outbound traffic.
- iptables_manager.ipv4['nat'].add_rule("snat",
+ if add_snat:
+ iptables_manager.ipv4['nat'].add_rule("snat",
"-s %s -j SNAT --to-source %s" % \
(FLAGS.fixed_range,
FLAGS.routing_source_ip))
Cactusでやっています。
メタデータ取得のためのiptablesルールの追加処理のためのパッチです。
すいませんブリッジインターフェースにIPAddressを割り当てる処理が抜けていました。
検証機が死んでしまったので、その処理を入れたパッチをもう一度投げます。
状況的にはメタデータ取得に失敗しているわけではないと思います。
僕の環境ではFlatDHCPでもでていた症状です。
FlatManagerの場合、メタデータ取得のために手動で設定しないといけない項目として
1 nova-networkのブリッジインターフェースにネットワークアドレスの一番目のアドレス
2 iptablesの設定
3 ip_forwardの設定
が必要です。ドキュメントには丁寧には書いていませんし、ドキュメントに書いてある
iptablesの設定ですと、一つのネットワークにしか対応できないです。
VlanManager/FlatDHCPManagerはこのあたりを自動で設定してくれるのですが、
FlatManagerの場合、floating_ipのバグ関係でごっそり処理が抜けています。
急いで環境を作り直しますので、上記をマージしたパッチをもう一度投げます。
--
Hisashi Ikari <igoi...@gmail.com>
> 状況的にはメタデータ取得に失敗しているわけではないと思います。
私の環境(qemu, VlanManager)でも、該当イメージだと同じようにブートできま
せんでした。
メタデータ取得はnova-apiのログにアクセスに来たことが出ていたので、メタ
データ取得の問題ではないと思います。
それっぽいバグレポートを探しましたが、以下が該当するのでしょうか。
https://bugs.launchpad.net/ubuntu/+source/mountall/+bug/717153
伊藤さんのいうように、ほかのイメージで試されてはいかがでしょうか。
伊藤さんご紹介のttyイメージはqemuでも問題なくブートできています。
あとは、このあたりを参考に自前でつくる、という方法もあります...。
http://open.eucalyptus.com/participate/wiki/using-ubuntu-vm-builder-generate-eucalyptus-images
#このあたりのイメージの作り方はEucalyptusに詳しい方の方がご存じかも。
アドバイスいただきありがとうございます。
碇さんから
> FlatManagerの場合、メタデータ取得のために手動で設定しないといけない項目として
> 1 nova-networkのブリッジインターフェースにネットワークアドレスの一番目のアドレス
> 2 iptablesの設定
> 3 ip_forwardの設定
というお話を伺ったんですが、
私は、2は実施したんですが、 1, 3については特にしていません。
にもかかわらず、
euca-get-console-outputのログからも
メタデータは取得できているように見えます。
ubuntu1010-UEC-localuser-imageが悪いのかと思い
イメージを伊藤さんに教えていただいた
http://images.ansolabs.com/tty.tgz
に変更したら、 コンソールログがこんな(下記)感じになりました。
やはりメタデータはwgetできていないようです。
本当はメタデータ取得のための準備が整っていないのに、
ubuntu1010-UEC-localuser-imageが勘違いしていた
ということでしょうか。。。
わたしの今回の環境ではVLAN(下側でタグVLAN使っているので。)は使えないのでFlatDHCPも試してみようと思います。
みなさんありがとうございます。
root@ubuntu:~# euca-get-console-output i-00000007
i-00000007
2011-05-24T17:57:46Z
[ 0.000000] Initializing cgroup subsys cpuset
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Linux version 2.6.35-22-virtual (buildd@yellow) (gcc
version 4.4.5 (Ubuntu/Linaro 4.4.4-14ubuntu5) ) #35-Ubuntu SMP Sat Oct
16 23:19:29 UTC 2010 (Ubuntu 2.6.35-22.35-virtual 2.6.35.4)
[ 0.000000] RAMDISK: 1fa53000 - 1fff0000
[ 0.000000] Subtract (41 early reservations)
[ 0.000000] #1 [0001000000 - 0001d1a954] TEXT DATA BSS
[ 0.000000] #2 [001fa53000 - 001fff0000] RAMDISK
[ 0.000000] #3 [0001d1b000 - 0001d1b071] BRK
[ 0.000000] #4 [000009f000 - 00000f8990] BIOS reserved
[ 0.000000] #5 [00000f8990 - 00000f89a0] MP-table mpf
[ 0.000000] #6 [00000f8a90 - 0000100000] BIOS reserved
[ 0.000000] #7 [00000f89a0 - 00000f8a90] MP-table mpc
[ 0.000000] #8 [0000010000 - 0000012000] TRAMPOLINE
[ 0.000000] #9 [0000012000 - 0000016000] ACPI WAKEUP
[ 0.000000] #10 [0000016000 - 0000017000] PGTABLE
[ 0.000000] #11 [0001d1b080 - 0001d20080] NODE_DATA
[ 0.000000] #12 [0001d20080 - 0001d21080] BOOTMEM
[ 0.000000] #13 [0000017000 - 0000017060] BOOTMEM
[ 0.000000] #14 [0002522000 - 0002523000] BOOTMEM
[ 0.000000] #15 [0002523000 - 0002524000] BOOTMEM
[ 0.000000] #16 [0002600000 - 0002e00000] MEMMAP 0
[ 0.000000] #17 [0001d21080 - 0001d39080] BOOTMEM
[ 0.000000] #18 [0001d39080 - 0001d51080] BOOTMEM
[ 0.000000] #19 [0001d52000 - 0001d53000] BOOTMEM
[ 0.000000] #20 [0001d1a980 - 0001d1a9c1] BOOTMEM
[ 0.000000] #21 [0001d1aa00 - 0001d1aa43] BOOTMEM
[ 0.000000] #22 [0001d1aa80 - 0001d1ac08] BOOTMEM
[ 0.000000] #23 [0001d1ac40 - 0001d1aca8] BOOTMEM
[ 0.000000] #24 [0001d1acc0 - 0001d1ad28] BOOTMEM
[ 0.000000] #25 [0001d1ad40 - 0001d1ada8] BOOTMEM
[ 0.000000] #26 [0001d1adc0 - 0001d1ae28] BOOTMEM
[ 0.000000] #27 [0001d1ae40 - 0001d1aea8] BOOTMEM
[ 0.000000] #28 [0001d1aec0 - 0001d1af28] BOOTMEM
[ 0.000000] #29 [0001d1af40 - 0001d1af60] BOOTMEM
[ 0.000000] #30 [0001d1af80 - 0001d1af9c] BOOTMEM
[ 0.000000] #31 [0001d1afc0 - 0001d1afdc] BOOTMEM
[ 0.000000] #32 [0001e00000 - 0001e1e000] BOOTMEM
[ 0.000000] #33 [0001d51080 - 0001d51088] BOOTMEM
[ 0.000000] #34 [0001d510c0 - 0001d510c8] BOOTMEM
[ 0.000000] #35 [0001d51100 - 0001d51104] BOOTMEM
[ 0.000000] #36 [0001d51140 - 0001d51148] BOOTMEM
[ 0.000000] #37 [0001d51180 - 0001d512d0] BOOTMEM
[ 0.000000] #38 [0001d51300 - 0001d51380] BOOTMEM
[ 0.000000] #39 [0001d51380 - 0001d51400] BOOTMEM
[ 0.000000] #40 [0001d53000 - 0001d57000] BOOTMEM
[ 0.000000] Memory: 496056k/524268k available (5816k kernel code,
452k absent, 27760k reserved, 5366k data, 828k init)
[ 0.000000] SLUB: Genslabs=14, HWalign=64, Order=0-3, MinObjects=0,
CPUs=1, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] RCU dyntick-idle grace-period acceleration is enabled.
[ 0.000000] RCU-based detection of stalled CPUs is disabled.
[ 0.000000] Verbose stalled-CPUs detection is disabled.
[ 0.000000] NR_IRQS:4352 nr_irqs:256
[ 0.000000] Console: colour VGA+ 80x25
[ 0.000000] console [ttyS0] enabled
[ 0.000000] allocated 5242880 bytes of page_cgroup
[ 0.000000] please try 'cgroup_disable=memory' option if you don't
want memory cgroups
[ 0.000000] Fast TSC calibration failed
[ 0.000000] TSC: Unable to calibrate against PIT
[ 0.000000] TSC: using HPET reference calibration
[ 0.000000] Detected 1699.212 MHz processor.
[ 0.041737] Calibrating delay loop (skipped), value calculated
using timer frequency.. 3398.42 BogoMIPS (lpj=16992120)
[ 0.043018] pid_max: default: 32768 minimum: 301
[ 0.054291] Security Framework initialized
[ 0.062009] AppArmor: AppArmor initialized
[ 0.062344] Yama: becoming mindful.
[ 0.071324] Dentry cache hash table entries: 65536 (order: 7,
524288 bytes)
[ 0.075259] Inode-cache hash table entries: 32768 (order: 6, 262144
bytes)
[ 0.081739] Mount-cache hash table entries: 256
[ 0.095216] Initializing cgroup subsys ns
[ 0.098968] Initializing cgroup subsys cpuacct
[ 0.099429] Initializing cgroup subsys memory
[ 0.101044] Initializing cgroup subsys devices
[ 0.101501] Initializing cgroup subsys freezer
[ 0.102180] Initializing cgroup subsys net_cls
[ 0.105541] mce: CPU supports 10 MCE banks
[ 0.111667] Performance Events: AMD PMU driver.
[ 0.112770] ... version: 0
[ 0.113103] ... bit width: 48
[ 0.113703] ... generic registers: 4
[ 0.114082] ... value mask: 0000ffffffffffff
[ 0.114711] ... max period: 00007fffffffffff
[ 0.115109] ... fixed-purpose events: 0
[ 0.115685] ... event mask: 000000000000000f
[ 0.117187] SMP alternatives: switching to UP code
[ 0.310394] Freeing SMP alternatives: 24k freed
[ 0.314642] ACPI: Core revision 20100428
[ 0.370429] ftrace: converting mcount calls to 0f 1f 44 00 00
[ 0.371180] ftrace: allocating 23035 entries in 91 pages
[ 0.398135] Setting APIC routing to flat
[ 0.411039] ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
[ 0.520693] CPU0: AMD QEMU Virtual CPU version 0.12.3 stepping 03
[ 0.548227] Brought up 1 CPUs
[ 0.548594] Total of 1 processors activated (3398.42 BogoMIPS).
[ 0.563600] devtmpfs: initialized
[ 0.667025] regulator: core version 0.5
[ 0.668052] Time: 17:14:44 Date: 05/24/11
[ 0.670433] NET: Registered protocol family 16
[ 0.684929] ACPI: bus type pci registered
[ 0.688633] PCI: Using configuration type 1 for base access
[ 0.722063] bio: create slab <bio-0> at 0
[ 0.812591] ACPI: Interpreter enabled
[ 0.814148] ACPI: (supports S0 S3 S4 S5)
[ 0.816049] ACPI: Using IOAPIC for interrupt routing
[ 0.924229] ACPI: No dock devices found.
[ 0.924682] PCI: Ignoring host bridge windows from ACPI; if
necessary, use "pci=use_crs" and report a bug
[ 0.928476] ACPI: PCI Root Bridge [PCI0] (domain 0000 [bus 00-ff])
[ 0.939483] pci 0000:00:01.3: quirk: [io 0xb000-0xb03f] claimed by
PIIX4 ACPI
[ 0.940134] pci 0000:00:01.3: quirk: [io 0xb100-0xb10f] claimed by
PIIX4 SMB
[ 1.097477] ACPI: PCI Interrupt Link [LNKA] (IRQs 5 *10 11)
[ 1.100201] ACPI: PCI Interrupt Link [LNKB] (IRQs 5 *10 11)
[ 1.102250] ACPI: PCI Interrupt Link [LNKC] (IRQs 5 10 *11)
[ 1.104633] ACPI: PCI Interrupt Link [LNKD] (IRQs 5 10 *11)
[ 1.106029] HEST: Table is not found!
[ 1.112593] vgaarb: device added: PCI:0000:00:02.0,decodes=io
+mem,owns=io+mem,locks=none
[ 1.113341] vgaarb: loaded
[ 1.118445] SCSI subsystem initialized
[ 1.121149] usbcore: registered new interface driver usbfs
[ 1.122262] usbcore: registered new interface driver hub
[ 1.123456] usbcore: registered new device driver usb
[ 1.128930] ACPI: WMI: Mapper loaded
[ 1.130142] PCI: Using ACPI for IRQ routing
[ 1.141238] NetLabel: Initializing
[ 1.141550] NetLabel: domain hash size = 128
[ 1.142053] NetLabel: protocols = UNLABELED CIPSOv4
[ 1.144079] NetLabel: unlabeled traffic allowed by default
[ 1.146630] HPET: 3 timers in total, 0 timers will be used for per-
cpu timer
[ 1.147767] hpet0: at MMIO 0xfed00000, IRQs 2, 8, 0
[ 1.148284] hpet0: 3 comparators, 64-bit 100.000000 MHz counter
[ 1.161192] Switching to clocksource tsc
[ 1.396513] AppArmor: AppArmor Filesystem Enabled
[ 1.397750] pnp: PnP ACPI init
[ 1.398555] ACPI: bus type pnp registered
[ 1.415963] pnp: PnP ACPI: found 6 devices
[ 1.416495] ACPI: ACPI bus type pnp unregistered
[ 1.459176] NET: Registered protocol family 2
[ 1.465421] IP route cache hash table entries: 4096 (order: 3,
32768 bytes)
[ 1.473632] TCP established hash table entries: 16384 (order: 6,
262144 bytes)
[ 1.475741] TCP bind hash table entries: 16384 (order: 6, 262144
bytes)
[ 1.477986] TCP: Hash tables configured (established 16384 bind
16384)
[ 1.478538] TCP reno registered
[ 1.478934] UDP hash table entries: 256 (order: 1, 8192 bytes)
[ 1.479815] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[ 1.482550] NET: Registered protocol family 1
[ 1.483454] pci 0000:00:00.0: Limiting direct PCI/PCI transfers
[ 1.484003] pci 0000:00:01.0: PIIX3: Enabling Passive Release
[ 1.485061] pci 0000:00:01.0: Activating ISA DMA hang workarounds
[ 1.494114] Scanning for low memory corruption every 60 seconds
[ 1.499052] audit: initializing netlink socket (disabled)
[ 1.500217] type=2000 audit(1306257284.490:1): initialized
[ 1.618836] Trying to unpack rootfs image as initramfs...
[ 1.781400] HugeTLB registered 2 MB page size, pre-allocated 0
pages
[ 1.845435] VFS: Disk quotas dquot_6.5.2
[ 1.847059] Dquot-cache hash table entries: 512 (order 0, 4096
bytes)
[ 1.877985] fuse init (API version 7.14)
[ 1.880891] msgmni has been set to 968
[ 1.914591] Block layer SCSI generic (bsg) driver version 0.4
loaded (major 253)
[ 1.915278] io scheduler noop registered
[ 1.915635] io scheduler deadline registered (default)
[ 1.916720] io scheduler cfq registered
[ 1.919451] pci_hotplug: PCI Hot Plug PCI Core version: 0.5
[ 1.922131] pciehp: PCI Express Hot Plug Controller Driver version:
0.4
[ 1.928733] input: Power Button as /devices/LNXSYSTM:00/LNXPWRBN:00/
input/input0
[ 1.929948] ACPI: Power Button [PWRF]
[ 2.004568] ERST: Table is not found!
[ 2.009514] ACPI: PCI Interrupt Link [LNKD] enabled at IRQ 11
[ 2.010238] virtio-pci 0000:00:04.0: PCI INT A -> Link[LNKD] -> GSI
11 (level, high) -> IRQ 11
[ 2.026055] ACPI: PCI Interrupt Link [LNKA] enabled at IRQ 10
[ 2.026554] virtio-pci 0000:00:05.0: PCI INT A -> Link[LNKA] -> GSI
10 (level, high) -> IRQ 10
[ 2.032142] Linux agpgart interface v0.103
[ 2.033234] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
[ 2.035871] serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
[ 2.037263] serial8250: ttyS1 at I/O 0x2f8 (irq = 3) is a 16550A
[ 2.067092] brd: module loaded
[ 2.077755] loop: module loaded
[ 2.092431] vda: unknown partition table
[ 2.246241] scsi0 : ata_piix
[ 2.263140] scsi1 : ata_piix
[ 2.264470] ata1: PATA max MWDMA2 cmd 0x1f0 ctl 0x3f6 bmdma 0xc000
irq 14
[ 2.265008] ata2: PATA max MWDMA2 cmd 0x170 ctl 0x376 bmdma 0xc008
irq 15
[ 2.273016] Fixed MDIO Bus: probed
[ 2.274259] PPP generic driver version 2.4.2
[ 2.275659] tun: Universal TUN/TAP device driver, 1.6
[ 2.276068] tun: (C) 1999-2004 Max Krasnyansky <ma...@qualcomm.com>
[ 2.278623] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI)
Driver
[ 2.279442] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[ 2.280178] uhci_hcd: USB Universal Host Controller Interface
driver
[ 2.282939] uhci_hcd 0000:00:01.2: PCI INT D -> Link[LNKD] -> GSI
11 (level, high) -> IRQ 11
[ 2.283887] uhci_hcd 0000:00:01.2: UHCI Host Controller
[ 2.285640] uhci_hcd 0000:00:01.2: new USB bus registered, assigned
bus number 1
[ 2.287010] uhci_hcd 0000:00:01.2: irq 11, io base 0x0000c020
[ 2.302237] hub 1-0:1.0: USB hub found
[ 2.303237] hub 1-0:1.0: 2 ports detected
[ 2.308441] PNP: PS/2 Controller [PNP0303:KBD,PNP0f13:MOU] at
0x60,0x64 irq 1,12
[ 2.314537] serio: i8042 KBD port at 0x60,0x64 irq 1
[ 2.315359] serio: i8042 AUX port at 0x60,0x64 irq 12
[ 2.317662] mice: PS/2 mouse device common for all mice
[ 2.321670] rtc_cmos 00:01: rtc core: registered rtc_cmos as rtc0
[ 2.323023] rtc0: alarms up to one day, 114 bytes nvram, hpet irqs
[ 2.325634] device-mapper: uevent: version 1.0.3
[ 2.332191] input: AT Translated Set 2 keyboard as /devices/
platform/i8042/serio0/input/input1
[ 2.396669] device-mapper: ioctl: 4.17.0-ioctl (2010-03-05)
initialised: dm-d...@redhat.com
[ 2.413687] device-mapper: multipath: version 1.1.1 loaded
[ 2.414489] device-mapper: multipath round-robin: version 1.0.0
loaded
[ 2.419185] cpuidle: using governor ladder
[ 2.419617] cpuidle: using governor menu
[ 2.425367] TCP cubic registered
[ 2.428356] NET: Registered protocol family 10
[ 2.442456] lo: Disabled Privacy Extensions
[ 2.447634] NET: Registered protocol family 17
[ 2.449203] powernow-k8: Processor cpuid 623 not supported
[ 2.456522] registered taskstats version 1
[ 2.459339] Magic number: 11:767:239
[ 2.461310] rtc_cmos 00:01: setting system clock to 2011-05-24
17:14:46 UTC (1306257286)
[ 2.462093] BIOS EDD facility v0.16 2004-Jun-25, 0 devices found
[ 2.462532] EDD information not available.
[ 3.453511] Freeing initrd memory: 5748k freed
[ 3.477184] Freeing unused kernel memory: 828k freed
[ 3.518250] Write protecting the kernel read-only data: 10240k
[ 3.523237] Freeing unused kernel memory: 308k freed
[ 3.527381] Freeing unused kernel memory: 1620k freed
Used vda for root filesystem
pivot_root: Invalid argument
init started: BusyBox v1.17.2 (2010-10-17 16:10:18 MST)
stty: /dev/console
ttylinux 12.1
> http://ttylinux.org/
> hostname: ttylinux_host
load Kernel Module: acpiphp [ OK ]
load Kernel Module: e1000 [ OK ]
load Kernel Module: ne2k-pci [ OK ]
[ 7.247628] ACPI: PCI Interrupt Link [LNKC] enabled at IRQ 11
load Kernel Module: 8139cp [ OK ]
load Kernel Module: pcnet32 [ OK ]
load Kernel Module: mii [ OK ]
load Kernel Module: ip_tables [ OK ]
file systems checked [ OK ]
mounting local file systems [ OK ]
setting up system clock [utc] Tue May 24 17:14:53 UTC 2011 [ OK ]
stty: /dev/console
stty: /dev/console
initializing random number generator [WATING].. [ OK ]
stty: /dev/console
startup klogd [ OK ]
startup syslogd [ OK ]
stty: /dev/console
stty: /dev/console
bringing up loopback interface lo [ OK ]
stty: /dev/console
udhcpc (v1.17.2) started
Sending discover...
Sending discover...
Sending discover...
No lease, forking to background
starting DHCP forEthernet interface eth0 [ OK ]
cloud-setup: checking http://169.254.169.254/2009-04-04/meta-data/instance-id
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 1/30: up 28.18. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 2/30: up 29.75. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 3/30: up 31.12. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 4/30: up 32.59. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 5/30: up 34.00. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 6/30: up 35.63. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 7/30: up 36.99. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 8/30: up 38.35. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 9/30: up 39.70. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 10/30: up 41.02. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 11/30: up 42.41. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 12/30: up 43.81. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 13/30: up 45.24. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 14/30: up 46.74. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 15/30: up 48.18. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 16/30: up 49.78. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 17/30: up 51.14. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 18/30: up 52.59. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 19/30: up 53.95. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 20/30: up 55.33. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 21/30: up 56.70. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 22/30: up 58.10. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 23/30: up 59.48. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 24/30: up 60.89. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 25/30: up 62.32. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 26/30: up 63.75. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 27/30: up 65.15. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 28/30: up 66.56. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 29/30: up 67.93. request failed
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-setup: failed 30/30: up 69.06. request failed
cloud-setup: after 30 fails, debugging
cloud-setup: running debug (30 tries reached)
############ debug start ##############
### /etc/rc.d/init.d/sshd start
stty: /dev/console
generating DSS host key [WATING].. [ OK ]
generating RSA host key [WATING].. [ OK ]
startup dropbear [ OK ]
route: fscanf
### ifconfig -a
eth0 Link encap:Ethernet HWaddr 02:16:3E:67:1A:C3
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:12 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:2400 (2.3 KiB)
Interrupt:11 Base address:0xc000
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
### route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref
Use Iface
route: fscanf
### cat /etc/resolv.conf
cat: can't open '/etc/resolv.conf': No such file or directory
### gateway not found
/etc/rc.d/init.d/cloud-functions: line 41: /etc/resolv.conf: No such
file or directory
### pinging nameservers
### uname -a
Linux ttylinux_host 2.6.35-22-virtual #35-Ubuntu SMP Sat Oct 16
23:19:29 UTC 2010 x86_64 GNU/Linux
### lsmod
Module Size Used by
ip_tables 18737 0
x_tables 24391 1 ip_tables
pcnet32 36585 0
8139cp 20333 0
mii 5261 2 pcnet32,8139cp
ne2k_pci 7802 0
8390 9897 1 ne2k_pci
e1000 110274 0
acpiphp 18752 0
### dmesg | tail
<6>[ 7.036230] ne2k-pci.c:v1.03 9/22/2003 D. Becker/P. Gortmaker
<6>[ 7.240108] 8139cp: 8139cp: 10/100 PCI Ethernet driver v1.3 (Mar
22, 2004)
<4>[ 7.247628] ACPI: PCI Interrupt Link [LNKC] enabled at IRQ 11
<6>[ 7.248434] 8139cp 0000:00:03.0: PCI INT A -> Link[LNKC] -> GSI
11 (level, high) -> IRQ 11
<6>[ 7.258585] 8139cp 0000:00:03.0: eth0: RTL-8139C+ at
0xffffc900001dc000, 02:16:3e:67:1a:c3, IRQ 11
<7>[ 7.258753] 8139cp 0000:00:03.0: setting latency timer to 64
<6>[ 7.424418] pcnet32: pcnet32.c:v1.35 21.Apr.2008
tsbo...@alpha.franken.de
<6>[ 7.833389] ip_tables: (C) 2000-2006 Netfilter Core Team
<6>[ 17.615836] eth0: link up, 100Mbps, full-duplex, lpa 0x05E1
<7>[ 28.219928] eth0: no IPv6 routers present
### tail -n 25 /var/log/messages
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.616913]
acpiphp: Slot [20] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.617403]
acpiphp: Slot [21] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.617906]
acpiphp: Slot [22] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.618331]
acpiphp: Slot [23] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.618794]
acpiphp: Slot [24] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.619250]
acpiphp: Slot [25] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.619755]
acpiphp: Slot [26] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.620205]
acpiphp: Slot [27] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.620639]
acpiphp: Slot [28] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.621041]
acpiphp: Slot [29] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.621808]
acpiphp: Slot [30] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.622280]
acpiphp: Slot [31] registered
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.810688] e1000:
Intel(R) PRO/1000 Network Driver - version 7.3.21-k6-NAPI
May 24 17:14:57 ttylinux_host user.info kernel: [ 6.810807] e1000:
Copyright (c) 1999-2006 Intel Corporation.
May 24 17:14:57 ttylinux_host user.info kernel: [ 7.036230] ne2k-
pci.c:v1.03 9/22/2003 D. Becker/P. Gortmaker
May 24 17:14:57 ttylinux_host user.info kernel: [ 7.240108] 8139cp:
8139cp: 10/100 PCI Ethernet driver v1.3 (Mar 22, 2004)
May 24 17:14:57 ttylinux_host user.warn kernel: [ 7.247628] ACPI:
PCI Interrupt Link [LNKC] enabled at IRQ 11
May 24 17:14:57 ttylinux_host user.info kernel: [ 7.248434] 8139cp
0000:00:03.0: PCI INT A -> Link[LNKC] -> GSI 11 (level, high) -> IRQ
11
May 24 17:14:57 ttylinux_host user.info kernel: [ 7.258585] 8139cp
0000:00:03.0: eth0: RTL-8139C+ at 0xffffc900001dc000, 02:16:3e:
67:1a:c3, IRQ 11
May 24 17:14:57 ttylinux_host user.debug kernel: [ 7.258753] 8139cp
0000:00:03.0: setting latency timer to 64
May 24 17:14:57 ttylinux_host user.info kernel: [ 7.424418]
pcnet32: pcnet32.c:v1.35 21.Apr.2008 tsbo...@alpha.franken.de
May 24 17:14:57 ttylinux_host user.info kernel: [ 7.833389]
ip_tables: (C) 2000-2006 Netfilter Core Team
May 24 17:15:01 ttylinux_host user.info kernel: [ 17.615836] eth0:
link up, 100Mbps, full-duplex, lpa 0x05E1
May 24 17:15:11 ttylinux_host user.debug kernel: [ 28.219928] eth0:
no IPv6 routers present
May 24 17:15:58 ttylinux_host authpriv.info dropbear[267]: Running in
background
############ debug end ##############
cloud-setup: failed to read iid from metadata. tried 30
stty: /dev/console
sshd is already running.
stty: /dev/console
startup inetd [ OK ]
stty: /dev/console
startup crond [ OK ]
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
cloud-userdata: failed to read instance id
===== cloud-final: system completely up in 79.15 seconds ====
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
wget: can't connect to remote host (169.254.169.254): Network is
unreachable
instance-id:
public-ipv4:
local-ipv4 :
=> First-Boot Sequence:
setting shared object cache [running ldconfig] [ OK ]
> --sql_connection=mysql://root:ntts...@172.16.25.2/nova
> --network_manager=nova.network.manager.VlanManager
> --libvirt_type=qemu<http://172.16.25.2:8773/services/Cloud--fixed_range=172.16.25.0/27--network _size=20--FAKE_subdomain=ec2--routing_source_ip=172.16.25.2--verbose--sql_c onnection=mysql://root:ntts...@172.16.25.2/nova--network_manager=nova.network.manager.FlatManager--libvir t_type=qemu>
> --vlan_interface=eth0
> --public_interface=eth0
>
> 『Step4 MySQL内のnovaデータベースのnetworksテーブルとfixed_ipsテーブルの削除』
> MySQLサーバにログインし、下記に示すSQLを実行。
>
> root@ubuntu: mysql --user=root --password=nttsoft<http://172.16.25.2:8773/services/Cloud--fixed_range=172.16.25.0/27--network _size=20--FAKE_subdomain=ec2--routing_source_ip=172.16.25.2--verbose--sql_c onnection=mysql://root:ntts...@172.16.25.2/nova--network_manager=nova.network.manager.FlatManager--libvir t_type=qemu>
すいません。
バタバタしてしまってまだパッチの確認取れていないです。
いくつか設定項目を忘れていました。順番が順不同になってしまって申し訳ないです。
1 nova-networkのブリッジインターフェースにネットワークアドレスの一番目のアドレス
2 iptablesの設定
3 ip_forwardの設定
4 169.254.169.254/32 のアドレスをループバックインターフェースに割り当てる。
5 ゲストからアクセスするネットワークインターフェースにブリッジをbr100として割り当てる
これらがなぜ必要かについて原因だけ
guestがhttp://169.254.169.254/2009-04-04/meta-data/instance-id
この情報をとりにいくのにデフォルトゲートウェイにとりに行こうとします。
そのIPAddressが1番目のアドレスであって、そのアドレスがnova-apiにリダイレクトされないとい
けないから上記の設定が必要になります。
#個人的にはnova-compute上でリダイレクトしてくれればいいのにと思います。
FlatDHCPManagerなどではnova-network上でnova-apiにリダイレクトしてくれます。
マニュアルに記載されているiptablesではnova-networkが一つであると限定し、その上でnova-api
が動作している事が前提となっています。コードにそのへんのコメントは少しだけ書いてあります。
DBのnetworksのNULLなどをみて中途半端にFlatManagerだと判断したりしますので、
NetworkManagerを変更する際はnova-manage db syncからやり直したほうがいいと思います。
最低限DBのnetworksとfixed_ipsをtruncateしてネットワークから作成しないと
FlatDHCPManagerにしてもflat_injectedが走ってしまってリゾルバの設定が上書きされたりします。
一応パッチ作ったのですがきちんとどうさするかもう少しテストしてからにします。
On Tue, 24 May 2011 02:10:58 -0700 (PDT)
tacky1052 <takiguchi...@gmail.com> wrote:
--
Hisashi Ikari <igoi...@gmail.com>
> ubuntu1010-UEC-localuser-imageが悪いのかと思い
> イメージを伊藤さんに教えていただいた
> http://images.ansolabs.com/tty.tgz
> に変更したら、 コンソールログがこんな(下記)感じになりました。
> やはりメタデータはwgetできていないようです。
うっかりしていましたが、tty.tgzイメージはDHCPでIPアドレスを取得する必要
があり、FlatManager ではIPアドレスの設定ができないという問題があります。
添付いただいたログから察するに、VMの起動はできているのですが、IPアドレス
の設定に失敗しているため、ネットワークのアクセスができていない状態に見え
ます。
ttyイメージはDebian系のディストリではないので、FlatManagerが実施する
/etc/network/interfaces のインジェクトが効かないです。
FlatDHCPManagerで tty イメージで試されるときっと動くと思います。