Skip to content

Kubernetes device plugin supporting FPGA and other accelerators

License

Notifications You must be signed in to change notification settings

cqbqdd11519/Accelerator-K8S

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Accelerator-K8S

Accelerator-K8S is a device plugin works with Accelerator-Docker

Getting Started

Dependencies

Installation

  • Deploy as a daemonset (Recommended)
kubectl create -f https://raw.githubusercontent.com/KAIST-NCL/Accelerator-K8S/master/acc-k8s.yml

OR

  • Install manually by cloning and building
$ git clone https://github.com/KAIST-NCL/Accelerator-K8S.git
$ cd Accelerator-K8S
$ make
$ sudo make install

$ out/acc-k8s

for every node

How to Use

Prerequisites

First, you need to make sure that you installed Accelerator-Docker properly.

  • default-runtime of docker daemon should be set to acc-runtime. Check /etc/docker/daemon.json
  • In Accelerator-Docker setting(/etc/accelerator-docker/device.pbtxt), accelerator type should be named following kubernetes resourece naming rule. Refer to this.

Enabling Accelerators in Containers

You can require your accelerators as a resource like below:

apiVersion: v1
kind: Pod
metadata:
  name: demo-pod
spec:
  containers:
    - name: demo-container
      image: ubuntu:16.04
      resources:
        limits:
          {ACCELERATOR_TYPE}: 1

'Accelerator type' is configured in Accelerator-Docker configuration file and you can check it by using acc-manager list command

  • Example)
$ acc-manager list
+------------+--------------+------------------------+----------------+----------------+----------+
|     ID     |     Name     |          Type          |    PCI-Slot    |     Status     |  Holder  |
+------------+--------------+------------------------+----------------+----------------+----------+
| 234750     | QuadroM2000  | nvidia.com/gpu         | 0000:02:00.0   | Available      | 0        |
| 1121730    | KCU-1500     | xilinx.fpga/kcu-1500   | 0000:01:00.0   | Available      | 0        |
+------------+--------------+------------------------+----------------+----------------+----------+

If you want to use KCU-1500 for your pod, you can set container limit as follows.

  containers:
    - name: demo-container
      image: ubuntu:16.04
      resources:
        limits:
          xilinx.fpga/kcu-1500: 1

Authors

KAIST NCL

License

This project is released under the BSD-3-Clause, see LICENSE for more information.

Acknowledgement

This work was supported by 'The Cross-Ministry Giga KOREA Project' grant funded by the Korea government (MSIT) (No.GK19P0400, Development of Mobile Edge Computing Platform Technology for URLLC Services)

About

Kubernetes device plugin supporting FPGA and other accelerators

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 92.1%
  • Makefile 4.7%
  • Dockerfile 3.2%