Skip to content

Commit

Permalink
address #618
Browse files Browse the repository at this point in the history
  • Loading branch information
opcm committed Dec 12, 2023
1 parent bd62564 commit f7be22a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion doc/DOCKER_README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ How To Run Intel(r) Performance Counter Monitor Server Container from GitHub Con
As root user:
1. ``modprobe msr``
2. ``docker run -d --name pcm --privileged -p 9738:9738 ghcr.io/opcm/pcm`` (GitHub Container repository) or ``docker run -d --name pcm --privileged -p 9738:9738 opcm/pcm`` (Dockerhub repository)
- the container can also be run with limited capabilities without the privileged mode: ``docker run -d --name pcm --cap-add=SYS_ADMIN --cap-add=SYS_RAWIO --device=/dev/cpu --device=/dev/mem -v /sys/firmware/acpi/tables/MCFG:/pcm/sys/firmware/acpi/tables/MCFG:ro -v /proc/bus/pci/:/pcm/proc/bus/pci/ -v /proc/sys/kernel/nmi_watchdog:/pcm/proc/sys/kernel/nmi_watchdog -p 9738:9738 ghcr.io/opcm/pcm`` (there is also a docker-compose file containing these options: https://raw.githubusercontent.com/opcm/pcm/master/docker-compose.yml)
- the container can also be run with limited capabilities without the privileged mode: ``docker run -d --name pcm --cap-add=SYS_ADMIN --cap-add=SYS_RAWIO --device=/dev/cpu --device=/dev/mem -v /sys/firmware/acpi/tables/MCFG:/pcm/sys/firmware/acpi/tables/MCFG:ro -v /proc/bus/pci/:/pcm/proc/bus/pci/ -v /proc/sys/kernel/nmi_watchdog:/pcm/proc/sys/kernel/nmi_watchdog -v /sys:/sys:rw -p 9738:9738 ghcr.io/opcm/pcm`` (there is also a docker-compose file containing these options: https://raw.githubusercontent.com/opcm/pcm/master/docker-compose.yml)

This will start pcm-sensor-server container exposing CPU metrics from the whole system at port 9738

Expand Down
1 change: 1 addition & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ services:
- "/sys/firmware/acpi/tables/MCFG:/pcm/sys/firmware/acpi/tables/MCFG:ro"
- "/proc/bus/pci/:/pcm/proc/bus/pci/"
- "/proc/sys/kernel/nmi_watchdog:/pcm/proc/sys/kernel/nmi_watchdog"
- "/sys:/sys:rw"
cap_add:
- SYS_ADMIN
- SYS_RAWIO
Expand Down

0 comments on commit f7be22a

Please sign in to comment.