[pve-devel] [PATCH] zfs: auto import after reboot
Dietmar Maurer
dietmar at proxmox.com
Mon Feb 9 12:07:51 CET 2015
On 02/03/2015 12:59 PM, Wolfgang Link wrote:
> @@ -419,6 +419,14 @@ sub volume_snapshot_rollback {
>
> sub activate_storage {
> my ($class, $storeid, $scfg, $cache) = @_;
> +
> + my @param = ('-o', 'name', '-H');
> +
> + my $text = zfs_request($class, $scfg, undef, 'zpool_list', @param);
> +
> + if ($text !~ $scfg->{pool}) {
> + run_command("zpool import -d /dev/disk/by-id/ -a");
> + }
> return 1;
> }
>
activate_storage is inherted by ZFSPlugin, so we cannot do that! So please
overwrite it inside ZFSPlugin.pm.
More information about the pve-devel
mailing list