473,408 Members | 2,477 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

filesystem within a file

Hi list!

I would like to write a linux c++ program which mounts it's own filesystem
within a file, that is located in the Linux filesystem.
Now I don't know how to start that. I need basic help on how to write my
tool that I'm abel to create a File and "formating" this file, so that I
can place "files" in my filesystem in my file. Does anyone know where I
could get basic information about writing something like that? Or, maybe
how a filesystem is basically designed? Would be great.

thx
Jul 19 '05 #1
1 2555
Francois Fernandes wrote:
Hi list!

I would like to write a linux c++ program which mounts it's own
filesystem within a file, that is located in the Linux filesystem.
Now I don't know how to start that. I need basic help on how to write my
tool that I'm abel to create a File and "formating" this file, so that I
can place "files" in my filesystem in my file. Does anyone know where I
could get basic information about writing something like that? Or, maybe
how a filesystem is basically designed? Would be great.

thx


This is OT here unless you are asking how this would be done on any system.

On Linux you don't need to, use the loop device to mount a file and then
use it as a filesystem. "man mount"

The more std c++ way to answer the question is to tell you to research
how filesystems work and make one. I believe that at a basic level they
are b-trees which should be easily implemented using std c++.
www.tldp.org has books on the Linux kernel which may help you understand
how a filesystem works. You can also look at the source to Linux for
this information.

NR

Jul 19 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Peter Hansen | last post by:
The term "mock filesystem" refers to code allowing unit or acceptance tests to create, read and write, and manipulate in other ways "virtual" files, without any actual disk access. Everything is...
6
by: rbt | last post by:
More of an OS question than a Python question, but it is Python related so here goes: When I do os.walk('/') on a Linux computer, the entire file system is walked. On windows, however, I can...
4
by: Christian Blackburn | last post by:
Hi Gang, I've created a text-based file format. Once I've generated the text to save the file is as it should be in the debug window. However once I write it to a file a " is added to the...
2
by: Jeff Davis | last post by:
I have virtual hosted users on a server and some of them have a postgresql database. I'm concerned about the outside possibility that a user could create an infinite loop and fill up the partition...
4
by: FAQ server | last post by:
----------------------------------------------------------------------- FAQ Topic - How can I access the client-side filesystem?...
12
by: =?Utf-8?B?R2VyaGFyZA==?= | last post by:
I am using .Net 2.0, writing a directory on a network share using My.Computer.FileSystem.CreateDirectory. This works fine as long a USERS have full share permissions on that directory. My...
2
by: Javier | last post by:
Hello all, I'm trying to remove a hidden file (in UNIX) using the Boost::filesystem library. This is what I have: #include <boost/filesystem/operations.hpp> namespace...
1
by: Thomas W | last post by:
I want to create a virtual filesystem based on a relational database. It might run as a server on a different machine, but it has to be available like a normal filesystem, either shared using...
3
by: Patient Guy | last post by:
I am curious as to the strategy experienced scripters use when trying to interface with the filesystem through the web document. This for scripters who try to write web documents acting as...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.