Page 2 of 2 FirstFirst 12
Results 11 to 17 of 17

Thread: Formatting HD using Ext3 (for use with TV)

  1. #11
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Formatting HD using Ext3 (for use with TV)

    Not sure where you got the 44G file from. There is a difference in the way that HDD vendors count and the rest of the world. They use 1000, not 1024, but nearly all software uses 1024b = 1KB. Depends on which counting is used - base 10 or base 2. https://en.wikipedia.org/wiki/Kilobyte

    Also, by default, 5% of a file system is "reserved" for use by privileged processes. For an OS partition, this is VERY important. For 100% data partitions, I remove that reserved amount.

    And lastly, formatting a partition puts markers down which use a few Kb.

    For example:
    Code:
    $ sudo parted -l
    
    Model: WD My Book 1140 (scsi)
    Disk /dev/sdb: 2000GB
    Sector size (logical/physical): 512B/512B
    Partition Table: msdos
    Disk Flags: 
    
    Number  Start   End     Size    Type      File system  Flags
     1      32.3kB  2000GB  2000GB  extended
     5      1049kB  2000GB  2000GB  logical   ext4
    Great. But after formatting to ext4, that 2TB becomes:
    Code:
    $ df -Th | grep b5
    Filesystem     Type  Size  Used Avail Use% Mounted on
    /dev/sdb5      ext4  1.8T  1.4T  412G  78% /misc/2TB
    We can see the count of inodes:
    Code:
    $ df -i
    Filesystem     Inodes IUsed IFree IUse% Mounted on
    /dev/sdb5        117M  320K  117M    1% /misc/2TB
    Those reserved blocks?
    Code:
    $ sudo tune2fs -l  /dev/sdb5
    ...
    Reserved block count:     0
    ...
    File systems use something called inodes to bridge the file system -to- data locations on the disk. When the file system is created, some number of inodes are created based on the size of the disk storage. Running out of inodes can make for a terrible day. It is less common in disks over 10TB. Those inodes require storage, that's part of the "format". To learn more about inodes, the wikipedia article is good enough. https://en.wikipedia.org/wiki/Inode

    I don't have a big HDD available to run ext3 format tests on right now. Sorry.

    I think GUI tools are often too far from the hardware and over simplify what is actually happening. They often choose sub-optimal settings. Plus, on non-desktop systems, there isn't any GUI, so I'd need to know both the GUI and non-GUI methods. Much easier to just learn 1 for me. Plus, GUIs change every few years and non-GUI tools stay about the same for 10+ yrs, if not 20+ yrs. Anyway, that's my thought process for wanting to see CLI tools run and the output from those tools.

  2. #12
    Join Date
    Feb 2012
    Beans
    79

    Re: Formatting HD using Ext3 (for use with TV)

    Yes, I know about 1024. I cut my teeth on this stuff with the PDP-8, so I know at least enough to get in trouble, but not full time. And yes, I know about the OS overhead. But isn't that 5% part of the net 2.73TB? Also 44GB appears to be only about 1.4% of 3TB (if my math is correct). I don't know what it is, but I think it's something different than the OS overhead. Still, I'll look into that possibility.

    Was tied up today, but hope to get back to this over the weekend. I think I might try the CLI as you suggest, and maybe the NTFS. I'll update when I have more to report. Thanks again for your assistance.

  3. #13
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Formatting HD using Ext3 (for use with TV)

    Inode tables use 2MB of inodes for each 128MiB of disk.

    From the mkfs.ext3 manpage:
    Code:
                  The default inode size is  controlled  by  the  mke2fs.conf(5)
                  file.  In the mke2fs.conf file shipped with e2fsprogs, the de‐
                  fault inode size is 256 bytes for most  file  systems,  except
                  for small file systems where the inode size will be 128 bytes.
    The ext3 journal area also takes some space which is related to the total partition size.

    These things can be tuned. On really large partitions, I don't bother. It is the smaller partitions where I've run out of inodes because the defaults were terribly small. Running out of inodes makes for a very bad day. Trust me.

    And there are superblocks and backups of the superblocks which also take some storage. The settings, defaults, and tuning of those settings are documented in the manpages.

  4. #14
    Join Date
    Feb 2012
    Beans
    79

    Re: Formatting HD using Ext3 (for use with TV)

    That could very well explain it. The drive is nominally 3TB, but the net is 2.73TB. So 2.73TB / 128MB = 21,328 and multiplying that by 128MB = 42.656 GB ... which is close enough to the 44 GB being used by the unknown file.

    I've never had an instance of running out of inodes (at least where I was aware of it). But I'll take your word for it. I remember in the 1980's fighting for every byte of a 64K floppy, even getting out Norton Editor to use all the space. That was MS-DOS, not Linux.

  5. #15
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Formatting HD using Ext3 (for use with TV)

    Quote Originally Posted by Lappert View Post
    That could very well explain it. The drive is nominally 3TB, but the net is 2.73TB. So 2.73TB / 128MB = 21,328 and multiplying that by 128MB = 42.656 GB ... which is close enough to the 44 GB being used by the unknown file.

    I've never had an instance of running out of inodes (at least where I was aware of it). But I'll take your word for it. I remember in the 1980's fighting for every byte of a 64K floppy, even getting out Norton Editor to use all the space. That was MS-DOS, not Linux.
    When there aren't any inodes left on a partition, the only thing that can be done is deleting files. Nothing else. On the OS or logging partition logs cannot be created, just appended. Lots of common commands use temporary files - none of those work. Little commands like du and df don't work. Forget about using a GUI. They create so many temporary files as to be useless.

    In the 1980s, the smallest floppies I used were 160Kb. Remember when they got DSDD floppies and 360Kb was possible. I can probably find my old FORTRAN 66 floppies somewhere.

  6. #16
    Join Date
    Feb 2012
    Beans
    79

    Re: Formatting HD using Ext3 (for use with TV)

    Putting aside the PDP-8 we used in college (no floppies, programs were on paper tape), and various Wang or Xerox word processors that had 8" disks, my first computer was an Atari 800 - good machine for its time, lousy marketing. I mispoke. The Atari 810 single side single density drive (using AtariDOS) was formatted for 88 or 90K, not 64K.

    Later on, I bought a non-Atari drive (Percom), double-sided, double density floppy drive ($600) that formatted to 360K (using both sides, but you had to turn to the other side manually and use the old notch trick). That drive came with it's own OS.

  7. #17
    Join Date
    Sep 2011
    Location
    Pennsylvania, U.S.A.
    Beans
    3,068
    Distro
    Ubuntu Development Release

    Re: Formatting HD using Ext3 (for use with TV)

    Quote Originally Posted by sudodus View Post
    This makes me think that the drive is damaged and the process gets stuck at some sectors that are not readable or not writable. Is there S.M.A.R.T. information on the old drive? In that case test it (easy via Disks alias gnome-disks) or more detailed via smartctl (part of the program package smartmontools).
    That's a very good suggestion, especially for old drives.

Page 2 of 2 FirstFirst 12

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •