luca2 Posted October 31, 2015 Share Posted October 31, 2015 Hi, I have managed to grow a .qcow2 file succesfully, but cannot make it with the default .img file that is created when using the built-in functionality in Unraid to create vm´s. I used to type this command...and this is what I get: root@Tower:/mnt/vm# qemu-img resize vdisk1.img +60G WARNING: Image format was not specified for 'vdisk1.img' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions. Image resized. I am running v6.0.1. Hope someone can help. Quote Link to comment
itimpi Posted November 1, 2015 Share Posted November 1, 2015 Hi, I have managed to grow a .qcow2 file succesfully, but cannot make it with the default .img file that is created when using the built-in functionality in Unraid to create vm´s. I used to type this command...and this is what I get: root@Tower:/mnt/vm# qemu-img resize vdisk1.img +60G WARNING: Image format was not specified for 'vdisk1.img' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions. Image resized. I am running v6.0.1. Hope someone can help. Since the error message implies you need to specify you need to give the format for raw images in the parameters have you tried the command qemu-img resize -fmt raw vdisk1.img +60G Quote Link to comment
luca2 Posted November 1, 2015 Author Share Posted November 1, 2015 Hi, thx for trying. This is waht I get: root@Tower:/mnt/vm# qemu-img resize -fmt raw vdisk1.img +60G qemu-img: Expecting one image file name Try 'qemu-img --help' for more information Any other idea? Quote Link to comment
itimpi Posted November 1, 2015 Share Posted November 1, 2015 Hi, thx for trying. This is waht I get: root@Tower:/mnt/vm# qemu-img resize -fmt raw vdisk1.img +60G qemu-img: Expecting one image file name Try 'qemu-img --help' for more information Any other idea? Looking at the help from qemu-img it does not seem to have any option on the resize mode to specify a format. All I can think is that you convert the raw format to some other one that can be resized, resize that, and then convert back. It may be possible to resize a raw image using the Linux 'truncate' command to extend the file, but I am not sure. Quote Link to comment
luca2 Posted November 1, 2015 Author Share Posted November 1, 2015 Jonp, I love kvm vodoo magic. I am not an expert in linux, but I love this! I have been posting before that I could not grow (resize) my .img created by unraid (using the tool to create vm´s in VM menu). Just a couple of minutes ago, I checked again my .img using "qemu-img info" and I could not believe it: root@Tower:/mnt/vm# qemu-img info vdisk1.img image: vdisk1.img file format: raw virtual size: 100G (107374182400 bytes) disk size: 17G My original .img of 40G did actually grow to 100G! How did this happen? Based on previous fighting with kvm for months (while creating my vm´s) I always backup my command line inputs in putty, so this is what I found out. I did again grow my .img +20G ... so here again vodoo magic was happening: root@Tower:/mnt/vm# qemu-img info vdisk1.img image: vdisk1.img file format: raw virtual size: 100G (107374182400 bytes) disk size: 17G root@Tower:/mnt/vm# qemu-img resize vdisk1.img +20G WARNING: Image format was not specified for 'vdisk1.img' and probing guessed raw. Automatically detecting the format is dangerous for raw images, write operations on block 0 will be restricted. Specify the 'raw' format explicitly to remove the restrictions. Image resized. root@Tower:/mnt/vm# qemu-img info vdisk1.img image: vdisk1.img file format: raw virtual size: 120G (128849018880 bytes) disk size: 17G Thx all for support. I wish I was rich and could play more with kvm Hope this help others. Rgds. Quote Link to comment
busa1 Posted November 22, 2017 Share Posted November 22, 2017 I'm not sure if anyone is still reading this, but just by increasing the size of the vm, that data doesn't get allocated, if I'm right. Anyone know how to allocate data on ubuntu server? (Only using command line) Quote Link to comment
sureguy Posted February 2, 2018 Share Posted February 2, 2018 On 11/21/2017 at 8:25 PM, busa1 said: I'm not sure if anyone is still reading this, but just by increasing the size of the vm, that data doesn't get allocated, if I'm right. Anyone know how to allocate data on ubuntu server? (Only using command line) You should be able to use gparted to do that. Always best to have a backup first. Quote Link to comment
dweb Posted February 5, 2018 Share Posted February 5, 2018 (edited) I am facing the same issue at the moment... I increased the Filesystem with Unraid Webinterface but it is not allocated. I tried running gparted on my UbuntuServer VM without success. Any suggestions how I can extend the filesystem? Edited February 5, 2018 by dweb Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.