mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-23 10:54:35 +03:00
Add zfs_prepare_disk script for disk firmware install
Have libzfs call a special `zfs_prepare_disk` script before a disk is included into the pool. The user can edit this script to add things like a disk firmware update or a disk health check. Use of the script is totally optional. See the zfs_prepare_disk manpage for full details. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Tony Hutter <hutter2@llnl.gov> Closes #15243
This commit is contained in:
committed by
Brian Behlendorf
parent
35252ae0fd
commit
11574a7934
@@ -318,6 +318,15 @@ extern nvlist_t *zpool_find_vdev(zpool_handle_t *, const char *, boolean_t *,
|
||||
extern nvlist_t *zpool_find_vdev_by_physpath(zpool_handle_t *, const char *,
|
||||
boolean_t *, boolean_t *, boolean_t *);
|
||||
extern int zpool_label_disk(libzfs_handle_t *, zpool_handle_t *, const char *);
|
||||
extern int zpool_prepare_disk(zpool_handle_t *zhp, nvlist_t *vdev_nv,
|
||||
const char *prepare_str, char **lines[], int *lines_cnt);
|
||||
extern int zpool_prepare_and_label_disk(libzfs_handle_t *hdl,
|
||||
zpool_handle_t *, const char *, nvlist_t *vdev_nv, const char *prepare_str,
|
||||
char **lines[], int *lines_cnt);
|
||||
extern char ** zpool_vdev_script_alloc_env(const char *pool_name,
|
||||
const char *vdev_path, const char *vdev_upath,
|
||||
const char *vdev_enc_sysfs_path, const char *opt_key, const char *opt_val);
|
||||
extern void zpool_vdev_script_free_env(char **env);
|
||||
extern uint64_t zpool_vdev_path_to_guid(zpool_handle_t *zhp, const char *path);
|
||||
|
||||
const char *zpool_get_state_str(zpool_handle_t *);
|
||||
|
||||
Reference in New Issue
Block a user