ubuntu下配置NFS, tftp服务

1、NFS安装配置
(1)    apt-get install nfs-kernel-server
     apt-get install portmap nfs-common
(2)
    编辑/etc/exports
    /home/administrator/nfsroot  *(rw,sync,no_root_squash)
(3)
    修改挂载点的属性
    chmod 777 /nfsroot
(4)
    重启nfs
    sudo /etc/init.d/nfs-kernel-server restart
    sudo /etc/init.d/portmap restart
5)
    在本机上测试:showmount -e

===================================================
2、安装配置tftp服务
    sudo apt-get install tftp tftpd
    sudo apt-get install netkit-inetd
     sudo apt-get install xinetd
    sudo in.tftpd -l /tftpboot
    在/目录下建一个tftpboot, 把属性改成777。
    cd /
    sudo mkdir tftpboot
    sudo chmod 777 tftpboot
    修改/etc/inetd.conf
    tftp dgram udp wait nobody /usr/sbin/tcpd /usr/sbin/in.tftpd /tftpboot
    重新加载inetd进程
    打开目录 /etc/xinetd.d/新建文件tftp
    sudo /etc/init.d/xinetd reload
    sudo /etc/init.d/xinetd restart
    或
    service xinetd reload
    service xinetd restart
    测试:在/tftpboot文件夹下新建立一个文件:touch aaa
        进入另外一个文件夹
        tftp 192.168.0.101
        tftp> get aaa

 

#使用

#define CALL(f, p)      (printf("Call function %s\n", #f), f(p))

printf("1. ret=%d\n", CALL(square, 3));

 

##使用

#define STRUCT(type) typedef struct _tag_##type type; \
         struct _tag_##type
STRUCT(Student) {};

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值