1. 16 10月, 2013 1 次提交
  2. 14 10月, 2013 3 次提交
    • D
      Initialize threading & error layer in LXC controller · 97973ebb
      Daniel P. Berrange 提交于
      In Fedora 20, libvirt_lxc crashes immediately at startup with a
      trace
      
       #0  0x00007f0cddb653ec in free () from /lib64/libc.so.6
       #1  0x00007f0ce0e16f4a in virFree (ptrptr=ptrptr@entry=0x7f0ce1830058) at util/viralloc.c:580
       #2  0x00007f0ce0e2764b in virResetError (err=0x7f0ce1830030) at util/virerror.c:354
       #3  0x00007f0ce0e27a5a in virResetLastError () at util/virerror.c:387
       #4  0x00007f0ce0e28858 in virEventRegisterDefaultImpl () at util/virevent.c:233
       #5  0x00007f0ce0db47c6 in main (argc=11, argv=0x7fff4596c328) at lxc/lxc_controller.c:2352
      
      Normally virInitialize calls virErrorInitialize and
      virThreadInitialize, but we don't link to libvirt.so
      in libvirt_lxc, and nor did we ever call the error
      or thread initializers.
      
      I have absolutely no idea how this has ever worked, let alone
      what caused it to stop working in Fedora 20.
      
      In addition not all code paths from virLogSetFromEnv will
      ensure virLogInitialize is called correctly, which is another
      possible crash scenario.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      97973ebb
    • D
      Fix exit status of lxc controller · 13c011c3
      Daniel P. Berrange 提交于
      The LXC controller main() method initialized 'rc' to 1
      rather than '-1'. In the cleanup path it will print any
      error to stderr, if-and-only-if rc < 0. Hence the incorrect
      initialization caused errors to be lost.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      13c011c3
    • D
      Make LXC controller use a private dbus connection & close it · ae9a0485
      Daniel P. Berrange 提交于
      The LXC controller uses dbus to talk to systemd to create
      cgroups. This means that each LXC controller instance has
      a dbus connection. The DBus daemon is limited to 256
      connections by default and we want to be able to run many
      1000 of containers.
      
      While the dbus limit could be raised in the config files,
      it is simpler to make libvirt LXC controller close its
      dbus connection once everything is configured.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      ae9a0485
  3. 27 9月, 2013 2 次提交
  4. 05 8月, 2013 1 次提交
    • M
      Introduce max_queued_clients · 1199edb1
      Michal Privoznik 提交于
      This configuration knob lets user to set the length of queue of
      connection requests waiting to be accept()-ed by the daemon. IOW, it
      just controls the @backlog passed to listen:
      
        int listen(int sockfd, int backlog);
      1199edb1
  5. 25 7月, 2013 1 次提交
  6. 24 7月, 2013 1 次提交
    • D
      Create + setup cgroups atomically for LXC process · da704c87
      Daniel P. Berrange 提交于
      Currently the LXC driver creates the VM's cgroup prior to
      forking, and then libvirt_lxc moves the child process
      into the cgroup. This won't work with systemd whose APIs
      do the creation of cgroups + attachment of processes atomically.
      
      Fortunately we simply move the entire cgroups setup into
      the libvirt_lxc child process. We make it take place before
      fork'ing into the background, so by the time virCommandRun
      returns in the LXC driver, the cgroup is guaranteed to be
      present.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      da704c87
  7. 22 7月, 2013 2 次提交
  8. 18 7月, 2013 2 次提交
  9. 16 7月, 2013 5 次提交
  10. 11 7月, 2013 1 次提交
  11. 10 7月, 2013 1 次提交
  12. 09 7月, 2013 1 次提交
  13. 02 7月, 2013 7 次提交
  14. 06 6月, 2013 1 次提交
  15. 21 5月, 2013 4 次提交
  16. 13 5月, 2013 2 次提交
  17. 09 5月, 2013 1 次提交
  18. 02 5月, 2013 1 次提交
    • M
      virutil: Move string related functions to virstring.c · 7c9a2d88
      Michal Privoznik 提交于
      The source code base needs to be adapted as well. Some files
      include virutil.h just for the string related functions (here,
      the include is substituted to match the new file), some include
      virutil.h without any need (here, the include is removed), and
      some require both.
      7c9a2d88
  19. 20 4月, 2013 1 次提交
    • E
      docs: fix usage of 'onto' · 1bf25ba2
      Eric Blake 提交于
      http://www.uhv.edu/ac/newsletters/writing/grammartip2009.07.01.htm
      (and several other sites) give hints that 'onto' is best used if
      you can also add 'up' just before it and still make sense. In many
      cases in the code base, we really want the two-word form, or even
      a simplification to just 'on' or 'to'.
      
      * docs/hacking.html.in: Use correct 'on to'.
      * python/libvirt-override.c: Likewise.
      * src/lxc/lxc_controller.c: Likewise.
      * src/util/virpci.c: Likewise.
      * daemon/THREADS.txt: Use simpler 'on'.
      * docs/formatdomain.html.in: Better usage.
      * docs/internals/rpc.html.in: Likewise.
      * src/conf/domain_event.c: Likewise.
      * src/rpc/virnetclient.c: Likewise.
      * tests/qemumonitortestutils.c: Likewise.
      * HACKING: Regenerate.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      1bf25ba2
  20. 16 4月, 2013 1 次提交
  21. 09 4月, 2013 1 次提交
    • B
      Implement support for <hostdev caps=net> · 442d6a05
      Bogdan Purcareata 提交于
      This allows a container-type domain to have exclusive access to one of
      the host's NICs.
      
      Wire <hostdev caps=net> with the lxc_controller - when moving the newly
      created veth devices into a new namespace, also look for any hostdev
      devices that should be moved. Note: once the container domain has been
      destroyed, there is no code that moves the interfaces back to the
      original namespace. This does happen, though, probably due to default
      cleanup on namespace destruction.
      Signed-off-by: NBogdan Purcareata <bogdan.purcareata@freescale.com>
      442d6a05