Hi All, I am trying to create a loopback block device under a UML (running kernel 3.1.0). I used following commands: # dd if=/dev/zero of=/tmp/store1 bs=1024 seek=2047 count=1 # losetup /dev/loop1 /tmp/store1 But the 2nd command (i.e. losetup) returns with the error complaining "/dev/loop1" is not present, but I can see /dev/loop[0..7] files present. My question, is it possible to do this exercise under UML (User mode linux)? Thanks, Vishal
But the 2nd command (i.e. losetup) returns with the error complaining "/dev/loop1" is not present, but I can see /dev/loop[0..7] files present. Try loading the module as - #modprobe loop and check again. My question, is it possible to do this exercise under UML (User mode linux)? If you are asking about whether is it possible use to loop device on UML machine, then the answer is 'Yes'. HTH -- ---- Cheers, Lakshmipathi.G FOSS Programmer. www.giis.co.in
On Tue, Nov 15, 2011 at 8:09 PM, Lakshmipathi.G <lakshmipathi.g@gmail.com> wrote:
But the 2nd command (i.e. losetup) returns with the error complaining "/dev/loop1" is not present, but I can see /dev/loop[0..7] files present.
Try loading the module as -
#modprobe loop
This worked. Thanks for pointing that out.
and check again. My question, is it possible to do this exercise under UML (User mode linux)? If you are asking about whether is it possible use to loop device on UML machine, then the answer is 'Yes'. HTH
-- ---- Cheers, Lakshmipathi.G FOSS Programmer. www.giis.co.in
On Wed, Nov 16, 2011 at 9:14 AM, Vishal Thanki <vishalthanki@gmail.com> wrote:
On Tue, Nov 15, 2011 at 8:09 PM, Lakshmipathi.G <lakshmipathi.g@gmail.com> wrote:
But the 2nd command (i.e. losetup) returns with the error complaining "/dev/loop1" is not present, but I can see /dev/loop[0..7] files present.
Try loading the module as -
#modprobe loop
I have one more question in the same line (i.e. related to UML). I tried loading an external module (build for ARCH=um type). I am able to load that module only if i've booted UML with following command: ./linux ubda=<raw_file_system_path> If i pass the mem parameter, i.e. ./linux ubda=<raw_file_system_path> mem=512M I am not able to load the module. The error that I am seeing is: overflow in relocation type 11 val a121c3c0 `tun' likely not compiled with -mcmodel=kernel I tried to load the tun.ko. This holds true for any manually built simple hello_world kind of module too (where i added -mcmodel=kernel parameter in Makefile). What can be wrong with "mem=512M" parameter? I change the size of mem to 128K to 1G, but nothing works. It just doesn't like "mem" parameter as bootargs.
This worked. Thanks for pointing that out.
and check again. My question, is it possible to do this exercise under UML (User mode linux)? If you are asking about whether is it possible use to loop device on UML machine, then the answer is 'Yes'. HTH
-- ---- Cheers, Lakshmipathi.G FOSS Programmer. www.giis.co.in
On Thu, Nov 17, 2011 at 19:04, Vishal Thanki <vishalthanki@gmail.com> wrote:
I have one more question in the same line (i.e. related to UML). I tried loading an external module (build for ARCH=um type). I am able to load that module only if i've booted UML with following command:
./linux ubda=<raw_file_system_path>
If i pass the mem parameter, i.e.
./linux ubda=<raw_file_system_path> mem=512M
I am not able to load the module. The error that I am seeing is:
overflow in relocation type 11 val a121c3c0 `tun' likely not compiled with -mcmodel=kernel
could be a UML specific bug. Have you tried other kernel version? -- regards, Mulyadi Santosa Freelance Linux trainer and consultant blog: the-hydra.blogspot.com training: mulyaditraining.blogspot.com
participants (3)
-
Lakshmipathi.G -
Mulyadi Santosa -
Vishal Thanki