Ubuntu autofs 設定メモ

/etc/auto.master の編集

auto.master のファイルに諸々の設定があるので編集する.

#
# Sample auto.master file
# This is a 'master' automounter map and it has the following format:
# mount-point [map-type[,format]:]map [options]
# For details of the format look at auto.master(5).
#
/misc   /etc/auto.misc
/mnt/auto       /etc/auto.home --timeout 600 # ここを追加

こうすると /etc/auto.home の情報を拾って /mnt/auto 以下にマウントするようになる.

マウントの設定

上で /etc/auto.home を読むように書いたので /etc/auto.home というファイルをつくって書く.

# server AAA, BBB
AAA_home       -fstype=nfs     -rw,soft,intr   192.168.30.aaa:/raid
BBB_home       -fstype=nfs     -rw,soft,intr   192.168.30.bbb:/raid



設定の反映

sudo service autofs restart

Front page   Edit Diff Attach Copy Rename Reload   New List of pages Search Recent changes   Help   RSS of recent changes
Last-modified: 2022-08-04 (Thu) 09:32:43 (628d)