rockstor / rockstor-core

Linux/BTRFS based Network Attached Storage(NAS)
http://rockstor.com/docs/contribute_section.html
GNU General Public License v3.0
553 stars 137 forks source link

add a cancel ballance button #1413

Open phillxnet opened 8 years ago

phillxnet commented 8 years ago

As balance operations can be lengthy and inconvenient I propose we have a 'Cancel balance' button which would simply run the following command:

btrfs balance cancel /mnt2/pool-name

This button could be located next to the the existing "Start a new balance" button in each pools "Balances" tab.

phillxnet commented 8 years ago

Also a pause/resume button which would in turn run one of the following commands:

btrfs balance pause /mnt2/pool-name
btrfs balance resume /mnt2/pool-name
phillxnet commented 8 years ago

Ensure with this addition that we update the db of balance tasks via a call to:

storageadmin/views/pool_balance.py _balance_status(pool)

This should be done after every button press to ensure the db is updated accordingly.

Issue #1022 (pr #1418 pr #1445) already has pending commits that help the Web-UI layer interpret cancelling, cancelled, pausing, and paused states within running balance tasks. So this issue should only be attempted after those commits are merged.

phillxnet commented 8 years ago

Please update the following forum thread with significant progress on this issue: https://forum.rockstor.com/t/running-balance-does-not-show-under-balances/1981