Why automount inside a container hosted on Red Hat Enterprise Linux 7 is not working ?

Solution Unverified - Updated -

Issue

  • Why automount inside a container hosted on Red Hat Enterprise Linux 7 is not working ?
  • Why autofs directories are not getting mounted automatically in LXC container ?
# echo '* -fstype=nfs 192.168.0.1:/vol/home_shared/&' > /etc/auto.home
# echo "/home /etc/auto.home" >> /etc/auto.master
# systemctl enable autofs.service
# systemctl start autofs.service
# cd /home/user    <------- hangs

Environment

  • Red Hat Enterprise Linux 7.1
  • Docker 1.8
  • lxc container using libvirt-lxc plugin

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content