Git Product home page Git Product logo

qemu-affinity's People

Contributors

zegelin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

qemu-affinity's Issues

Issue using ryzen and smp

I'm having problem using the script with -k option.
qemu command line :
ExecStart=/usr/bin/qemu-system-x86_64 -daemonize -name %i,debug-threads=on -pidfile /run/qemu_%i.pid -monitor unix:/tmp/%i.sock,server,nowait,nodelay $args
args contain this smp definition: -smp sockets=1,cores=12,threads=1
(note: hyperthreading doesn't work on ryzen/qemu actual version so i'm sticking with single core/threads )
ExecStartPost=/bin/sh -c 'exec /usr/local/bin/qemu-affinity $MAINPID -p 0-1 -i *:0-1 -q 0-1 -w *:0-1 -k 4 5 6 7 8 9 10 11 12 13 14 15'

cpus from 4 to 15 are isolated through isolcpus parameter in kernel.
Journalctl :
Traceback (most recent call last):
lug 17 09:54:11 ryzensrv sh[9839]: File "/usr/local/bin/qemu-affinity", line 11, in
lug 17 09:54:11 ryzensrv sh[9839]: load_entry_point('qemu-affinity==1.0.0', 'console_scripts', 'qemu-affinity')()
lug 17 09:54:11 ryzensrv sh[9839]: File "/usr/local/lib/python3.6/site-packages/qemu_affinity.py", line 239, in main
lug 17 09:54:11 ryzensrv sh[9839]: parser.error('argument %s: too many positional affinity specifications (%d threads, %d provided).' % (argparse._get_action_name(arg), len(threads), spec_count))
lug 17 09:54:11 ryzensrv sh[9839]: TypeError: object of type 'filter' has no len()

Will not run on Linux Mint 19 - needs check for python version and other issues

By default, running qemu-affinity on Linux Mint 19 gets a generic error:

Traceback (most recent call last):
  File "/usr/local/bin/qemu-affinity", line 7, in <module>
    from qemu_affinity import main
  File "/home/haruka/.local/lib/python2.7/site-packages/qemu_affinity.py", line 4, in <module>
    from pathlib import Path
ImportError: No module named pathlib

This is because python 2.7 is the default. qemu-affinity should check the version string before using it, and check for a python3 binary if the python version is not 3 already.

$ python --version
Python 2.7.15rc1
$ python3 --version
Python 3.6.5

However, even setting the opening line of the script to #!/usr/bin/python3 then we still get an error:

$ qemu-affinity --help
Traceback (most recent call last):
  File "/usr/local/bin/qemu-affinity", line 7, in <module>
    from qemu_affinity import main
ModuleNotFoundError: No module named 'qemu_affinity'

But I'm unsure as to why its throwing this error.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.