我正在尝试挂载 zfs 快照。应该很简单……但我做不到。我使用的是 Ubuntu Server 11.10 Oneric,内核 3.0.0-15-server。
从ppa安装 ZFS我也在使用 zfs-auto-snapshot。与手动创建快照的情况相同。
如何挂载 zfs 快照?
root@us1:/# zfs list -t snapshot
NAME USED AVAIL REFER MOUNTPOINT
tank/www@zfs-auto-snap_hourly-2012-02-11-1917 0 - 268K -
root@us1:/# zfs mount tank/www@zfs-auto-snap_hourly-2012-02-11-1917 /mnt/snapshot/tank/www
too many arguments
usage:
mount
mount [-vO] [-o opts] <-a | filesystem>
For the property list, run: zfs set|get
For the delegated permission list, run: zfs allow|unallow
root@us1:/# zfs mount tank/www@zfs-auto-snap_hourly-2012-02-11-1917
cannot open 'tank/www@zfs-auto-snap_hourly-2012-02-11-1917': operation not applicable to datasets of this type
Run Code Online (Sandbox Code Playgroud)
ben*_*lor 32
截至今天,Linux (ZoL) 上的 ZFS 现在还支持通过数据集根目录中的不可见(非隐藏、不可见)目录对快照进行只读访问。
# ls -a /tank/test
./ ../ boot.tar text.tar text.tar.2
# cd /tank/test/.zfs/
# ls -a
./ ../ shares/ snapshot/
Run Code Online (Sandbox Code Playgroud)
在该snapshot目录中,您将找到所有快照的只读副本。
您可以.zfs通过zfs set snapdir=visible tank/test.
来源:https : //pthree.org/2012/12/19/zfs-administration-part-xii-snapshots-and-clones/
Dar*_*orn 28
运行 ZoL,只需像这样使用常规的 mount 命令:
mount -t zfs tank/www@zfs-auto-snap_hourly-2012-02-11-1917 /mnt/snapshot/tank/www
Run Code Online (Sandbox Code Playgroud)
像这样卸载它:
umount /mnt/snapshot/tank/www
Run Code Online (Sandbox Code Playgroud)
这是一个正在跟踪的错误https://github.com/zfsonlinux/zfs/issues/173
| 归档时间: |
|
| 查看次数: |
40143 次 |
| 最近记录: |