FreeBSD Bugzilla – Attachment 204525 Details for
Bug 237517
ZFS parallel mounting sometimes misses mounting intermediate filesystems
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
Script to parallel-mount zfs filesystems (uses "parallel")
zfs-speedmount (text/plain), 1009 bytes, created by
Peter Eriksson
on 2019-05-21 22:19:26 UTC
(
hide
)
Description:
Script to parallel-mount zfs filesystems (uses "parallel")
Filename:
MIME Type:
Creator:
Peter Eriksson
Created:
2019-05-21 22:19:26 UTC
Size:
1009 bytes
patch
obsolete
>#!/bin/bash ># ># zfs-speedmount ># ># Parallel mounting of all available zfs filesystems ># ># Author: Mikael Haglund <mikael.haglund@liu.se> ># > >###### > >export PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/root/bin >fs_raw="" >fs_ordered="" > >function get_pool_filesystems() >{ > IFS=" > " > tmp_fs=$(zfs list -r -t filesystem -H -o name,mountpoint $1 | awk '{print $1":"$2}') > fs_raw="$fs_raw > $tmp_fs" >} > >function get_pools() >{ > pools=$(zpool list -H -o name) > echo $pools >} > >function orderfs() >{ > fs_ordered=$(echo "$fs_raw" | awk -F":" '{print gsub(/\//,"/",$2)":"$1}' ) >} > >function mountfs() >{ > for i in $(echo "$fs_ordered" | awk -F":" '{print $1}' | sort | uniq ); do > echo "$fs_ordered" | grep -E "^$i:" | cut -f 2 -d ":" | sed -e "s/[[:blank:]]//g" | /usr/local/bin/parallel --will-cite -j 40 zfs mount {} > sleep 5 > done >} > > >get_all_filesystems() >{ > fs="" > for pool in $(get_pools); do > get_pool_filesystems $pool > done > orderfs > mountfs >} > >get_all_filesystems >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 237517
:
204479
|
204484
|
204504
|
204524
| 204525 |
204788
|
205830
|
205857