Changing ZFS mountpoint?

Discussion in 'Linux & BSD' started by Dark Atheist, May 23, 2009.

  1. Dark Atheist

    Dark Atheist Moderator Political User Folding Team

    Messages:
    6,376
    Location:
    In The Void
    Is it just a simple case of reissuing the mount part, for example this is what i did to make the ZFS tank

    zpool create tank ad6 ad8 ad10
    zfs create tank/store
    zfs set mountpoint=/store tank/store

    im guessing is just a case of me doing

    zfs set mountpoint=/path/to/new/mount/point tank/store

    i dont want to lose what is on there but i need to move the dir
     
  2. Dark Atheist

    Dark Atheist Moderator Political User Folding Team

    Messages:
    6,376
    Location:
    In The Void
    to answer my own question yes you can move it just be using the mount point command, and you don't loose anything :)
     
  3. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
    oooooh earthshattering revelation there :D
     
  4. Dark Atheist

    Dark Atheist Moderator Political User Folding Team

    Messages:
    6,376
    Location:
    In The Void
    is when you have 750gb on there, i suppose to those who know everything there is to know about freebsd is not a great deal
     
  5. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
    Did you ever loose data moving disks to other mount points before? :p
     
  6. Dark Atheist

    Dark Atheist Moderator Political User Folding Team

    Messages:
    6,376
    Location:
    In The Void
    yes i did - that's why i asked, but they were ufs fs not zfs, and i wanted to make really really sure, last time i moved mount points the whole fs went missing, also don't change the tank or you will lose stuff
     
  7. LordOfLA

    LordOfLA Godlike!

    Messages:
    7,027
    Location:
    Maidenhead, Berkshire, UK
    if you lost data moving mountpoints you must have done something wrong.

    You can't loose an entire disk just by editing /etc/fstab...
     
  8. Dark Atheist

    Dark Atheist Moderator Political User Folding Team

    Messages:
    6,376
    Location:
    In The Void
    i know i did something wrong, that's why i made zfs and have left it till now :) if mem serves think i did something with lable but thought i canceled the changes - more then likely i never and thats what caused it, either whay i learnt a lesson there.

    That is all :p