Git Product home page Git Product logo

zfsmanager's Introduction

ZFS Manager

ZFS administration tool for Webmin

This is in early development, not for production. That being said, try this out in a virtual machine or anywhere else where data is non-critical. My hope is that this will ultimately provide Webmin with similar ZFS functionality to FreeNAS and NAS4Free.

This project lives at https://github.com/jonmatifa/zfsmanager provide all feedback and bug reports there. I am brand new to Perl and Webmin's API. so first I apologize for the shabby state the code is in, second any further contributions are greatly welcomed. I am learning a fair amount about ZFS along the way as well.

I am currently developing this under ZFS on Linux in Ubuntu, but all varients of ZFS/Webmin are planned to be supported in the future.

Installation

You can either use a *.wbm.gz from the releases tab, or "# git clone https://github.com/jonmatifa/zfsmanager.git" from the webmin root directory (Centos/REHL: /usr/libexec/webmin, Debian/Ubuntu: /usr/share/webmin), this will clone everything into the zfsmanager subfolder (which will be created). Then copy the "config" file to /etc/webmin/zfsmanager once that is done, you can then keep up to date with by "# git pull" from the webmin/zfsmanager directory.

Feedback

I am interested in what you think, even during this early alpha phase. The issue tracker can be used not only for bug reports but also feature requests and comments in general. Tracking and fixing bugs is important, but I also want to know what you think about the idea of the project and things like usability and UI design.

Contribution

