How to grow jail.1.img

Hi all,

I use the jail with memdisk. But, memdisk size is not sufficient
now. How can i grow this memdisk size that it is not destroying
the data in the memdisk jail.1.img

Code:
# mdconfig -a -t vnode -f /jail/images/jail.1.img -u 0
# mount /dev/md0c /jail/jail.1


Regards,

Murat USTUNTAS
 
create another one with the size that's sufficient for you and copy the contents of the original one there and destroy the old image.
 
Ok,

But is there another way to grow. Because, this image size very high and there is no space making new size like that size.
This image size 32Gb but I have a 16Gb on disk for growing this
image.
 
ustuntas said:
Ok,

But is there another way to grow. Because, this image size very high and there is no space making new size like that size.
This image size 32Gb but I have a 16Gb on disk for growing this
image.

Test this method on some smaller test image:
1. you have your current image test.img
2. add needed space by dd(1) like that:
# dd < /dev/zero >> test.img bs=1m count=${COUNT}
where you add ${COUNT} megabytes of space.
3. user growfs(1) to grow the filesystem on the test.img
4. mount(1) it and test if it works
 
I want to grow this memdisk from 32GB to 40GB.
When growing the /dev/md0c with the command says me;

Code:
# growfs -s 40610630 /dev/md0c
growfs: /dev/md0c: Operation not permitted

I assume that something wrong. :(

Any idea please. Or what am i doing something wrong?
 
I write like,

# growfs -s 4194304 /dev/md0
and os says me;
Code:
growfs: we are not growing (4194304->1048576)
in the man page of growfs; -s parameter in sectors.
How can i calculate the correct sector size for growing?
My problem is still same :(.
 
Back
Top