Thanks Senthil
             But still its not working with Lava job. Can we debug LXC-instance  with more logs. 

On Wed, Jul 26, 2017 at 3:36 PM, Senthil Kumaran S <senthil.kumaran@linaro.org> wrote:


On Wednesday 26 July 2017 02:31 PM, Chetan Sharma wrote:
> Default Configuration file path is :  /etc/lxc/default.conf
> Entry is :-
>       lxc.mount.entry = /var/lib/nfsdir var/nfsmnt none bind,create=dir 0 0

You are missing a forward slash before 'var/nfsmnt' above.
[chetan]  No Senthil, we need not to provide forward slash,  as its defined in this version of lxc. 
                   https://wiki.debian.org/LXC#bind_mounts_inside_the_container  
 
> After restart lxc service. I executed lava job then this directory

How did you restart lxc service?

   [chetan] /etc/init.d/lxc-net restart,  /etc/init.d/lxc restart
 
> "/var/lib/nfsdir" of worker machine is not mounting on LXC instance in
> directory "/var/nfsmnt".

   [chetan] directory is created automatically on LXC instance with name /var/nfsmnt but content of worker machine directory is not synced/mounted in this directory. 
 
A fresh LXC created and started during the job execution will not have
the directory /var/nfsmnt hence it will not work.

You may try 'mkdir /var/nfsmnt; mount /var/nfsmnt' before accessing the
directory.
   [chetan] this step is not required.  I have followed these steps simply with additional parameters. 
    https://wiki.debian.org/LXC#bind_mounts_inside_the_container 
 
> But if i manually create and start lxc instance on worker, then this
> directory "/var/lib/nfsdir" of worker machine is mounted on LXC instance.

What are the things you did after starting lxc? Did you create
'/var/nfsmnt' directory?
[chetan] I just did config change and created a new lxc instance with name lxc-ubuntu and then start instance. By attaching to instance, i am able to access /var/nfsmnt path on LXC. 

 
Thank You.
--
Senthil Kumaran S
http://www.stylesen.org/
http://www.sasenthilkumaran.com/




--
Thanks & Regards
 Chetan Sharma