1825771 Members
2160 Online
109687 Solutions
New Discussion

Re: fstab syntax

 
David L Wright
New Member

fstab syntax

It is possible to mount a directory from one local file system over another? Like this:

mount /11b/data/iman/idsm_tmp /tmp/idsm_tmp

My question is how do I enter this in the fstab so that it mounts when the server reboots. OS is 11.11.

NOTE: The application using this directory doesn't like links.

Thanks,
David
5 REPLIES 5
Mike Shilladay
Esteemed Contributor

Re: fstab syntax

Hi David,

You can, you would need to make sure that the first directory is mounted before the second is attempted.

So for example:

/dev/vg01/dir1
/dev/vg01/dir1/dir2

Would have entries in the fstab file something like this:

/dev/vg01/lvol1 /dir1 vxfs delaylog 0 2
/dev/vg01/lvol2 /dir1/dir2 vxfs delaylog 0 2

Mike.
David L Wright
New Member

Re: fstab syntax

Thanks for the reply Mike. I found the syntax I was looking for by doing the mount and then looking at the /etc/mnttab and copying that syntax to the /etc/fstab. This is working. Per your suggestion, I will make this the last entry in the /etc/fstab.

Syntax used:

/11b/data/iman/idsm_tmp /tmp/idsm_tmp lofs defaults 0 0
David L Wright
New Member

Re: fstab syntax

See my last post for the solution.
Dennis Handly
Acclaimed Contributor

Re: fstab syntax

Instead of doing complicated stuff like mounts, you can simply create a symlink from one directory to the other.
Dennis Handly
Acclaimed Contributor

Re: fstab syntax

>The application using this directory doesn't like links.

Oops, I just saw this. How does the application know there is a link?
This implies the application is trying to be too clever and is not clever enough.

You of course can create a directory hardlink (if in the same filesystem) to fight stupidity with even more. :-)