В этой папке есть несколько подпапок, которые должны быть видны на клиентах.
Я хочу использовать autofs для монтирования на клиентах по следующему пути:
/opt/netapps/
Это я могу сделать, но когда я это делаю, папка / opt становится непригодной для использования, потому что с ней что-то делает автомонтировщик. Я не могу создать новую подпапку для / opt или сделать что-нибудь на самом деле ... Я получаю «Отказано в доступе» для всего ... как root!
Что я сделал не так? Как мне это решить? У кого-нибудь есть идея, пожалуйста?
2 ответа на вопрос
0
Lars Rohrbach
Your current opt.autofs file basically tells autofs to take control of the /opt directory, so that it can build arbitrary mountpoints there for automounting. I would recommend that you instead create and use a directory where you can allow autofs to be in full control -- something like /opt/auto (so you would end up using /opt/auto/netapps), or perhaps /remote (so you would end up using /remote/netapps).
For the former choice, you could simply change your /opt.autofs file:
/opt/auto file:/etc/auto.opt --timeout 10
0
Sathish
The problem is with your map file (auto.opt) having incorrect export location (/exports/netapps)
cat /etc/auto.master ....omitted lines..... /misc /etc/auto.misc /opt /etc/auto.opt --timeout 10 ....omitted lines..... cat /etc/auto.opt netapps -ro,nfsvers=3 lwp16.service.rug.nl:/exports/netapps service nfs restart service autofs stop service autofs start
Also you may experience name resolution issues due to dns may cause this issue. In that case try ip address in your map file (ip-addr-nfs-server:/exports/netapps).
By default, nfs is mounted with version4 if none specified as mount options.