You are not logged in.
Pages: 1
I just installed a system on LVM2. It seems to be working. But then when I check the spaces:
# df -h
Filesystem Size Used Avail Use% Mounted on
rootfs 5.0G 3.8G 1.1G 79% /
/dev 2.0G 0 2.0G 0% /dev
/run 2.0G 288K 2.0G 1% /run
/dev/mapper/VGK210-ROOT 5.0G 3.8G 1.1G 79% /
shm 2.0G 248K 2.0G 1% /dev/shm
/dev/mapper/VGK210-BOOT 497M 43M 430M 10% /boot
/dev/mapper/VGK210-HOME 50G 890M 47G 2% /home
/dev/mapper/VGK210-VAR 5.0G 993M 3.8G 21% /var
tmpfs 2.0G 52K 2.0G 1% /tmp
/dev/mapper/VGK210-EXPORT 100G 1.7G 94G 2% /export
I noted that /home and /export already have almost 1G and 1.7G used, respectively. This is a new install. /home is almost empty and I just mkfs.ext4-ed /export.
]# du -sh /home /export
12M /home
20K /export
Why is there so much space in used already?
Cheers!
M
Offline
When creating filesystems with ext4 5% of the filesystem is reserved for the super-user.
From the mkfs.ext4 man page:
-m reserved-blocks-percentage
Specify the percentage of the filesystem blocks reserved for the super-user. This avoids fragmenta‐
tion, and allows root-owned daemons, such as syslogd(8), to continue to function correctly after non-
privileged processes are prevented from writing to the filesystem. The default percentage is 5%.
When creating big filesystems you can safely set this variable lower than 5%.
Offline
That's the size of the filesystem metadata created when formatting, such as the inode table. Nothing to do with LVM, but rather with ext filesystem family.
You can change the number of inodes (at formating time only) if you think you're going to write big files to the partition:
sudo mkfs.ext4 -i 262144 /dev/sdbX
The reserved blocks percentage can be changed after formating, with tune2fs.
Offline
This partition is mean to host my media files for sharing. So mp3/flac's of a few MB and movies of a 0.5-4 GB each. What would be a good amount to set this parameter to?
Thanks.
Cheers!
M
Offline
It's hard to answer without seeing your files collection, but if you're not going to have any file smaller than 1MB, it should be safe to use just that: "-i 1048576".
You could also use "-T largefile" which might be preferable because it also affects block size, but I haven't tried it. See /etc/mke2fs.conf, "man mke2fs.conf" and "man mke2fs" for more information...
You can use "df -i" to see current inodes usage.
Offline
It's hard to answer without seeing your files collection, but if you're not going to have any file smaller than 1MB, it should be safe to use just that: "-i 1048576".
You could also use "-T largefile" which might be preferable because it also affects block size, but I haven't tried it. See /etc/mke2fs.conf, "man mke2fs.conf" and "man mke2fs" for more information...
You can use "df -i" to see current inodes usage.
-T largefile can have a _really bad_ effect on space usage if you have a lot of small files btw, so use with care.
Also I suggest watching this: http://www.youtube.com/watch?v=FegjLbCnoBw
Evil #archlinux@libera.chat channel op and general support dude.
. files on github, Screenshots, Random pics and the rest
Offline
Pages: 1