ZFS mount point - problem
807557Jun 26 2009 — edited Jul 10 2009Hi,
We are using ZFS to take the sanpshots in our solaris 10 servers. I have the problem when using ZFS mount options.
The solaris server we are used as,
SunOS emch-mp89-sunfire 5.10 Generic_127127-11 sun4u sparc SUNW,Sun-Fire-V440Sys
tem = SunOS
Steps:
1. I have created the zfs pool named as lmspool
2. Then created the file system lmsfs
3. Now I want to set the mountpoint for this ZFS file system (lmsfs) as "/opt/database" directory (which has some .sh files).
4. Then need to take the snapshot of the lmsfs filesystem.
5. For the mountpoint set, I tried two ways.
1. zfs set mountpoint=/opt/database lmspool/lmsfs
it returns the message "cannot mount '/opt/database/': directory is not empty
property may be set but unable to remount filesystem".
If I run the same command in second time, the mount point set properly and then I taken the snapshot of the ZFS filesystem (lmsfs). After done some modification in the database directory (delete some files), then I rollback the snapshot but the original database directory was not recovered. :-(
2. In second way, I used the "legacy" option for mounting.
# zfs set mountpoint=legacy lmspool/lmsfs
# mount -F zfs lmspool/lmsfs /opt/database
After run this command, I cant able to see the files of the database directory inside the /opt. So I cant able to modify anything inside the /opt/database directory.
Please someone suggest me the solution for this problem. or anyother ways to take the ZFS snapshot with mounting point in UFS file system?..
Thanks,
Muthukrishnan G