1 / 9

第十二章 访问网络文件共享服务

第十二章 访问网络文件共享服务. 本章内容. NFS 网络文件系统 配置 NFS 服务 自动挂载网络存储服务. 挂载网络文件系统. 网络文件系统是由网络附加存储服务器通过网络向多个主机提供的一种文件系统,客户端通过特殊的文件系统协议和格式访问远程存储。 访问网络文件系统的协议: NFS( Network File System) CIFS( Common Internet File System). 访问网络共享的基本步骤. 识别要访问的远程共享 确定挂载点,并创建挂载点的空目录 通过相应的命令或配置更改挂载网络文件系统. 挂载网络文件系统.

saber
Télécharger la présentation

第十二章 访问网络文件共享服务

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. 第十二章 访问网络文件共享服务

  2. 本章内容 • NFS网络文件系统 • 配置NFS服务 • 自动挂载网络存储服务

  3. 挂载网络文件系统 • 网络文件系统是由网络附加存储服务器通过网络向多个主机提供的一种文件系统,客户端通过特殊的文件系统协议和格式访问远程存储。 • 访问网络文件系统的协议: • NFS( Network File System) • CIFS( Common Internet File System)

  4. 访问网络共享的基本步骤 • 识别要访问的远程共享 • 确定挂载点,并创建挂载点的空目录 • 通过相应的命令或配置更改挂载网络文件系统

  5. 挂载网络文件系统 • 访问 NFS 导出的命令 • 1.showmount –e nfsserver.domain • 2.mkdir /remote1 • 3.mount nfsserver.domain:/exported/path /remote1 • 访问 CIFS 共享的命令 • 1.smbclient –L cifsserver.domain –U user1 • 2.mkdir /remote2 • 3.mount //cifsserver.domain/sharename /remote2 –o username=user1

  6. 练习 • 1. 验证 /var/ftp/pub 是否为服务器 instructor.example.com上的可用NFS共享. • 2. 创建目录 /server 用作挂载点. • 3. 设置并执行命令,以将NFS共享挂载到挂载点. • 4. 列出挂载点的内容,以验证这是否为 instructor.example.com上的NFS共享 • 5. 解除挂载共享将其清除

  7. 自动挂载网络存储 • 当某一程序试图访问网络共享中的文件时,可以将 automounter (autofs)服务配置为按需挂载 • 当共享不再使用并处于不活动状态一定时间后,automounter会对共享解除挂载

  8. 自动挂载 • 1. 特殊映射 /net • 默认情况下,autofs服务运行时,/net目录映射服务器上的所有共享 • 2. 间接映射 • 修改/etc/auto.master: /server /etc/auto.server • 创建 /etc/auto.server文件 public -ro 192.168.0.254:/exported/path • 直接访问/server/public目录

  9. 实验:自动挂载NFS共享 • 需求描述 • 您的公司有一个新NFS服务器instructor.example.com,它的共享用于存储与“特殊”客户有关的文件 • 此客户的共享为:/var/nfs/oshu • 配置您的工作站,以使autofs自动将该共享作为/special/oshu挂载 • 列出/special/oshu的内容,确认您看到以下文件: • supertopsecret.txt • ultrashh.txt

More Related