Learning record 004-Directory and file extension

Source: Internet
Author: User

First, Directory
1. System log file storage/var/log/messages, the information inside the automatic polling, often look at this file, the system has a problem, first look at this file
2.var/log/secure//record log in information by weekly polling
3.var/log/wtmp//Record last information input last displays information about the login account or W who Lastlog
4.var/spool/cron/root//Timed task Crontab-l the same effect
5.var/spool/clientmqueue//sendmail The file directory of temporary mail sometimes causes the inode to be full.
6.proc//virtual directory is a mapping of memory
Proc/version//Kernel version
Proc/sys/kernel//System kernel function
etc/sysctl.conf///kernel parameter configuration path is placed here permanently proc/sys/net/ipv4/tcp_max_tw_buckets put it into effect here when run, a lot of people want to start on the boot will open/etc/ Rc.local inside add echo 0 >proc/sys/net/ipv4/tcp_max_tw_buckets, this kernel tuning is the same
Proc/cpuinfo//processor information, such as type, manufacturer and model etc.
Proc/meminfo//System memory Information
Proc/devices//List of all devices configured by the current running kernel
PROC/DMA//channel of DMA currently in use
Proc/interrupts//The interrupt being used and the number of interrupts that have been made, this advanced tuning to the back will involve
Proc/ioports//I/O port currently in use
PROC/LOADDAVG//System load information (the busy situation of the system, more accurate, but not enough detailed system indicators). Results of uptime
7. In Linux ls-al//a display hidden files, there will be a point to display the end of such as. Sh This is the hidden file

Ii. Linux file extension
1.windows file extension Pictures: Jpg,jpeg,pug,bmp,gif etc
Content extension: doc,docx,txt,pdf
2.linux system, all documents, ls-l
-rwxrwxr-x. 1 Root2 root2 June 03:18 a.sh
Drwxr-xr-x. 2 Root2 root2 4096 June 19:06 Desktop
-(regular file) common file Touch CP, etc. tool commands created are normal files, all with RM can be deleted
Continue to divide: plain text files (ASCLL) such as etc/hosts binary file z execute command file (binary) data format file data record in, var/log/wtmp file is log logged in data
So how to differentiate these files
File/etc/hosts or with other files can be
[Email protected] ~]$ file/var/log/w
Wpa_supplicant.log wtmp
[Email protected] ~]$ file/var/log/wtmp
/var/log/wtmp:data
[Email protected] ~]$ file/etc/hosts
/etc/hosts:ascii text
[Email protected] ~]$ File/bin/ls
/bin/ls:elf 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for Gnu/linux 2.6.18, Stripped
d (directory) directory file View catalog file Ls-ld ls-f to the directory is to add "/" at the end
Character devices and block devices
Find/dev-type b-exec ls-l {} \;
Find/dev-type B|xargs Ls-l
[Email protected] ~]# Ll-al/dev/tty
crw-rw-rw-. 1 root TTY 5, 0 June 03:37/dev/tty//c the beginning of the character device character device refers to a device that transmits characters in the I/O transmission, such as a keyboard, printer, and so on. Note that in characters, it does not necessarily mean that it is in bytes, because the encoding rules stipulate that 1 characters are 16 bits and 2 bytes in total.
[Email protected] ~]# LL-AL/DEV/SDA
BRW-RW----. 1 root Disk 8, 0 June 01:45/DEV/SDA//b start with a block device disk, optical drive Mknod Kaka C 5 1, creating a Kaka block device
Socket interface File: Mysql.sock, data connection between networks
[Email protected] ~]# Ll/dev/log
srw-rw-rw-. 1 root root 0 June 17:45/dev/log
S.
Symbolic Link File
[Email protected] ~]# LS-LD/ETC/INIT.D
lrwxrwxrwx. 1 root root One June 02:43/etc/init.d-Rc.d/init.d//l
3.linux files can have no extension, primarily for compatibility with Windows
. Tar. tar.gz. tgz. zip. tar.bz means that the compressed file creation command is generally tar,gzip,uzip
. SH represents a shell script file, a program developed through the shell language
. pl represents Perl language files, programs developed in the Perl language
. py represents a Python language file that is developed through the Python language
. html. htm. php. jsp. Do represents a Web language file
. conf represents the system's configuration file
. RPM indicates RPM installation package file

Learning record 004-Directory and file extension

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.