Right now its just me developing this. I'm not a programmer by trade, but I'm happy to work on this project whenever I can. I would love help from someone more seasoned at perl (don't judge me too hard), but also someone who "gets" the design philosophy of this project and understands the Webmin API. I'm a beginner myself so I'm not looking for too much.

Thank you

Thank you for stopping by and I hope you enjoy this plugin!

zfsmanager's People

Contributors

grunt009 avatar jonmatifa avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

zfsmanager's Issues

**06/14/2017 upgrade notice**

If you are upgrading your zfs manager to the latest git pull (as of June 14th 2017), you may run into some issues displaying the ZFS pools and ZFS filesystems lists correctly, namely you may not get a list that includes any properties, just the names. I made a change that allows for customizing those lists, which means the config file needs to be updated.

You can edit the config at /etc/webmin/zfsmanager/config and add the following two lines:

list_zpool=size,alloc,free,frag,cap,dedup,health
list_zfs=used,avail,refer,mountpoint

Incidentally, you can customize these lists by adding/removing/rearranging comma delimited properties respective for each. It's the equivalent of running the zpool list -o or zfs list -o commands.

Support Rollback function

From discussion in issue #19, there seems to be some interest in a rollback function.

Here's the current manpage description of rollback:

zfs rollback [-rRf] snapshot


           Roll  back the given dataset to a previous snapshot. When a dataset is rolled back, all
 data that has changed since the snapshot is discarded, and the dataset reverts to the state at 
 the time  of  the  snapshot.  By  default,  the  command refuses  to  roll  back to a snapshot 
 other than the most recent one. In order to do so, all intermediate snapshots and bookmarks 
 must be destroyed by specifying the -r option.

           The -rR options do not recursively destroy the child snapshots of a recursive snapshot. 
 Only direct  snapshots  of  the  specified  filesystem  are destroyed by either of these options. 
 To  completely roll back a recursive snapshot, you must  rollback the individual child snapshots.

           -r

               Destroy any snapshots and bookmarks more recent than the one specified.

           -R

               Recursively destroy any more recent snapshots and bookmarks, as well as any 
 clones of those snapshots.

           -f

               Used with the -R option to force an unmount of any clone file systems that are to 
be  destroyed.

This will be relatively straight forward to implement, I just want to be sure the UI gives ample warning of the destructive behavior of rolling back. The key thing for me is that intermediate snapshots must also be destroyed.

Issues with Authentic Webmin Theme

I've been using Cloudmin for a few years, which is also where I happen to do 99% of the development for ZFS Manager and didn't notice until recently Webmin ships with a new default theme, specifically "Authentic".

Right off the bat I've noticed some issues with lists being displayed properly and certain commands not triggering, I'll have to take some time to dive in and figure out what I need to do to ensure compatibility.

In the mean time, a work around can be achieved by switching back to the old theme, "Grey Framed Theme". Go to the Webmin menu, then select Change Language and Theme then click the drop down menu by Webmin UI Theme and select Grey Framed Theme and ensure the radio box is selected for Personal Choice then click Make Changes. Webmin may not display the theme correctly until you do a refresh in your browser.
2017-06-19 23_35_48-cloudmin 9 2 kvm

No list of ZFS Pools

Hi just installed latest via git pull.

Menu appears in my list after I do the work around with user assignment of allowed modules.

But when opening ZFS Manager i just get an empty list.

I have configured the module via "Module Config".

When I create a new pool via "Create new pool" - the pool successfully appears in linux when I run zpool status or zpool list.

So the integration to linux works in that direction - it just seems like something goes wrong when actually reading the current ZFS configuration.

Looking in the HTML code generated its empty as well.

Anything I can do to help diagnose this?

ZFS Install

Sorry Guys new to all of this. Didn't know where to ask these questions.

When you install this in to webmin, does it install the zfs on the system/VM/Device? Also if it doesn't I would need to install it first in the OS correct?

Sorry I know they are stupid questions but I am very new to zfs.

Great Project,
Michael

AWESOME!!!

Ok, I wasn't expecting much when I first installed, but after running it... WOOOOOOWWWW!!!!

Dude... its working PERFECTLY!!!

I was able to create a RAIDZ pool, and it started working right away!!!

Its brilliant!!

Only problem I had was when creating the pool. It failed in webmin with this error:

use '-f' to override the following errors:
/dev/disk/by-id/ata-ST3000DM001-1CH166_Z1F1MHP4 does not contain an EFI label but it may contain partition
information in the MBR.
/dev/disk/by-id/ata-ST3000DM001-1CH166_Z1F1P29W does not contain an EFI label but it may contain partition
information in the MBR.
/dev/disk/by-id/ata-ST3000DM001-1CH166_Z1F1P2EN does not contain an EFI label but it may contain partition
information in the MBR.
/dev/disk/by-id/ata-ST4000DX001-1CE168_Z304TCP8 does not contain an EFI label but it may contain partition
information in the MBR.

When I clicked returned, all my config for the pool was gone.
But no big deal... started over, checked FORCE, but got the same error!!

Turns out the FORCE checkbox didn't change the command line at all.

But because you made it spit out the command line when a error occurs, it was just a matter of copy/paste the command line to a shell, add the -f option and voila!!! It created successfully!!

After that, I returned to webmin and the pool is there!!!

TOP NOTCH JOB MAN!!!

I'll keep testing it thoroughly since I'm deploying a new server which will basically be a ZFS NAS running ARCH linux!!

I'll keep you up to speed!!

thank you so much for making this module, and keep up the good work!!
let me known if you need any help with anything!!

-H

ZFS Manager Boot Environments Support

Hi sorry for use this section for posting in this regard.

I just added Boot Environments support to ZFS Manager, with it you can keep a track/list of currently available BE's with respective info, create new BE's, switch between them(activate), rename and destroy depending on the module configuration.

Is a wrapper for the simple 'beadm' utility and currently working/tested on FreeBSD 11.1 and latest Webmin, however it should work on any OS supporting the 'beadm' package/command.

I will provide here link for the source files, so you can replace files in test environment for testing:

Here is the source:
ZFS Manager Boot Environments Source

Here are some screenshots:
ZFS Manager Boot Environments Screenshot

Regards

EDIT:
Hello, I've build a functional ZFS Manager Module with ZFS Boot Environments Support, targeting FreeBSD users primarily, experimental build below.

ZFS Manager + Boot Environments Support Webmin Module

EDIT-2: Fixed links.

Javascript error

It seems the module doesnt work with webmin version 2.021, im getting this error when clicking to add devices

image

Great Project

Would be interested to see this get to 'production' status. A simple ZFS setup is not too difficult but anything that makes it easier to control all the options has to be a great idea, especially via webmin.

Great Project, love it :)

Hello,
today I just want to let you know: this project is great and fills a major gap in webmin.
Although it is in early state it´s quite useful and has more functions than I expected.
So far I tested all "read only" functions and the results look promising, familiar and correct.
Deleting snapshots also worked well. Will test it on more machines within the next time.
Is there anything one can do to bring this module forward?
Anyway - I like it very much and will stick to it from now on.
Best regards, Stefan

Creating Cron scrub job from GUI/Webmin module

Hi guys,

Is it possible to create a Cron scrub job from within the webmin module?
ZFS only maintains its integrity as a filesystem Manager if scrub jobs are done at least monthly if not weekly.
I know we can establish this frequency in CLI but it would be nice to able to do it from the webmin admin panel?

Thanks

Missing menu link in Hardware

After installation either via git clone or using the webmin plugin file the menu is not found. Also the search does not find it.
The plugin works if you go to it usin a direct link or using the link provided after installation when using the webmin plugin file.

Commands don't return results

On the cmd.cgi page, which references zfsmanager-lib.pl none of the backquote commands seem to produce an output in this context, when they have no problem doing so in the command line.

Zfs import requires -f option

Import when a ZFS pool has not been released from an existing previous host requires the -f command line option.
The import function does not complete when this condition exists.
Forced import should be default or a confirmation option provided.

Create send/receive task

First of all, thank you for your effort to make ZFS more user friendly, despite the CLI of ZFS is quite great.
One of Achilles' heel from ZFS, under my point a view, is the proper automation of the zfs send/receive. I was just looking this with your tool, and something like FreeNAS does: create a snapshot task and a send/receive task which takes the created snapshot and send it to tanother host, using the SSH keys.-

It seems at them moment send tasks are just a downloable gz file, isn't it? It would be great to let it point to another host's ZFS FS. Just a proposal, until then, I will just create some cront tasks, but managing rotation and retention of the snaps on both nodes are quite complex.

Did you consider that?

Cosmetic bug in gpt/name Fix.

Hello, Thanks for this really great project, a definitive must have tool for Webmin nowadays, working so far so good in FreeBSD 11.1 + Webmin 1.881 + Authentic Theme 19.09.2, I use it for monitoring purposes mostly since very simple and sleek looking at.

Found a little cosmetic bug that was changing my GPT/LABEL devices to "|_gpt/hdd-XXXX" instead "gpt/hdd-XXXX", I found on line #31 on "status.cgi" it was causing this issue, seems that removing the "|_" characters in that line fixed the cosmetic "gpt/name" bug instantly, otherwise thanks again for bring this really needed feature to Webmin.

Regards

Spelling error on aclinherit property

Attempting to set zfs property aclinherit to pasthrough on dpool/Movies with command...
zfs set aclinherit=pasthrough dpool/Files

error: cannot set property for 'dpool/Files': 'aclinherit' must be one of 'discard | noallow | restricted | passthrough | passthrough-x'

spellingerror

Cannot select devices when creating pool

When creating a new pool, the available devices (VMWare virtual hdd's), don't show up in zfsmanager. Only a VMWare-virtual cd-rom drive. The disk's have a GPT disklabel with no partitions on them.

When using the command line, I'am able to make a new pool with command:
sudo zpool create -f zfs_pool_1 mirror /dev/sdc /dev/sdd

After that, the new pool does shows up in zfsmanager.

After destroying the pool in zfsmanager, above problem repeat's itself again. Also the destroyed pool cannot be found when importing a pool by searching for destoyed pools.

Using Ubuntu LTS 16.04 as VM under Esxi 6.0 U2 | Webmin 1.870

Cant install Modul on Webmin

Hello,

this day i would test this interface hiere on Proxmox5.1 with Webmin 1.870. But it didn't work. When i install the ... i get this error-message:

Failed to install uploaded module : Module lang is missing a module.info file
What i have to do that the installation is working?

Thanks a lot and best Regards

Error thrown when click a zpool

When trying to enter an existing zpool, the plugin throws the following message:

Undefined subroutine &zfsmanager_master::ui_zpool_status called at /usr/share/webmin/zfsmanager-master/status.cgi line 15.

Failed to install uploaded module : Module zfsmanager does not support this operating system (Sun Solaris 11)

Hi,

thanks so much for creating this module. I've used it with other operating systems and have decided to use Solaris 11.3 for an ESXi NFS datastore. Unfortunately, when I tried to install the ZFS module (which I love), I got this:

Failed to install uploaded module : Module zfsmanager does not support this operating system (Sun Solaris 11)

This looks like it'd be something that would be easy to fix - is there any way you could tell me where to change it so it's accepted?

Thank you,
Avery

Sort snapshots by creation date

This plugin is awesome. I love a complete overview like this.
Easily the best GUI for ZoL I've come across.
I thought it woud be more intuitive to list snapshots by creation date.
In zfsmanager-lib.pl instead of:

zfs list -H -o name,$config{'list_snap'} -t snapshot $snap
You could use:
zfs list -H -o name,$config{'list_snap'} -t snapshot $snap -s creation

I also noticed the rollback button isn't active.
Hasn't that been implemented yet?

I've installed it on Debian 9 in a VM.
But would love to use this on my home server.
Do you think it's stable enough in it's current state?
Are you using it yourself?

Disks reported in wrong vdev

I initially create a pool with 4 disks in a raidz1 vdev. Since then I added another raidz1 vdev with four disks. The interface reported the first vdev fine, however it now shows a disk from the second vdev as being part of the first. Attached the output of zfsmanager and "zpool" status below:
zfsmanager zpoolstatus

Support for pool version 5000

The supported poolversions now only go up to 28. Pool version 5000 is around some time now. How about supporting it in zfsmanger?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.