【需求】
web应用需要部署在两台机器,图片目录共用,MySQL共用。

【环境】
Server: 192.168.168.10
Client: 192.168.168.20

【配置步骤】
1、在两台机器上安装nfs
#yum install nfs-utils rpcbind

2、在Server机器上执行如下命令
#vi /etc/exports
/website/test.com/gallery/ 192.168.168.20/32(rw,sync)

#chkconfig nfs on
#/etc/init.d/rpcbind start
#/etc/init.d/nfs start

3、在Client机器上执行如下命令
#showmount -e 192.168.168.10
#mount -t nfs 192.168.168.10:/website/test.com/gallery/ /website/test.com/gallery/

#vi /etc/rc.d/rc.local
mount -t nfs 192.168.168.10:/website/test.com/gallery/ /website/test.com/gallery/

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-12-17
  • 2021-09-12
猜你喜欢
  • 2021-05-30
  • 2021-07-06
  • 2021-06-10
  • 2021-11-13
  • 2022-01-26
  • 2021-07-09
  • 2021-09-22
相关资源
相似解决方案