# solaris on kvm issues

## Adel Ahmed

I have installed solaris 11 on KVM, default configuration.

While the machine is working just fine, there seems to be something with the network card, dhcp and static configurations are not working, it seems the vm is unable to reach the physical machine or any other virtual machines.

I have applied the following configuration to the xml file:

<feature name="x2apic" policy="disable"/>

But no dice.

any suggestions?

----------

## szatox

One common pitfall is when people forget to enable IP forwarding in host's kernel.

Good news is you can do that at runtime.

Could be a firewall issue too.

how did you configure your network?

I mean host's configuration (including relations between interfaces, e.g. bridges), guest OS  configuration, and qemu networking mode/VNIC model. Need some information to make a good guess.

----------

## Hu

I suggest you tell us exactly what commands you used that led you to the conclusion (no connectivity) that you posted.  Tell us what error messages were produced, if any.  Tell us what you have checked so far.  What failure modes have you ruled out, and how?

----------

## Adel Ahmed

Other virtual machines are working just fine, so I do not think this is a forwarding issue

```

g50-80 ~ # iptables -L

Chain INPUT (policy ACCEPT)

target     prot opt source               destination         

ACCEPT     udp  --  anywhere             anywhere             udp dpt:domain

ACCEPT     tcp  --  anywhere             anywhere             tcp dpt:domain

ACCEPT     udp  --  anywhere             anywhere             udp dpt:bootps

ACCEPT     tcp  --  anywhere             anywhere             tcp dpt:bootps

Chain FORWARD (policy ACCEPT)

target     prot opt source               destination         

ACCEPT     all  --  anywhere             192.168.122.0/24     ctstate RELATED,ESTABLISHED

ACCEPT     all  --  192.168.122.0/24     anywhere            

ACCEPT     all  --  anywhere             anywhere            

REJECT     all  --  anywhere             anywhere             reject-with icmp-port-unreachable

REJECT     all  --  anywhere             anywhere             reject-with icmp-port-unreachable

Chain OUTPUT (policy ACCEPT)

target     prot opt source               destination         

ACCEPT     udp  --  anywhere             anywhere             udp dpt:bootpc

g50-80 ~ # brctl show

bridge name   bridge id      STP enabled   interfaces

virbr0      8000.fe54003576d9   yes      vnet1

virbr0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500

        inet 192.168.122.1  netmask 255.255.255.0  broadcast 192.168.122.255

        ether fe:54:00:35:76:d9  txqueuelen 1000  (Ethernet)

        RX packets 129294  bytes 93155147 (88.8 MiB)

        RX errors 0  dropped 2227  overruns 0  frame 0

        TX packets 184046  bytes 30196968 (28.7 MiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

vnet1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500

        ether fe:54:00:35:76:d9  txqueuelen 1000  (Ethernet)

        RX packets 126962  bytes 94467171 (90.0 MiB)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 214000  bytes 31746238 (30.2 MiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

```

I have configured the machine using  a static IP, then I use ICMP and ssh to test the machine, both hosts are unable to communicate with each other, and unable to ssh to each other .

I'm using virtual network 'default' : NAT

device model is rtl8139    and I have tried the following model:

e1000

I only have NAT available in my configuration, I have not compiled support for bridging.

thanks

[Moderator edit: added [code] tags to preserve output layout. -Hu]

----------

## Adel Ahmed

help anyone?

----------

## szatox

You say you don't have support for bridging, but your console output shows bridge virbr0 and enslaved vnet1.

You can try changing options on the bridge. This set works really well (make sure you don't make a loop)

setfd 0

sethello 10

stp off

Alternatively, if you don't want to use bridge, you can release that vnet from bridge and assign him an IP address.

Rules from your filter table look fine. What about rules from nat table?

For routing that traffic you will also need IP forwarding on your host.

```
sysctl -a | grep forward

net.ipv4.conf.all.forwarding = 1
```

Do those other VMs also attach to that bridge?

Does your solaris detect that virtual NIC? What IP is assigned inside the virtual machine?

----------

## Adel Ahmed

I appreciate everyone's help, but it had started working, I will try installing another solaris machine to see if the problem persists.

thanks

----------

