xen xen-kernel doesn't start at all

mutterhunt

New Member


Messages: 18

I have a i7 ivy-bridge put to CSM compatibility with BIOS first. My settings for the dom0 are:

/boot/loader.conf:

Code:
kernel_load="YES"
vfs.root.mountfrom=ad1p6
set vfs.root.mountfrom.options=rw
if_bridge_load="YES"
if_tap_load="YES"
vmm_load="YES"
fusefs_load="YES"
xen_kernel="/boot/xen"
xen_cmdline="dom0_mem=4048M dom0_max_vcpus=4 dom0pvh=1 com1=115200,8n1 guest_loglvl=all loglvl=all"
boot_multicons="YES"
boot_serial="YES"
comconsole_speed="115200"
console="comconsole,efi"
boot_verbose="YES"
hw.pci.mcfg=0


and followed the guide for installing the XEN-kernel. My /etc/ttys is:

Code:
xencommons_enable="YES"
xc0     "/usr/libexec/getty Pc"         vt100   on  secure
ttyu0   "/usr/libexec/getty std.115200" dialup  on  secure

First of all, it is unable to find the root device (ada1p6), even when copying it to /boot/defaults and secondly when activating the xen-kernel it doesn't boot at all, loading the modules but no xen-kernel showing up.

what do I making wrong?

Lizbeth
 
OP
mutterhunt

mutterhunt

New Member


Messages: 18

which you mean? my typos are famous as legastenic! tried with "brackets", doesn't help. and AFAIK it isn't ada1p6. /etc/fstab is alright!

not with vfs.root.mountfrom="ufs:ad1p6" (copied and pasted and modified) nor with with other versions of it.

/etc/fstab:
Code:
/dev/ada1p6             /           ufs       rw      0       1
/dev/ada1p7             swap    none    sw      0       0

[5 mins. later]

works now! with
Code:
vfs.root.mountfrom="ufs:ada1p6"
but this was not the main issue! what to do with the xen-kernel!
 

Phishfry

Beastie's Twin

Reaction score: 2,645
Messages: 5,561

devel/libvirt from packages does not include Xen support.
You must compile it from ports and enable Xen in port options.
That was what I found when I tested it years ago.
Xen needs libvirt.

XEN=off: Xen support via libxl
 

George

Aspiring Daemon

Reaction score: 201
Messages: 506

I dunno I thought from FreeBSD 9 onwards the ad driver is no more. ;D
 
OP
mutterhunt

mutterhunt

New Member


Messages: 18

OP
mutterhunt

mutterhunt

New Member


Messages: 18

Code:
virsh -c "xen://":
Failed to connect socket to '/var/run/libvirt/virtxend-sock': No such file or directory
I guess it is for a running xen-kernel! I had it on this PC very early and it worked great! Now I really don't know, why this damn thing doesn't boot!
 

Phishfry

Beastie's Twin

Reaction score: 2,645
Messages: 5,561

Did you make an XML file for Xen? libvirt must be configured. I have no idea if this is related to your problem but libvirt should be setup and running for Xen.
 

SirDice

Administrator
Staff member
Administrator
Moderator

Reaction score: 11,959
Messages: 38,420

Is this a typo?
Code:
xencommons_enable="YES"
xc0     "/usr/libexec/getty Pc"         vt100   on  secure
ttyu0   "/usr/libexec/getty std.115200" dialup  on  secure
That xencommons_enable="YES" doesn't belong in /etc/ttys.
 

Phishfry

Beastie's Twin

Reaction score: 2,645
Messages: 5,561

Looking at the instructions here:

I see no mention of libvirt. So maybe that is just one method of using Xen.
The page is 5 years old so take that into account.

Please note the banner on the above page. Legacy BIOS support only.
So make sure your host BIOS is set to legacy. Also note IOMMU CPU required.
 
OP
mutterhunt

mutterhunt

New Member


Messages: 18

SirDice: yup, was a typok, corrected it to /etc/rc.conf!
Phishfry: what I did now was to write bootcode to /dev/ada1 with gpart; I had big problems to get other systems back and had to delete the /dev/ada1p1 and reconnect it to systems like coping the .efi-file from the rescue image to the partition. I do not know how often I had the wiki-page for FreeBSD open in the last 72 hours!

I think it has to do with the (U)EFI bootmode; I set to CSM in BIOS, MBR first, but FreeBSD is booting .EFI. How to change that?
 

Ole

Active Member

Reaction score: 78
Messages: 121

My FreeBSD 13.0-RELEASE with xen-kernel/xen-tools (4.15) work fine via UEFI boot. All XEN-related settings:

1) /boot/loader.conf (hint: vmm_load="YES" should be absent):
Code:
...
xen_kernel="/boot/xen"
xen_cmdline="dom0_mem=2048M dom0_max_vcpus=2 dom0=pvh com1=115200,8n1 guest_loglvl=all loglvl=all"

2) /etc/sysctl.conf:
Code:
...
vm.max_user_wired=-1

3) /etc/ttys:
Code:
...
xc0     /usr/libexec/getty Pc           xterm   onifconsole     secure

4) /etc/rc.conf:
Code:
..
xencommons_enable="YES"
xendriverdomain_enable="YES"
 

Ole

Active Member

Reaction score: 78
Messages: 121

devel/libvirt from packages does not include Xen support.
Xen needs libvirt.
You are wrong, XEN does not require libvirt. This package may be required, for example, for virt-manager to manage XEN. In addition to the virt-manager, you can manage XEN (in addition to xl ) via CBSD ( at least I manage a small XEN cluster with CBSD ;-)
 
OP
mutterhunt

mutterhunt

New Member


Messages: 18

Sorry for course in advance: shit!

No change at all, xen_kernel doesn't boot and FreeBSD 14 is only bootable with key 6 for the built kernel change and the 3 for command line with "unset xen_kernel" and "boot" afterwards.

Installed CBSD and set it up to the home directory but take care, with sudo it is too less on permissions for setting up! But I think that it is a question for controlling the hypervisor after kernel successfully booted, what definitely is not doing how it should!

My thoughts go back to the MBR in PCB mode first before UEFI boots, but this is with this installation probably impossible.
[OT]:

I installed FreeBSD_CURRENT from the mini-memstick and ftp'd the sets because of mismatch of checksum in the installation program. So there were no inodes made after installation but a "tar xfv set*"; I configured /etc/rc.conf and network manually and keep on working on a splash screen, but the bitmap doesn't work, I guess because of the colours (should be the same as my avatar here). Any other ideas?

At the moment I'm working on a Hackintosh Monterey, but getting no sound with the Voodoo driver as well as with LILO.kext and ALC.kext. To listen to music I had to install windoze with a cracked parallels with the apple hypervisor and connect my bluetooth stick (rtl8761b) in the VM, so I can listen now to YT or Kodi or whatever! There's linux driver for this device but nothing for Mac and the HDMI output doesn't work. With linux there's a dkms config and it does what it should; working like a charm! is what I learned there. I never forget that the mach-kernel is the double of our CURRENT, so I don't forget the base, that made the OC-loader for Mac possible. Ok, enough from this point of view, it was a month of work!

[/OT]


So, last change, I guess, if someone knows anything how to get the XEN work, please help!

Lizbeth
 
OP
mutterhunt

mutterhunt

New Member


Messages: 18

ahhh! with the 13-RELEASE it is tired and available for everybody, but 14 for specialists! All I can do, is making a Virtual Machine with OsX or linux and boot it from there on (this works, I tried it out!) or making a Virtual Machine in the 14_CURRENT release with 13-RELEASE with qemu or virtualbox-ose!

Gonna write in the forums, I already did ant freebsd-current@freebsd.org mailing list, but got no answer, maybe your proposal is good like this; we discuss it in the mailing list and bring the result here for others!

Lizbeth
 
OP
mutterhunt

mutterhunt

New Member


Messages: 18

to let a intermed behind: we're making a virtual console on a plain FreeBSD14 machine "greatgrandma" Dell on the receiving end, and on the other end we connect it to the port but with problems, as the 9-pin don't match the cable. It *needs* to be a 0-modem-cable. we'll update with output of the serial console.

lizbeth
 

Phishfry

Beastie's Twin

Reaction score: 2,645
Messages: 5,561

It *needs* to be a 0-modem-cable. we'll update with output of the serial console.
Yes commonly referred to as null modem cable.

Most older APC UPS used the null modem cable. So easy to scape those.

The advice about FreeBSD 13 is valid.
FreeBSD 14 is a development version right now. It can be broke by design.
Under construction. Danger Zone.
 
OP
mutterhunt

mutterhunt

New Member


Messages: 18

not all warnings given are exectely included permanently, I think. And for me it's the moment of updating to latest source when system has been built after make buildworld -j9 and install buildworld -j9, what takes "great-grandma" a temperature of 80° on mainboard and something useful to do for 27 hours.

for me it always has been the "newest version" and "latest" and "current" what did it's fascination and when success it's motivation for bad times enough, no need to go around and earn something with it. there's still enough pressure and I guess the "CURRENT" and brandnew thing is for forgetting how damn fast the time has been. What today is modern and in, is out tomorrow and people tend to suffer on the sickness of being empty with one reasen: the capitalism and wellfare everywhere. and: the sensorical (en-)privation - neologism?.

speak with elder people and they will all tell you the same: that the system will accellerate so fast that it's getting a mary-go-around seen as charts for breaking down completely. the covide was just a warning by nature.
 
Top