Topic
  • 7 replies
  • Latest Post - ‏2019-05-29T10:36:54Z by nenifled
nenifled
nenifled
5 Posts

Pinned topic Unmirror a filesystem

‏2019-05-22T09:46:21Z | mmchdisk mmchfs mmchnsd replicas tiebreaker

Hello 

I have a filesystem created with this command:

mmcrfs gpfs01    -F discdesc_start -A yes -B 8M -i 4096 -m 2 -M 2 -r 2 -R 2 -K whenpossible -S relatime -T /tsm/back       --metadata-block-size 256K 

Because I have -m 2 and -r 2 I have two copies of data.

I changed my mind! I don't want two copies anymore :-)

How do I do that? The filesystem is in production...so I want to be safe with the commands :-)

Is it this command:

mmchfs gpfs01 -m 1 -r 1

 

I have two different faileregroups and one tiebreaker disk....I want to delete all the disks in faileregroup two and ofcause the tiebreaker disk

  • oester
    oester
    259 Posts
    ACCEPTED ANSWER

    Re: Unmirror a filesystem

    ‏2019-05-22T12:10:52Z  
    • nenifled
    • ‏2019-05-22T12:01:44Z

    Thanks - but what do I do with the failuregroups - where will data go, when I remove the "mirror"? To the first failuregroup? How will I get rid of the tiebreaker disk....

    This is a two step process:

     

    1) mmchfs <filesystem> -m 1 -r 1 (this changes the default number of replicas to 1, the max stays at 2 in case you change your mind again)

    2) mmrestripefs <filesystem> -R (this removes the replicas for data/metadata - IO intensive)

     

    When you drop back to 1 replica, the data/metadata on one of the failure groups is removed (I don't recall which). After the "mmrestripefs -R" finishes, you'll (probably) want to rebalance the data/metadata using something like "mmrestripefs -b" but before you'd do that I would look at the utilization on the NSDs (mmdf) and see where the data was removed. 

     

    Bob Oesterlin

    Nuance Communications

  • truongv
    truongv
    103 Posts

    Re: Unmirror a filesystem

    ‏2019-05-22T11:05:17Z  

    Yes, -m and -r are the correct options to change the default meta and data replicas, respectively.

  • nenifled
    nenifled
    5 Posts

    Re: Unmirror a filesystem

    ‏2019-05-22T12:01:44Z  
    • truongv
    • ‏2019-05-22T11:05:17Z

    Yes, -m and -r are the correct options to change the default meta and data replicas, respectively.

    Thanks - but what do I do with the failuregroups - where will data go, when I remove the "mirror"? To the first failuregroup? How will I get rid of the tiebreaker disk....

  • oester
    oester
    259 Posts

    Re: Unmirror a filesystem

    ‏2019-05-22T12:10:52Z  
    • nenifled
    • ‏2019-05-22T12:01:44Z

    Thanks - but what do I do with the failuregroups - where will data go, when I remove the "mirror"? To the first failuregroup? How will I get rid of the tiebreaker disk....

    This is a two step process:

     

    1) mmchfs <filesystem> -m 1 -r 1 (this changes the default number of replicas to 1, the max stays at 2 in case you change your mind again)

    2) mmrestripefs <filesystem> -R (this removes the replicas for data/metadata - IO intensive)

     

    When you drop back to 1 replica, the data/metadata on one of the failure groups is removed (I don't recall which). After the "mmrestripefs -R" finishes, you'll (probably) want to rebalance the data/metadata using something like "mmrestripefs -b" but before you'd do that I would look at the utilization on the NSDs (mmdf) and see where the data was removed. 

     

    Bob Oesterlin

    Nuance Communications

  • nenifled
    nenifled
    5 Posts

    Re: Unmirror a filesystem

    ‏2019-05-22T12:53:43Z  
    • oester
    • ‏2019-05-22T12:10:52Z

    This is a two step process:

     

    1) mmchfs <filesystem> -m 1 -r 1 (this changes the default number of replicas to 1, the max stays at 2 in case you change your mind again)

    2) mmrestripefs <filesystem> -R (this removes the replicas for data/metadata - IO intensive)

     

    When you drop back to 1 replica, the data/metadata on one of the failure groups is removed (I don't recall which). After the "mmrestripefs -R" finishes, you'll (probably) want to rebalance the data/metadata using something like "mmrestripefs -b" but before you'd do that I would look at the utilization on the NSDs (mmdf) and see where the data was removed. 

     

    Bob Oesterlin

    Nuance Communications

    I have issued the first command:

    mmchfs gpfs01 -m 1 -r 1

    I will see if the disks are evenly used tomorrow - maybe GPFS will choose one of the failure groups....

    I now get this "error" - but that makes sense:

    GPFS: 6027-740 Attention: Due to an earlier configuration change the file system is no longer properly replicated.

     

    Tomorrow I think I will restripe - I think I might set all the disks in failure group two "down" - to be sure GPFS is not moving to the wrong disks. My filesystem is quite big - so I would love not to move data to the wrong disks.

    Hmmm - but all data on the filesystem is changed every 6 days - so maybe I should just wait 7 days....and my filesystem is automatically restriped... :-)

     

  • oester
    oester
    259 Posts

    Re: Unmirror a filesystem

    ‏2019-05-22T12:57:56Z  
    • nenifled
    • ‏2019-05-22T12:53:43Z

    I have issued the first command:

    mmchfs gpfs01 -m 1 -r 1

    I will see if the disks are evenly used tomorrow - maybe GPFS will choose one of the failure groups....

    I now get this "error" - but that makes sense:

    GPFS: 6027-740 Attention: Due to an earlier configuration change the file system is no longer properly replicated.

     

    Tomorrow I think I will restripe - I think I might set all the disks in failure group two "down" - to be sure GPFS is not moving to the wrong disks. My filesystem is quite big - so I would love not to move data to the wrong disks.

    Hmmm - but all data on the filesystem is changed every 6 days - so maybe I should just wait 7 days....and my filesystem is automatically restriped... :-)

     

    You'll see that error until you do the restripe - the extra replicas will not be removed until you restripe the file system.

     

    Bob

  • nenifled
    nenifled
    5 Posts

    Re: Unmirror a filesystem

    ‏2019-05-24T11:11:53Z  
    • oester
    • ‏2019-05-22T12:57:56Z

    You'll see that error until you do the restripe - the extra replicas will not be removed until you restripe the file system.

     

    Bob

    I have suspended my disks:

    mmchdisk /dev/gpfsbad suspend -d data_disk_001

    mmchdisk /dev/gpfsbad suspend -d data_disk_002

    mmchdisk /dev/gpfsbad suspend -d data_disk_003

     

    ..and of cause they are now used less. Before I suspended them - there was no difference in the usability as far as I could see.

    Next week I will restripe and delete disks.

  • nenifled
    nenifled
    5 Posts

    Re: Unmirror a filesystem

    ‏2019-05-29T10:36:54Z  
    • nenifled
    • ‏2019-05-24T11:11:53Z

    I have suspended my disks:

    mmchdisk /dev/gpfsbad suspend -d data_disk_001

    mmchdisk /dev/gpfsbad suspend -d data_disk_002

    mmchdisk /dev/gpfsbad suspend -d data_disk_003

     

    ..and of cause they are now used less. Before I suspended them - there was no difference in the usability as far as I could see.

    Next week I will restripe and delete disks.

    # mmrestripefs /dev/gpfs01 -R
    GPFS: 6027-589 Scanning file system metadata, phase 1 ... 
    GPFS: 6027-552 Scan completed successfully.
    GPFS: 6027-589 Scanning file system metadata, phase 2 ... 
    Scanning file system metadata for badb storage pool
    GPFS: 6027-552 Scan completed successfully.
    GPFS: 6027-589 Scanning file system metadata, phase 3 ... 
    GPFS: 6027-552 Scan completed successfully.
    GPFS: 6027-589 Scanning file system metadata, phase 4 ... 
    GPFS: 6027-552 Scan completed successfully.
    GPFS: 6027-565 Scanning user file metadata ...
     100.00 % complete on Wed May 29 11:26:09 2019  (    500096 inodes with total    1283096 MB data processed)
    GPFS: 6027-552 Scan completed successfully.

     

    :-)

    After the restripe I could delete 

    mmdeldisk /dev/gpfs01 data_disk_001

    mmdeldisk /dev/gpfs01 data_disk_002

    etc - after the delete the disk was "free".

     

    Now I just have to delete the tiebreaker disk....