Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Working in Centos 7, with systemd
- -------
- Patches worked, patched configure worked. Build completed. RPM built
- Install of Xen worked without any kind of warning or message.
- Reboot worked, Xen started, and 3 VM auto-started.
- However, the libxl error messages are not fixed. My original patch fixed those.
- libxl messages are seen in xendomains status, below.
- In the top here, there is xendomains status still with the noisy error messages. So the xen-init-dom0.service
- didn't fix that.
- Below there is a patch I added to ./tools.configure.ac to fix ./tools/configure
- and this was enough to get a build to complete.
- sudo systemctl status xen-qemu-dom0-disk-backend xenstored xendomains xen-init-dom0
- --------------------
- xen-qemu-dom0-disk-backend.service - qemu for xen dom0 disk backend
- Loaded: loaded (/usr/lib/systemd/system/xen-qemu-dom0-disk-backend.service; enabled)
- Active: active (running) since Sun 2014-10-19 14:42:45 PDT; 1min 36s ago
- Process: 686 ExecStartPre=/bin/mkdir -p /var/run/xen (code=exited, status=0/SUCCESS)
- Process: 681 ExecStartPre=/bin/grep -q control_d /proc/xen/capabilities (code=exited, status=0/SUCCESS)
- Main PID: 773 (qemu-system-i38)
- CGroup: /system.slice/xen-qemu-dom0-disk-backend.service
- └─773 /usr/lib/xen/bin/qemu-system-i386 -xen-domid 0 -xen-attach -name dom0 -nographic -M xenpv -daemonize -m...
- Oct 19 14:42:45 c7dom0 systemd[1]: Started qemu for xen dom0 disk backend.
- xenstored.service - The Xen xenstore
- Loaded: loaded (/usr/lib/systemd/system/xenstored.service; enabled)
- Active: active (running) since Sun 2014-10-19 14:42:44 PDT; 1min 36s ago
- Process: 651 ExecStartPost=/usr/bin/xenstore-write /local/domain/0/domid 0 (code=exited, status=0/SUCCESS)
- Process: 622 ExecStartPost=/usr/bin/xenstore-write /local/domain/0/name Domain-0 (code=exited, status=0/SUCCESS)
- Process: 576 ExecStartPre=/bin/mkdir -p /var/run/xen (code=exited, status=0/SUCCESS)
- Process: 572 ExecStartPre=/bin/rm -f /var/lib/xenstored/tdb* (code=exited, status=0/SUCCESS)
- Process: 566 ExecStartPre=/bin/grep -q control_d /proc/xen/capabilities (code=exited, status=0/SUCCESS)
- Main PID: 579 (oxenstored)
- CGroup: /system.slice/xenstored.service
- └─579 /usr/sbin/oxenstored --no-fork
- Oct 19 14:42:44 c7dom0 sh[579]: Xen Storage Daemon, version 1.0
- Oct 19 14:42:44 c7dom0 systemd[1]: Started The Xen xenstore.
- xendomains.service - Xendomains - start and stop guests on boot and shutdown
- Loaded: loaded (/usr/lib/systemd/system/xendomains.service; enabled)
- Drop-In: /usr/lib/systemd/system/xendomains.service.d
- └─add_lvm.conf
- Active: active (exited) since Sun 2014-10-19 14:43:18 PDT; 1min 3s ago
- Process: 1049 ExecStart=/usr/lib/xen/bin/xendomains start (code=exited, status=0/SUCCESS)
- Process: 1047 ExecStartPre=/bin/grep -q control_d /proc/xen/capabilities (code=exited, status=0/SUCCESS)
- Main PID: 1049 (code=exited, status=0/SUCCESS)
- CGroup: /system.slice/xendomains.service
- ├─1167 /usr/sbin/xl create --quiet --defconfig /etc/xen/auto/a_c7min
- ├─1286 /usr/sbin/xl create --quiet --defconfig /etc/xen/auto/b_jesdev
- └─1413 /usr/sbin/xl create --quiet --defconfig /etc/xen/auto/c_wheez64
- Oct 19 14:43:04 c7dom0 systemd[1]: Starting Xendomains - start and stop guests on boot and shutdown...
- Oct 19 14:43:04 c7dom0 xendomains[1049]: Starting auto Xen domains: a_c7minlibxl: error: libxl.c:6292:libxl_retrie...main 0
- Oct 19 14:43:09 c7dom0 xendomains[1049]: b_jesdevlibxl: error: libxl.c:6292:libxl_retrieve_domain_configuration: f...main 0
- Oct 19 14:43:13 c7dom0 xendomains[1049]: c_wheez64libxl: error: libxl.c:6292:libxl_retrieve_domain_configuration: ...main 0
- Oct 19 14:43:13 c7dom0 logger[1379]: /etc/xen/scripts/vif-bridge: online type_if=vif XENBUS_PATH=backend/vif/3/0
- Oct 19 14:43:18 c7dom0 xendomains[1049]: [ OK ]
- Oct 19 14:43:18 c7dom0 systemd[1]: Started Xendomains - start and stop guests on boot and shutdown.
- xen-init-dom0.service - xen-init-dom0, initialise JSON configuration stub for Dom0
- Loaded: loaded (/usr/lib/systemd/system/xen-init-dom0.service; enabled)
- Active: inactive (dead) since Sun 2014-10-19 14:42:45 PDT; 1min 35s ago
- Process: 655 ExecStart=/usr/lib/xen/bin/xen-init-dom0 (code=exited, status=0/SUCCESS)
- Main PID: 655 (code=exited, status=0/SUCCESS)
- CGroup: /system.slice/xen-init-dom0.service
- Oct 19 14:42:45 c7dom0 xen-init-dom0[655]: Dom0 is already set up
- Oct 19 14:42:45 c7dom0 systemd[1]: Started xen-init-dom0, initialise JSON configuration stub for Dom0.
- Hint: Some lines were ellipsized, use -l to show in full.
- ----------- snip status -------
- $ sudo xl list 0
- Name ID Mem VCPUs State Time(s)
- Domain-0 0 512 2 r----- 8.0
- $ sudo xl list -l 0
- libxl: error: libxl.c:6292:libxl_retrieve_domain_configuration: fail to get domain configuration for domain 0
- [
- ]
- sudo xl info
- host : c7dom0
- release : 3.16.0-1.el7.elrepo.x86_64
- version : #1 SMP Sun Aug 3 19:29:26 EDT 2014
- machine : x86_64
- nr_cpus : 2
- max_cpu_id : 3
- nr_nodes : 1
- cores_per_socket : 2
- threads_per_core : 1
- cpu_mhz : 3062
- hw_caps : bfebfbff:20100800:00000000:00000900:0408e3bd:00000000:00000001:00000000
- virt_caps : hvm
- total_memory : 4094
- free_memory : 2122
- sharing_freed_memory : 0
- sharing_used_memory : 0
- outstanding_claims : 0
- free_cpus : 0
- xen_major : 4
- xen_minor : 5
- xen_extra : -unstable
- xen_version : 4.5-unstable
- xen_caps : xen-3.0-x86_64 xen-3.0-x86_32p hvm-3.0-x86_32 hvm-3.0-x86_32p hvm-3.0-x86_64
- xen_scheduler : credit
- xen_pagesize : 4096
- platform_params : virt_start=0xffff800000000000
- xen_changeset : Thu Oct 16 10:08:39 2014 +0200 git:9cea500-dirty
- xen_commandline : placeholder dom0_mem=512M,max:608M earlyprintk=xen guest_loglvl=all loglvl=all text
- cc_compiler : gcc (GCC) 4.8.2 20140120 (Red Hat 4.8.2-16)
- cc_compile_by : tlviewer
- cc_compile_domain :
- cc_compile_date : Sun Oct 19 13:56:13 PDT 2014
- xend_config_format : 4
- $ sudo xl list
- Name ID Mem VCPUs State Time(s)
- Domain-0 0 512 2 r----- 8.2
- c7min 1 512 2 -b---- 7.5
- jesdev 2 512 2 -b---- 6.2
- wheez64 3 384 2 -b---- 9.5
- $ exit
- logout
- $ ssh -qY user@192.168.1.228
- Last login: Sun Oct 19 14:29:14 2014 from 192.168.1.104
- $ cd ./unstable/
- $ ls
- xen.fedora.efi.build.patch xen.unstable.man.xl.pod1.patch xen.unstable.tools.rpmball.patch
- xen.unstable.init.dom0.patch xen.unstable.tools.config.patch
- $ cat xen.unstable.init.dom0.patch
- --- a/tools/hotplug/Linux/systemd/Makefile
- +++ b/tools/hotplug/Linux/systemd/Makefile
- @@ -14,6 +14,7 @@ XEN_SYSTEMD_SERVICE += xenconsoled.service
- XEN_SYSTEMD_SERVICE += xen-qemu-dom0-disk-backend.service
- XEN_SYSTEMD_SERVICE += xendomains.service
- XEN_SYSTEMD_SERVICE += xen-watchdog.service
- +XEN_SYSTEMD_SERVICE += xen-init-dom0.service
- ALL_XEN_SYSTEMD = $(XEN_SYSTEMD_MODULES) \
- $(XEN_SYSTEMD_MOUNT) \
- --- /dev/null
- +++ b/tools/hotplug/Linux/systemd/xen-init-dom0.service.in
- @@ -0,0 +1,12 @@
- +[Unit]
- +Description=xen-init-dom0, initialise JSON configuration stub for Dom0
- +Requires=xenstored.socket
- +After=xenstored.service
- +ConditionVirtualization=xen
- +
- +[Service]
- +Type=oneshot
- +ExecStart=@LIBEXEC_BIN@/xen-init-dom0
- +
- +[Install]
- +WantedBy=multi-user.target
- --- a/tools/hotplug/Linux/systemd/xendomains.service.in
- +++ b/tools/hotplug/Linux/systemd/xendomains.service.in
- @@ -1,7 +1,8 @@
- [Unit]
- Description=Xendomains - start and stop guests on boot and shutdown
- Requires=xenstored.socket
- -After=xenstored.service xenconsoled.service
- +After=network.target xenstored.service xenconsoled.service xen-init-dom0.service
- +Before=rc-local.service
- ConditionVirtualization=xen
- [Service]
- [tlviewer@c7min unstable]$ cat xen.unstable.tools.config.patch
- --- ./tools/configure.ac.orig 2014-10-19 13:46:57.513852146 -0700
- +++ ./tools/configure.ac 2014-10-19 13:48:41.597852146 -0700
- @@ -18,6 +18,7 @@
- hotplug/Linux/systemd/xen-watchdog.service
- hotplug/Linux/systemd/xenconsoled.service
- hotplug/Linux/systemd/xendomains.service
- +hotplug/Linux/systemd/xen-init-dom0.service
- hotplug/Linux/systemd/xenstored.service
- hotplug/Linux/systemd/xenstored.socket
- hotplug/Linux/systemd/xenstored_ro.socket
- @@ -103,13 +104,7 @@
- xen-blkback
- xen-netback
- xen-pciback
- -evtchn
- -gntdev
- -netbk
- -blkbk
- -xen-scsibk
- -usbbk
- -pciback
- +xen-privcmd
- xen-acpi-processor
- blktap2
- blktap
- [tlviewer@c7min unstable]$ cat xen.unstable.tools.rpmball.patch
- --- ./tools/misc/mkrpm.orig 2014-10-12 09:24:32.557981417 -0700
- +++ ./tools/misc/mkrpm 2014-10-13 18:29:42.007707932 -0700
- @@ -33,7 +33,7 @@
- Summary: Xen development build, version $version
- Name: xen$PKG_SUFFIX
- Version: $version
- -Release: $release
- +Release: unstable%{?dist}
- License: GPL
- Group: System/Hypervisor
- URL: http://xenbits.xenproject.org/xen.git
- @@ -53,17 +53,22 @@
- %install
- rm -rf \$RPM_BUILD_ROOT
- mkdir -p \$RPM_BUILD_ROOT
- -cd %{_xenroot}
- -dist/install.sh \$RPM_BUILD_ROOT/
- +(cd %{_xenroot}; dist/install.sh \$RPM_BUILD_ROOT/ )
- -cd \$RPM_BUILD_ROOT
- +echo "%%defattr(-, root, root)" > filelist.lst
- -%clean
- -rm -rf \$RPM_BUILD_ROOT
- +# first get the files
- +(cd %{buildroot}; find . -type f -or -type l | sed -e s/^.// -e /^$/d) >> filelist.lst
- +
- +# docs get gzip
- +sed -i -e '/^\/usr\/share/ s/\.1$/\.1\.gz/' filelist.lst
- +sed -i -e '/^\/usr\/share/ s/\.5$/\.5\.gz/' filelist.lst
- +sed -i -e '/^\/usr\/share/ s/\.8$/\.8\.gz/' filelist.lst
- +
- +# now get the empty folders
- +(cd %{buildroot}; find . -type d -empty | sed -e s/^.// -e 's/^\//%dir \//') >> filelist.lst
- -%files
- -%defattr(-,root,root,-)
- -/*
- +%files -f filelist.lst
- %post
- EOF
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement