Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#746 Unable to create ZFS Datasets with . or / in the name

v0.7
closed
zoon01
WebGUI (143)
5
2014-10-31
2010-01-18
Graham Inggs
No

Attempting to create a ZFS Dataset using the WebGUI containing a '.' or '/' character results in the following error:
[quote]The following input errors were detected:

* The attribute 'Name' may only consist of the characters a-z, A-Z, 0-9.[/quote]

ZFS Datasets can be created without error using SSH, for example:
[quote]zfs create pool0/staff/first.last[/quote]

Discussion

  • Graham Inggs
    Graham Inggs
    2010-01-18

    I found that changing the following lines in /usr/local/www/disks_zfs_dataset_edit.php:

    // Input validation
    $reqdfields = explode(" ", "name");
    $reqdfieldsn = array(gettext("Name"));
    $reqdfieldst = explode(" ", "alias");
    

    to read:

    // Input validation
    $reqdfields = explode(" ", "name");
    $reqdfieldsn = array(gettext("Name"));
    $reqdfieldst = explode(" ", "string");
    

    allows me to create ZFS Datasets using the WebGUI, until the next reboot.

     
  • Steven King
    Steven King
    2010-01-19

    Ginggs is correct. You should be able to create Datasets with a period '.'. However / is not technically part of the name but creates a new nested file system. But, if the parent does not exist for the Dataset zfs create will error out and let you know about that. So care must be taken to ensure the Dataset exists as well so the command does not fail.

     
  • zoon01
    zoon01
    2010-10-28

    Ginggs thanks,
    changes are committed to the svn (rev:5514).

    Regards,
    Michael Zoon