Trouble creating boot/root floppy disk

Trouble creating boot/root floppy disk

Post by Mike Boye » Wed, 08 Dec 1999 04:00:00



Hi, I'm having problems creating a boot/root disk, in particular I the
filesystem I am creating
doesn't seem to have enough "something".  By that I mean when I copy
1024 files to the image it
comes back and says "no space left on device".  Below is what I have
done.  I am taking this from the Redhat 6.0 Bootdisk howto file.

first I create an empty file of xxx block size using dd.

dd if=/dev/zero of=/tmp/fsfile bs=1k count=4000

I have tried increasing the count with little impact on the result.

second I create a filesystem on this file.

mke2fs -F -m 0 -i 2000 /tmp/fsfile

this command returns the following:

mke2fs 1.14, 9-Jan-1999 for EXT2 FS 0.5b, 95/08/09
Linux ext2 filesystem format
Filesystem label=
2104 inodes, 4096 blocks
0 blocks (0.00%) reserved for the super user
First data block=1
Block size=1024 (log=0)
Fragment size=1024 (log=0)
1 block group
8192 blocks per group, 8192 fragments per group
2104 inodes per group

Writing inode tables: done                            
Writing superblocks and filesystem accounting information: done

finally I count this new filesystem and try to write to it

mount -o loop -t ext2 /tmp/fsfile /tmp/junk

at this point df -k shows:

Filesystem           1k-blocks      Used Available Use% Mounted on
/tmp/fsfile               3828        13      3815   0% /tmp/junk

at this point I try to copy the device nodes to /tmp/junk/dev from /dev
using
cp -dpR per the howto.

cp -dpR /dev /tmp/junk

part way through I get a slew of "cp: cannot create special file 'name':
No space left on device"

df -k produces

Filesystem           1k-blocks      Used Available Use% Mounted on
/tmp/fsfile               3828        48      3780   1% /tmp/junk

I don't seem to have enough "something" to copy all the files, whether
this is inodes or some
other item is what I am trying to discover.  Any help offered would be
greatly appreciated.
Thanks.

--Mike Boyer

 
 
 

Trouble creating boot/root floppy disk

Post by Art S. Kage » Wed, 08 Dec 1999 04:00:00


You probably have run out of inodes in the little filesystem, you only
gave it 2048 (see the mke2fs output).  Try increasing the inodes, run
df -i /tmp/junk to check if you have run out of inodes.

Art S. Kagel


> Hi, I'm having problems creating a boot/root disk, in particular I the
> filesystem I am creating
> doesn't seem to have enough "something".  By that I mean when I copy
> 1024 files to the image it
> comes back and says "no space left on device".  Below is what I have
> done.  I am taking this from the Redhat 6.0 Bootdisk howto file.

> first I create an empty file of xxx block size using dd.

> dd if=/dev/zero of=/tmp/fsfile bs=1k count=4000

> I have tried increasing the count with little impact on the result.

> second I create a filesystem on this file.

> mke2fs -F -m 0 -i 2000 /tmp/fsfile

> this command returns the following:

> mke2fs 1.14, 9-Jan-1999 for EXT2 FS 0.5b, 95/08/09
> Linux ext2 filesystem format
> Filesystem label=
> 2104 inodes, 4096 blocks
> 0 blocks (0.00%) reserved for the super user
> First data block=1
> Block size=1024 (log=0)
> Fragment size=1024 (log=0)
> 1 block group
> 8192 blocks per group, 8192 fragments per group
> 2104 inodes per group

> Writing inode tables: done
> Writing superblocks and filesystem accounting information: done

> finally I count this new filesystem and try to write to it

> mount -o loop -t ext2 /tmp/fsfile /tmp/junk

> at this point df -k shows:

> Filesystem           1k-blocks      Used Available Use% Mounted on
> /tmp/fsfile               3828        13      3815   0% /tmp/junk

> at this point I try to copy the device nodes to /tmp/junk/dev from /dev
> using
> cp -dpR per the howto.

> cp -dpR /dev /tmp/junk

> part way through I get a slew of "cp: cannot create special file 'name':
> No space left on device"

> df -k produces

