02-15-2008
Discover the possibilities of the /proc folder
Fri, 15 Feb 2008 09:00:02 GMT
The /proc directory is a strange beast. It doesn't really exist, yet you can explore it. Its zero-length files are neither binary nor text, yet you can examine and display them. This special directory holds all the details about your Linux system, including its kernel, processes, and configuration parameters. By studying the /proc directory, you can learn how Linux commands work, and you can even do some administrative tasks.
Source...
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Where do i get unix at (1 Reply)
Discussion started by: shinobikil
1 Replies
2. UNIX for Dummies Questions & Answers
Hi,
I am trying to calculate the CPU Usage by getting the difference between the idle time reported by /proc/stat at 2 different intervals. Now the 4th entry in the first line of /proc/stat will give me the 'idle time'. But I also came across /proc/uptime that gives me 2 entries : 1st one as the... (0 Replies)
Discussion started by: coderd
0 Replies
3. Shell Programming and Scripting
Using find command is the below possible ?
find /home/abcd/****/efgh
where the "****" can be any name/character.
Thanks,
Vasanth. (2 Replies)
Discussion started by: skcvasanth
2 Replies
4. Ubuntu
Hi,
I have given a laptop from company with Ubuntu 10.04 on it.
I have restricted access over it, means I have been given sudo login on it.
SO I am unable to so many major activities over it,
Can you all people tell me the Terminal tricks that I can use to get my hands on it. (1 Reply)
Discussion started by: nixhead
1 Replies
5. IP Networking
I need a script to scan the surrounding DHCP servers. I want to know how many dhcp servers are there on my connected etnernet. (2 Replies)
Discussion started by: getrue
2 Replies
6. Shell Programming and Scripting
Hello,
Bash completion is great, but there are some features I'd like to change. One thing is the behaviour when there are lots of very similar possibilities.
E.g., my directory contains 133 files, from pubmed_result1.txt to pubmed_result133.txt
$ ls Lyonprim/p
Display all 133... (2 Replies)
Discussion started by: jossojjos
2 Replies
7. UNIX for Dummies Questions & Answers
Hello
I am writing a script that will first execute ps to get the list of processes running, and the go into the /proc folder for each PID listed and gather relevant information.
I looked through the contents of a particular process in the /proc folder and I can't find where I can locate... (2 Replies)
Discussion started by: flagman5
2 Replies
8. Shell Programming and Scripting
Hi,
I try to get the combination of 6 numbers from (1-60) using any script.
Any script that can help me to fix this ...
EG: The output should be like that different possibilities from 1-60...
1) 1 3 15 29 30 42
2) 4 5 6 31 44 60
like the above ... Hereas, I need all the possibilities... (5 Replies)
Discussion started by: gsiva
5 Replies
9. Shell Programming and Scripting
The below awk adds a header Variants Detected: followed by, in this case the line in
file underneath the ## (like the desired result). The script does execute and works as expected
(looks for the keywords in file and prints if found underneath header) if I remove the last awk, which
prints... (3 Replies)
Discussion started by: cmccabe
3 Replies
LINUX(4) BSD Kernel Interfaces Manual LINUX(4)
NAME
linux -- Linux ABI support
SYNOPSIS
To compile support for this ABI into an i386 kernel place the following line in your kernel configuration file:
options COMPAT_LINUX
for an amd64 kernel use:
options COMPAT_LINUX32
Alternatively, to load the ABI as a module at boot time, place the following line in loader.conf(5):
linux_load="YES"
DESCRIPTION
The linux module provides limited Linux ABI (application binary interface) compatibility for userland applications. The module provides the
following significant facilities:
o An image activator for correctly branded elf(5) executable images
o Special signal handling for activated images
o Linux to native system call translation
It is important to note that the Linux ABI support it not provided through an emulator. Rather, a true (albeit limited) ABI implementation
is provided.
The following sysctl(8) tunable variables are available:
compat.linux.osname Linux kernel operating system name.
compat.linux.osrelease Linux kernel operating system release. Changing this to something else is discouraged on non-development systems,
because it may change the way Linux programs work. Recent versions of GNU libc are known to use different syscalls
depending on the value of this sysctl.
compat.linux.oss_version Linux Open Sound System version.
The linux module can be linked into the kernel statically with the COMPAT_LINUX kernel configuration option or loaded as required. The fol-
lowing command will load the module if it is neither linked into the kernel nor already loaded as a module:
if ! kldstat -v | grep -E 'linux(aout|elf)' > /dev/null; then
kldload linux > /dev/null 2>&1
fi
Note that dynamically linked Linux executables will require a suitable environment in /compat/linux. Specifically, the Linux run-time
linker's hints files should be correctly initialized. For this reason, it is common to execute the following commands to prepare the system
to correctly run Linux executables:
if [ -x /compat/linux/sbin/ldconfig ]; then
/compat/linux/sbin/ldconfig -r /compat/linux
fi
For information on loading the linux kernel loadable module automatically on system startup, see rc.conf(5). This information applies
regardless of whether the linux module is statically linked into the kernel or loaded as a module.
FILES
/compat/linux minimal Linux run-time environment
/compat/linux/proc limited Linux process file system
/compat/linux/sys limited Linux system file system
SEE ALSO
brandelf(1), elf(5), linprocfs(5), linsysfs(5)
HISTORY
Linux ABI support first appeared in FreeBSD 2.1.
BSD February 8, 2010 BSD