LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-12-2004, 04:42 PM   #1
ebh1
LQ Newbie
 
Registered: Sep 2003
Posts: 4

Rep: Reputation: 0
writing a loopback device


I am definietly a newbie when it comes to kernel hacking. I need to write a loopback device that uses a file as the underlying block device. It sounds simple enough, but I am having trouble getting started. Can anyone point me in the right direction just so I can get started?
 
Old 03-12-2004, 05:00 PM   #2
neilcpp
Member
 
Registered: Jul 2003
Location: England
Distribution: Debian Jessie, FreeBSD 10.1 anything *nix to get my fix
Posts: 329

Rep: Reputation: Disabled
Im not able to help you with your query. But if i were trying to do what your trying to do, i would post to the kernel developers mailing list as your question is probably on topic there.

I think the url is http://vger.kernel.org/
 
Old 03-12-2004, 05:12 PM   #3
synapse
Member
 
Registered: Jan 2004
Location: On Planet Earth.
Distribution: Slackware 12
Posts: 244

Rep: Reputation: 30
Hi
you could try as root

dd if=/dev/zero of=~/block_file count=1440 bs=1024 #creates block device os size 1440Megs
losetup /dev/loop0 ~/block_file # sets up loopback
mke2fs /dev/loop0 #formats filesystem
mkdir ~/block_dir #creates mount point
mount /dev/loop0 ~/block_dir #mounts directory as block device
then continue to work in the mounted directory

this should work
cheers
 
  


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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
PCAP on LOOPBACK Device johnnyde Programming 4 03-05-2009 04:05 AM
loopback device praveenv Linux - Newbie 2 08-23-2004 07:27 AM
no loopback device in routing table KingNothing Linux - Networking 3 05-02-2004 02:08 AM
loopback device in 2.5.47 broken markus1982 Linux - General 3 11-13-2002 11:52 AM
loopback adapter --> unamanaged device sc300t Linux - General 0 01-17-2002 10:10 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:31 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