LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 03-08-2004, 01:05 PM   #1
ProtoformX
Member
 
Registered: Feb 2004
Location: Canada
Distribution: LFS SVN
Posts: 334

Rep: Reputation: 34
loop back device fails.... possible bug?


It seems there maybe a bug causing some systems to lose there loop fuctionality...

These are the things I have already tryed.

mount -t iso9660 -o ro,loop=/dev/loop0 /home/tim/test.iso /mnt/iso

And I get this:

mount: wrong fs type, bad option, bad superblock on /dev/loop0,
or too many mounted file systems
(could this be the IDE device where you in fact use
ide-scsi so that sr0 or sda or so is needed?)

Then I tryed this:

losetup /dev/loop0

And got this:

loop: can't get info on device /dev/loop0: No such device or address

and if I do this:

ls -l /dev/ |grep loop

I get this:

brw-rw---- 1 root disk 7, 0 Jun 3 1996 loop0
brw-rw---- 1 root disk 7, 1 Jun 3 1996 loop1
brw-rw---- 1 root disk 7, 10 Mar 19 2002 loop10
brw-rw---- 1 root disk 7, 11 Mar 19 2002 loop11
brw-rw---- 1 root disk 7, 12 Mar 19 2002 loop12
brw-rw---- 1 root disk 7, 13 Mar 19 2002 loop13
brw-rw---- 1 root disk 7, 14 Mar 19 2002 loop14
brw-rw---- 1 root disk 7, 15 Mar 19 2002 loop15
brw-rw---- 1 root disk 7, 2 Jun 3 1996 loop2
brw-rw---- 1 root disk 7, 3 Jun 3 1996 loop3
brw-rw---- 1 root disk 7, 4 Jun 3 1996 loop4
brw-rw---- 1 root disk 7, 5 Jun 3 1996 loop5
brw-rw---- 1 root disk 7, 6 Jun 3 1996 loop6
brw-rw---- 1 root disk 7, 7 Jun 3 1996 loop7
brw-rw---- 1 root disk 7, 8 Jun 3 1996 loop8
brw-rw---- 1 root disk 7, 9 Mar 19 2002 loop9


and if I do this:

mke2fs /dev/loop0 1024

I get this:

mke2fs 1.34 (25-Jul-2003)
mke2fs: Filesystem larger than apparent device size.
Proceed anyway? (y,n) y
Warning: could not erase sector 2: Invalid argument
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
128 inodes, 1024 blocks
51 blocks (4.98%) reserved for the super user
First data block=1
1 block group
8192 blocks per group, 8192 fragments per group
128 inodes per group

Warning: could not read block 0: Attempt to read block from filesystem resulted in short read
Warning: could not erase sector 0: Attempt to write block from filesystem resulted in short write
mke2fs: Invalid argument while zeroing block 960 at end of filesystem
Writing inode tables: 0/1
Could not write 8 blocks in inode table starting at 5: Invalid argument


my fstab looks like this :

/dev/hda5 swap swap defaults 0 0
/dev/hda3 / ext2 defaults 1 1
/dev/hda6 /var ext2 defaults 1 2
/dev/hda7 /home ext2 defaults 1 2
/dev/hda8 /usr ext2 defaults 1 2
/dev/cdrom /mnt/cdrom iso9660 noauto,users,owner,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,users,owner 0 0
/dev/sda1 /mnt/camera auto defaults,user,noauto 0 $
devpts /dev/pts devpts gid=5,mode=620 0 0
proc /proc proc defaults 0 0


I have been looking for along time .. this problem happends to me everytime I recompile my kernel
 
Old 03-08-2004, 03:26 PM   #2
spuzzzzzzz
Member
 
Registered: Sep 2003
Location: Australia
Distribution: Gentoo
Posts: 465

Rep: Reputation: 30
Do you have loopback device support compiled into your kernel? If it is a module, have you inserted it?
 
Old 03-08-2004, 03:42 PM   #3
ProtoformX
Member
 
Registered: Feb 2004
Location: Canada
Distribution: LFS SVN
Posts: 334

Original Poster
Rep: Reputation: 34
Yes I have compiled it in to the kernel at the present time I'm running kernel 2.6.3
 
Old 03-08-2004, 04:50 PM   #4
quatsch
LQ Addict
 
Registered: Aug 2003
Location: New York, NY
Distribution: gentoo, gentooPPC
Posts: 1,661

Rep: Reputation: 48
are those loop devices in /dev symlinks? For me, they are symlinks that point to devices in the directory /dev/loop.

Also, your output of losetup is normal. It will give that unless something is actually mounted.

have your tried
ifup lo
I doubt this helps, though...
 
Old 03-08-2004, 05:02 PM   #5
quatsch
LQ Addict
 
Registered: Aug 2003
Location: New York, NY
Distribution: gentoo, gentooPPC
Posts: 1,661

Rep: Reputation: 48
what's actually the encoding used for the iso? utf-8 or iso-8859-1? I just noticed that sometimes it won't mount b/c of incompatible encoding. It's a matter of loading the right NLS module.

You might make an iso file yourself with mkisofs and see if you can mount that. If you can, it's something about the iso (probably encoding).
 
Old 03-08-2004, 05:11 PM   #6
LinuXP
Member
 
Registered: Feb 2004
Location: Charlottesville, VA
Distribution: ArchLinux
Posts: 65

Rep: Reputation: 15
Actually, I had a problem with the loopback device just the other day when I was tweaking the 2.6.3 kernel. I could have sworn I make loopback support built-in too. Well, what do you know...kernel panic . I loaded up the old 2.4.xx kernel and recompiled the 2.6.3 kernel and it worked fine that time. Very odd.
 
Old 03-09-2004, 01:18 AM   #7
ProtoformX
Member
 
Registered: Feb 2004
Location: Canada
Distribution: LFS SVN
Posts: 334

Original Poster
Rep: Reputation: 34
Chanks guys but I solved the problem... It seems the people at kernel.org forgot to document that if ext2 is used loopback device is disabled, I did a recompile and switched to ex3 and it works ....
 
Old 07-21-2005, 05:21 PM   #8
rino.caldelli
Member
 
Registered: Apr 2005
Location: perugia
Distribution: ubuntu
Posts: 181

Rep: Reputation: 31
I have slackware 10.1 kernel 2.6.9 just compiled and with cryptoloop and block devices working...
however

root@baijotisa:/home/bsldd# losetup /dev/loop0
loop: can't open device /dev/loop0: No such device or address

my root partition is ext3 so loop shouldn't be disabled.....
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
loop: can't open device /dev/loop0: No such device or address miaviator278 Linux - Security 3 06-09-2004 09:24 PM
new kernel installation & loop back devices? fbarre Linux - Newbie 5 10-21-2003 01:40 PM
reg loop back adapater anilchow Linux - Security 1 10-02-2003 06:01 AM
System is hanging at :BRinging up loop back interface" svyshna Linux - General 1 09-21-2003 06:54 PM
Loop back Interface siddiqu Linux - Networking 2 11-17-2001 08:34 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration