无法在docker ubuntu 16上启动NFS服务器

时间:2017-11-06 13:39:21

标签: docker nfs

我正在尝试使用docker启动NFS服务器。我创建了Dockerfile:

FROM ubuntu:latest
ENV TERM linux
RUN apt-get update
RUN apt-get install --assume-yes \
    software-properties-common wget
RUN apt-get install --assume-yes \
    pkg-config \
    curl jq vim \
    nfs-kernel-server

RUN mkdir /var/nfs/general -p   
RUN chown nobody:nogroup /var/nfs/general

然后我做了以下命令:

sudo docker build -t nfs-ubunta .
sudo docker run --privileged -it nfs-host-ubuntu:latest /bin/bash

我将此行添加到 etc / exports

/var/nfs/general 172.17.0.3(rw,sync,no_subtree_check)
systemctl restart nfs-kernel-server

我得到了这个错误:

Not starting NFS kernel daemon: no support in current kernel. 

输出lsb_release -a

No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.3 LTS
Release:    16.04
Codename:   xenial

0 个答案:

没有答案