> Filesystem           1k-blocks      Used Available Use% Mounted on
> /tmp/fsfile               3828        48      3780   1% /tmp/junk

> I don't seem to have enough "something" to copy all the files, whether
> this is inodes or some
> other item is what I am trying to discover.  Any help offered would be
> greatly appreciated.
> Thanks.

> --Mike Boyer


 
 
 

Trouble creating boot/root floppy disk

Post by Floyd Davids » Thu, 09 Dec 1999 04:00:00



Quote:>Hi, I'm having problems creating a boot/root disk, in particular I the

I'm going to snip out all but the command lines here.

Quote:>dd if=/dev/zero of=/tmp/fsfile bs=1k count=4000
>mke2fs -F -m 0 -i 2000 /tmp/fsfile
>mount -o loop -t ext2 /tmp/fsfile /tmp/junk
>cp -dpR /dev /tmp/junk
>I don't seem to have enough "something" to copy all the files,
>whether this is inodes or some other item is what I am trying
>to discover.  Any help offered would be greatly appreciated.

Now run "df --inodes /tmp/junk" and what you will find is that
all inodes have been used.  It appears that since the instructions
you are reading were written, the number of inodes used by the
device files as increase (significantly).  You have two options.
One is to increase the number of inodes specified in the mke2fs
command, and the other is to reduce the number of device special
files that are copied.  It may or may not be easy to determine
which device special files you will or will not need... :-)

With a 2.2.13 kernel, I found that using the minimum ratio of
bytes to inodes that mke2fs would allow (-i 1024), resulted in a
file system which looked like this, after copying the entire
/dev directory to it:

#df -k
Filesystem    1024-blocks  Used Available Capacity Mounted on
/var/tmp/fs        3495      13     3482      0%   /var/tmp/junk
#df --inodes
Filesystem      Inodes   IUsed   IFree  %IUsed Mounted on
/var/tmp/fs        4000    3617     383    90%  /var/tmp/junk

Note the reduction of space available for data, to 3495 blocks,
and that only 383 inodes remain free.  Either of those could
prove to be a serious restriction.

There might be a third option too.  If the filesystem size is
increased from 4Mb to 8Mb the problem is shifted from the point
above to a more general one of not putting so much on the disk
that it cannot be compressed enough to fit on a floppy.  I have
done rescue disks that way in the past, but it was with earlier
kernels etc. and I'm not in any position to suggest what
problems might be encountered.  It might be easier to configure
everything for a larger filesystem and then develop a script
that deletes unneeded device files, for example, before the file
system is compressed.

  Floyd

--

Ukpeagvik (Barrow, Alaska)

 
 
 

1. Can't create lilo boot floppy for 3rd SCSI disk but can boot it

I have Linux 1.2.8 installed on a IDE /hda2 as root with 2 SCSI disk
drives with MS-DOS and some additional linux partitions on a AHA1542.
I have now got a new SCSI HD and copied all the Linux onto the last SCSI
hard disk (ID:3), hoping to delete the IDE stuff. When I came to
install LILO on a boot floppy, it came up BIOS drive 0x83 may not be
accessible 3 times.

When I boot, I just get garbage but I did manage to re-mount the
/hda2 to / with a SCSI kernel recovery disk and created a SCSI boot
floppy and that works OK. Trouble is that I cannot install LILO
and I will need to change things in the future once I have deleted
my IDE partition. The LILO DOCs do not give specific guidance

Any ideas?

******************************************************


* On the Web: http://www.wlv.ac.uk/~cm4272/home.html *
* "Our Hamburgers are made with beef" - McDonald's   *
******************************************************

2. Thinkpads ???

3. root disk file system and nfs server from boot/root floppies.

4. Installation of SIS 6502 Video config on Red Hat 3.0.3

5. How to build boot disk for boot/root floppy

6. Q: C Compiler for AIX 4.1.4

7. How does one create a root disk on a floppy?

8. dhcpd difficulty

9. Boot + root or boot/root floppies: how??

10. problem creating root and boot floppies on 3.2v5.0.4 system

11. Problem creating emergency root/boot floppies

12. can't create boot and root floppies!

13. root disk file system and nfs server from boot/root disks.