mirror of
https://github.com/OpenNebula/one.git
synced 2026-11-23 05:04:56 +09:00
F #1509: Added more data to the description and possibility to introduce TiB
This commit is contained in:
1 parent
9effa47d26
commit
32d61bc6c5
2 files changed
+8
-1
No files matched your search
@@ -794,13 +794,15 @@ EOT
|
||||
end
|
||||
|
||||
def OpenNebulaHelper.size_in_mb(size)
|
||||
m = size.match(/^(\d+(?:\.\d+)?)(m|mb|g|gb)?$/i)
|
||||
m = size.match(/^(\d+(?:\.\d+)?)(t|tb|m|mb|g|gb)?$/i)
|
||||
|
||||
if !m
|
||||
# return OpenNebula::Error.new('Size value malformed')
|
||||
return -1, 'Size value malformed'
|
||||
else
|
||||
multiplier=case m[2]
|
||||
when /(t|tb)/i
|
||||
1024*1024
|
||||
when /(g|gb)/i
|
||||
1024
|
||||
else
|
||||
|
||||
@@ -879,6 +879,11 @@ cmd=CommandParser::CmdParser.new(ARGV) do
|
||||
|
||||
disk_resize_desc = <<-EOT.unindent
|
||||
Resizes a VM disk. The new size should be larger than the old one.
|
||||
The valid units are:
|
||||
- T: TiB
|
||||
- G: GiB
|
||||
- M: MiB
|
||||
By default is MiB.
|
||||
|
||||
States: RUNNING, POWEROFF
|
||||
EOT
|
||||
|
||||
Reference in new issue
Block a user