Sponsored Content
Top Forums UNIX for Beginners Questions & Answers Which UNIX OS is going to give me the most versatility? I Want Total Control Post 302974337 by hicksd8 on Saturday 28th of May 2016 10:22:18 AM
Old 05-28-2016
Well if you really want to "tweak the guts of the O/S" I guess you need to start from source code; is that what you mean?

There are a number of Linux distros that allow you to download the whole source code and then compile if you've got CPU cycles to burn and a few hours to do it in. I know that Ubuntu will allow that. Also Gentoo provides kernel tailoring letting you build the O/S you want.

Understanding all this can be an issue if you haven't done it before. There's a project called Linux From Scratch (LFS) which provides source code but also a book in both digital and hardcopy which describes the internals of how the kernel is built. That might be a good place to start.
This User Gave Thanks to hicksd8 For This Post:
 

7 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Unix System Total Replication

Is there any way to totally replicate a unix system from one hardisk to another? And be able to swap the hardisk and restart the system without any error? TQ (4 Replies)
Discussion started by: nuraman
4 Replies

2. HP-UX

How should I know the total RAM available on UNIX

Hi How Should I know the Total RAM available on HP-UX box? (7 Replies)
Discussion started by: skull123
7 Replies

3. UNIX for Dummies Questions & Answers

grep running total/ final total across multiple files

Ok, another fun hiccup in my UNIX learning curve. I am trying to count the number of occurrences of an IP address across multiple files named example.hits. I can extract the number of occurrences from the files individually but when you use grep -c with multiple files you get the output similar to... (5 Replies)
Discussion started by: MrAd
5 Replies

4. UNIX for Advanced & Expert Users

can some one give me some link about process and job control commands

can some one give me some link about process and job control commands (2 Replies)
Discussion started by: alokjyotibal
2 Replies

5. Shell Programming and Scripting

Calculate total space, total used space and total free space in filesystem names matching keyword

Good afternoon! Im new at scripting and Im trying to write a script to calculate total space, total used space and total free space in filesystem names matching a keyword (in this one we will use keyword virginia). Please dont be mean or harsh, like I said Im new and trying my best. Scripting... (4 Replies)
Discussion started by: bigben1220
4 Replies

6. Programming

Please give me some advise to program for unix/linux using c/c++?

I have a good foundation of c++.I want to learn to program for linux/unix,can you give me some advises,for example classic books ,which operating system is used better(freebsd,solaris,federal linux.etc),and which aspects uses mostly in job.Can you give me clear direction for working or learning. (1 Reply)
Discussion started by: fengshuiyue
1 Replies

7. UNIX for Dummies Questions & Answers

For SFTP connection - How to give password in UNIX Script (ksh)

Hi, I am not able to give the password in Unix script for SFTP connection. When I am trying to manully SFTP command for accessing the server , it asking for pwd and I could provide the pwd but I am not getting how to provide the pwd inside the Unix script. sftp -v user@xyz.com. ... (4 Replies)
Discussion started by: Vineeta Nigam
4 Replies
Df(3pm) 						User Contributed Perl Documentation						   Df(3pm)

NAME
Filesys::Df - Perl extension for filesystem disk space information. SYNOPSIS
use Filesys::Df; #### Get information by passing a scalar directory/filename value my $ref = df("/tmp"); # Default output is 1K blocks if(defined($ref)) { print "Total 1k blocks: $ref->{blocks} "; print "Total 1k blocks free: $ref->{bfree} "; print "Total 1k blocks avail to me: $ref->{bavail} "; print "Total 1k blocks used: $ref->{used} "; print "Percent full: $ref->{per} "; if(exists($ref->{files})) { print "Total inodes: $ref->{files} "; print "Total inodes free: $ref->{ffree} "; print "Inode percent full: $ref->{fper} "; } } #### Get information by passing a filehandle open(FILE, "some_file"); # Get information for filesystem at "some_file" my $ref = df(*FILE); #### or my $ref = df(*FILE); #### or my $fhref = *FILE; my $ref = df($fhref); #### Get information in other than 1k blocks my $ref = df("/tmp", 8192); # output is 8K blocks my $ref = df("/tmp", 1); # output is bytes DESCRIPTION
This module provides a way to obtain filesystem disk space information. This is a Unix only distribution. If you want to gather this information for Unix and Windows, use "Filesys::DfPortable". The only major benefit of using "Filesys::Df" over "Filesys::DfPortable", is that "Filesys::Df" supports the use of open filehandles as arguments. The module should work with all flavors of Unix that implement the "statvfs()" and "fstatvfs()" calls, or the "statfs()" and "fstatfs()" calls. This would include Linux, *BSD, HP-UX, AIX, Solaris, Mac OS X, Irix, Cygwin, etc ... "df()" requires a argument that represents the filesystem you want to query. The argument can be either a scalar directory/file name or a open filehandle. There is also an optional block size argument so you can tailor the size of the values returned. The default block size is 1024. This will cause the function to return the values in 1k blocks. If you want bytes, set the block size to 1. "df()" returns a reference to a hash. The keys available in the hash are as follows: "{blocks}" = Total blocks on the filesystem. "{bfree}" = Total blocks free on the filesystem. "{bavail}" = Total blocks available to the user executing the Perl application. This can be different than "{bfree}" if you have per-user quotas on the filesystem, or if the super user has a reserved amount. "{bavail}" can also be a negative value because of this. For instance if there is more space being used then you have available to you. "{used}" = Total blocks used on the filesystem. "{per}" = Percent of disk space used. This is based on the disk space available to the user executing the application. In other words, if the filesystem has 10% of its space reserved for the superuser, then the percent used can go up to 110%. You can obtain inode information through the module as well, but you must call "exists()" on the "{files}" key first, to make sure the information is available. Some filesystems may not return inode information, for example some NFS filesystems. Here are the available inode keys: "{files}" = Total inodes on the filesystem. "{ffree}" = Total inodes free on the filesystem. "{favail}" = Total inodes available to the user executing the application. See the rules for the "{bavail}" key. "{fused}" = Total inodes used on the filesystem. "{fper}" = Percent of inodes used on the filesystem. See rules for the "{per}" key. There are some undocumented keys that are defined to maintain backwards compatibilty: "{su_blocks}", "{user_blocks}", etc ... If the "df()" call fails for any reason, it will return undef. This will probably happen if you do anything crazy like try to get information for /proc, or if you pass an invalid filesystem name, or if there is an internal error. "df()" will "croak()" if you pass it a undefined value. Requirements: Your system must contain "statvfs()" and "fstatvfs()", or "statfs()" and "fstatfs()" You must be running Perl 5.6 or higher. AUTHOR
Ian Guthrie IGuthrie@aol.com Copyright (c) 2006 Ian Guthrie. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. SEE ALSO
statvfs(2), fstatvfs(2), statfs(2), fstatfs(2), df(1), Filesys::DfPortable perl(1). perl v5.14.2 2006-06-25 Df(3pm)
All times are GMT -4. The time now is 02:32 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy