Problem to save file on the hard disk! What I have to set to do it ?
Thomas Doerfler (nt)
Thomas.Doerfler at imd-systems.de
Mon Mar 13 18:50:03 UTC 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Matteo,
I am a bit confused, your listing shows, that /dev/hda1 is a Linux ext3
partition, but you write that gparted shows it as FAT16. But /dev/hda2
looks fine in the partition table. can you access the filesystem on
/dev/hda2 from linux?
Thomas.
Matteo schrieb:
> Ok this is the result of the command "fdisk -l /dev/hda"
>
> Disk /dev/hda: 40.0 GB, 40007761920 bytes
> 255 heads, 63 sectors/track, 4864 cylinders
> Units = cilindri of 16065 * 512 = 8225280 bytes
>
> Dispositivo Boot Start End Blocks Id System
> /dev/hda1 2678 3014 2706952+ 83 Linux
> /dev/hda2 1 2677 21502971 c W95 FAT32 (LBA)
> /dev/hda3 3015 4784 14217525 83 Linux
> /dev/hda4 4785 4864 642600 5 Esteso
> /dev/hda5 4785 4864 642568+ 82 Linux swap / Solaris
>
>
> looking with gparted I have the result that, hda1 is "FAT16", hda2 is "FAT32",
> hda3 is "ext3", hda4 is "exetended", hda5 is "linux swap".
>
> I created hda1 with FAT16 thinking to resolve the problem, but from the fileio
> example I have always the same error,
> " fsmount: mounting of "/dev/hda1" to "/mnt/hda1" failed: No such file or
> directory " but now hda1 is FAT16 so it could be right for RTEMS, but it isn't.
> Why ?
>
> Can you help me ?
>
> Thanks advanced
>
> MAtteo
>
>
>
> Scrive "Thomas Doerfler (nt)" <Thomas.Doerfler at imd-systems.de>:
>
>
> Matteo,
>
> Matteo schrieb:
>
>>Ok hda3 is "ext3", but I have a window "FAT" on hda1 and hda2, so I could
>
> save
>
>>my file in this partitions?
>
> yes, this should be possible.
>
>
>>But I see from the error message that RTEMS can't mount all my partition
>
> hda1,2
>
>>(FAT) for windows and hda3,4 (ext3) for linux.
>
> can you boot linux on your system, log in as root and send me the output
> of the command "fdisk -l /dev/hda" ? Maybe the type of your FAT
> partitions is ounknown to RTES or your FAT partitions are located in an
> extended partition (most unlikely).
>
>
>>Can you help to save a file in one of this partitions ?
>>Is there any way to save on a "ext3" partitions ?(Because I have to test
>
> RTEMS
>
>>on some linux systems and I'm afraid they are all "ext3"!)
>
> Currently there is no RTEMS support for ext3 filesystems, so sorry, this
> will not work.
>
> wkr,
> Thomas.
>
>
>
>
>>Scrive "Thomas Doerfler (nt)" <Thomas.Doerfler at imd-systems.de>:
>
>
>>Matteo,
>
>>well, it SHOUDL work, if you have a FAT partition in the primary
>>partition table of your harddisk.
>>You are mentioning havong Linux on hda3, most problable it will use
>>"ext3" as the filesystem, and RTEMS does not know this FS type.
>
>>When you are running Linux on your system, what kind of output do you
>>get from the command
>
>>fdisk -l /dev/hda
>
>>(you have to run this as root).
>
>>wkr,
>>Thomas.
>
>
>>Matteo schrieb:
>
>
>>>Ok, like you have suggested I understood the steps to mount the hardisk,
>
>>but
>
>
>>>the problem is that the fileio example doesn't mount my hardisk!
>>>I follow the steps suggest from the fileio.doc but after it asks to me to
>
>>enter
>
>
>>>the partition table of first harddisk ( /dev/hda ) I try to mount the
>>>partitions and I have an error, He says to me
>>>" fsmount: mounting of "/dev/hda1" to "/mnt/hda1" failed: No such file or
>>>directory " and so on for hda2,3,4 and for hdc1,2,3,4
>
>>>Linux partition is on hda3, but the fileio example doesn't mount it !
>>>What's the problem ?
>
>>>Have you some idea ?
>
>>>Really Thanks in advance
>
>>>Matteo
>
>
>
>>>Scrive "Thomas Doerfler (nt)" <Thomas.Doerfler at imd-systems.de>:
>
>
>>>Matteo,
>
>>>I assume you are working on a standard i386 pc hardware. Have a look at
>>>the "fileio" sample application available in the RTEMS source tree under
>>>"cpukit/testsuites/samples/fileio". You should try to get it working on
>>>your system (it should work from scratch if you got a standard PC system).
>
>>>Have a look at "fileio.doc", it explains a bit what should work with
>>>this sample program.
>
>>>In your application, you will have to do the following steps to get
>>>access to your harddisk:
>
>>>- add the IDE and ATA drivers to your standard driver table (see entries
>>>in fileio/system.h)
>>>- add a rtems_bdbuf_configuration data structure to your system (once
>>>again, see fileio/system.h)
>
>>>- add a fs_table to your application, which specifies which harddisk
>>>partitions are to be mounted to which mount points (see fileio/
>
>>>- call the "rtems_ide_part_table_initialize" function after system
>>>startup to read in your harddisk partition table. This call will create
>>>a new device node (/dev/hda1 ...) for each partition available.
>
>>>- call the "rtems_fsmount" function to mount the partitions to their
>>>respective mount points. Have a look into "libmisc/fsmount" to find out,
>>>how it works.
>
>>>Then you can access the harddisk partitions at their respective mount
>>>points.
>
>>>wkr,
>>>Thomas.
>
>
>>>Matteo schrieb:
>
>
>>>>Hi
>>>>Joe says to me ask you how I can save a file on hard disk? if I have to
>
>>set
>
>
>>>>something in my linux's grub?
>
>>>>below the previous email sent to Joel.
>
>>>>Thanks in advance
>
>>>>Matteo
>
>>>>Scrive Joel Sherrill <joel.sherrill at oarcorp.com>:
>
>
>
>>>>>Matteo wrote:
>
>
>
>>>>>>Hi
>>>>>>
>>>>>>I'm trying to use the fdopen example of the package example-4.6.99.2
>
> but
>
>>>it
>
>
>>>>>>doesn't works, It doesn't create the file!
>>>>>>
>>>>>>
>
>>>>>I could be wrong but I think this one actually was submitted as part of
>>>>>a bug report and
>>>>>the bug may still be outstanding. It may be fixed. I just don't
>>>>>remember. See below for
>>>>>the more likely case.
>
>
>
>>>>>>But I can launch the hello world example and I create some simple posix
>
>>>>>program
>
>
>>>>>>with rtems yet so I think to have configured it well.
>>>>>>So what can be the problem ?
>>>>>>May be when I launch the fdopen example I have to set some particular
>
>>>>>privilege
>
>
>>>>>>in the "grub"(my linux boot loader) to allow it to write on the hard
>
>>>disk?
>
>
>>>>>this
>
>
>>>>>>is only my newbye's opinion..
>>>>>>
>>>>>>
>>>>>>
>
>>>>>Ohh.... if you are doing anything with the hard disk, then there is some
>
>>>>>filesystem specific
>>>>>configuration to get things right. The example code is only going to
>>>>>work with the IMFS
>>>>>which is a RAM based filesystem.
>
>>>>>Ask on the list so someone list Thomas can point you to an example
>
> setup.
>
>
>
>>>>>>Thanks in advantage
>>>>>>
>>>>>>Matteo
>>>>>>
>>>>>>
>>>>>>
>
>
>
>
>
>
>>>--
>>>--------------------------------------------
>>>IMD Ingenieurbuero fuer Microcomputertechnik
>>>Thomas Doerfler Herbststrasse 8
>>>D-82178 Puchheim Germany
>>>email: Thomas.Doerfler at imd-systems.de
>>>PGP public key available at:
>>> http://www.imd-systems.de/pgpkey_en.html
>
>>--
>>--------------------------------------------
>>IMD Ingenieurbuero fuer Microcomputertechnik
>>Thomas Doerfler Herbststrasse 8
>>D-82178 Puchheim Germany
>>email: Thomas.Doerfler at imd-systems.de
>>PGP public key available at:
>> http://www.imd-systems.de/pgpkey_en.html
>
> --
> --------------------------------------------
> IMD Ingenieurbuero fuer Microcomputertechnik
> Thomas Doerfler Herbststrasse 8
> D-82178 Puchheim Germany
> email: Thomas.Doerfler at imd-systems.de
> PGP public key available at:
> http://www.imd-systems.de/pgpkey_en.html
- --
- --------------------------------------------
IMD Ingenieurbuero fuer Microcomputertechnik
Thomas Doerfler Herbststrasse 8
D-82178 Puchheim Germany
email: Thomas.Doerfler at imd-systems.de
PGP public key available at:
http://www.imd-systems.de/pgpkey_en.html
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFEFb7ZwHyg4bDtfjQRAiXDAJ9FyOb2fWyRGtL9IUbR6gIIHiZ2hQCfaQXO
7CDQa4svlOVs2IJ1jTWtsN0=
=9YWo
-----END PGP SIGNATURE-----
More information about the users
mailing list