SlideShare ist ein Scribd-Unternehmen logo
1 von 10
Introduction to Unix and OS
Module 2
More File Attributes
Dr. Girisha G S
Dept. of CSE
SoE,DSU, Bengaluru
Agenda
• File System and inodes
• Hard links – ln command
• umask command
• find command
File Systems and inodes
File system:
- Each physical drive can be divided into several partitions
- Each partition can contain one file system
- Each file system has its own inode table
- All attributes of a file except its name and contents are available in a table – inode
(index node), accessed by the inode number
- Each file is assigned an inode number which is unique within the file system
- The inode contains the following attributes of a file:
- To know inode number of a file, issue the ls command with –i option:
$ ls -il myfile.txt
9059 -rw-r--r-- 1 kumar metal 51813 Jan 31 11:15 myfile
Where, 9059 is the inode number
Hard Links
- A Unix file may have multiple names
- A hard link is a reference to an existing file, not a copy of a file
- A hard link is used to provide alternate means of referencing a file
-rw-rw-r- - 1 guest other 72 sep 12 09:59 emp.lst
- Link count corresponds to number of files that reference the original file.
This count is normally 1 when the file is created
- To see the hard link count of a file, use the ls -l command, the second
column really is the number of hard links:
Link count
$ ls –l emp.lst
ln – creating hard links
- A file is linked with the ln command which takes two filenames as
arguments
Syntax: ln [options] existing_filename new_filename
Example: link emp.lst with employee
$ ln emp.lst employee
- The –i option to ls shows that they have the same inode number, meaning
that they are actually one and the same file:
$ ls –li emp.lst employee
29518 -rwxr-xr-x 2 kumar metal 915 may 4 09:58 emp.lst
29518 -rwxr-xr-x 2 kumar metal 915 may 4 09:58 employee
- The link count, which is normally one for unlinked files, is shown to be two
umask
- Umask value is used to set the default permission of a file and
directory while creating
- umask command is used to see the default mask for the file or
directory
- The default permission set for the file and directory upon their
creation is:
rw-rw-rw- (octal 666) for regular files
rwxrwxrwx (octal 777) for directories
- The default value is transformed by subtracting umask value from it to remove
one or more permission
- The computation that takes place during their permission
assignment is shown below
666 777
-022 -022
644 755
- To display the current umask value, use the umask command
$ umask
022
rw-r- -r- - (644) for ordinary files
rwxr-xr-x (755) for directories
- find command recursively examines a directory tree to look for files matching some
criteria, and then takes some action on the selected files.
find : locating files
Syntax:
find path_list selecton_criteria action
- It recursively examines all files specified in path_list
- It then matches each file for one or more selection-criteria
- Finally It takes some action on those selected files
Working of find command
Options for matching criteria
-inum n Selects file having inode no n
-name flname The name of the file for search
-type x What type of file to search for
f- ordinary file
d- directory file
-perm p Find files based permission p
-size n Find files based on size
+n – match files larger than n bytes
-n - match files smaller than n bytes
-user usr Find files owned by user usr
options for action component
-print Prints selected file on standard output
-exec cmd Execute command cmd on a file
-ls Execute ls command on selected files
-mtime x Find files which are based on modification time
+x – modified morethan x days ago
-x – modified less than x days ago
Example 1: Search for files in whole file system with a.out
$ find / -name a.out -print
Example 2: Find and report all files with extension .c in the current
working directory
$ find . -name “*.c” -print
Exercises:
1. Find and report all files begin with an upper case letter
2. Use find command to locate from your current directory the
following
i) all files with extension .html or .HTML
ii) files modified yesterday
3. Use find command to locate the following
i) all symbolic link files with permission 666 in the parent directory
ii) all files with number of links equal to 5
iii) display the content of the file name example.c in the home
directory
File systems and inodes

Weitere ähnliche Inhalte

Was ist angesagt? (19)

Linux commands and file structure
Linux commands and file structureLinux commands and file structure
Linux commands and file structure
 
Basic Unix
Basic UnixBasic Unix
Basic Unix
 
Linux basic commands
Linux basic commandsLinux basic commands
Linux basic commands
 
Linux Basic Commands
Linux Basic CommandsLinux Basic Commands
Linux Basic Commands
 
Introduction to UNIX Command-Lines with examples
Introduction to UNIX Command-Lines with examplesIntroduction to UNIX Command-Lines with examples
Introduction to UNIX Command-Lines with examples
 
Linux commands
Linux commandsLinux commands
Linux commands
 
Basic command ppt
Basic command pptBasic command ppt
Basic command ppt
 
Basic Linux day 2
Basic Linux day 2Basic Linux day 2
Basic Linux day 2
 
Linux commands
Linux commandsLinux commands
Linux commands
 
Basic linux commands
Basic linux commandsBasic linux commands
Basic linux commands
 
Unix(introduction)
Unix(introduction)Unix(introduction)
Unix(introduction)
 
Know the UNIX Commands
Know the UNIX CommandsKnow the UNIX Commands
Know the UNIX Commands
 
Basic 50 linus command
Basic 50 linus commandBasic 50 linus command
Basic 50 linus command
 
Basic
BasicBasic
Basic
 
Unix command
Unix commandUnix command
Unix command
 
Linux class 8 tar
Linux class 8   tar  Linux class 8   tar
Linux class 8 tar
 
Linux commd
Linux commdLinux commd
Linux commd
 
Linux commd
Linux commdLinux commd
Linux commd
 
Linux command for beginners
Linux command for beginnersLinux command for beginners
Linux command for beginners
 

Ähnlich wie File systems and inodes

Ähnlich wie File systems and inodes (20)

Linux ppt
Linux pptLinux ppt
Linux ppt
 
Linux ppt
Linux pptLinux ppt
Linux ppt
 
Unix fundamentals
Unix fundamentalsUnix fundamentals
Unix fundamentals
 
Unix Shell Script - 2 Days Session.pptx
Unix Shell Script - 2 Days Session.pptxUnix Shell Script - 2 Days Session.pptx
Unix Shell Script - 2 Days Session.pptx
 
QSpiders - Unix Operating Systems and Commands
QSpiders - Unix Operating Systems  and CommandsQSpiders - Unix Operating Systems  and Commands
QSpiders - Unix Operating Systems and Commands
 
Linux command line
Linux command lineLinux command line
Linux command line
 
Unix Basics Commands
Unix Basics CommandsUnix Basics Commands
Unix Basics Commands
 
3.1.a linux commands reference
3.1.a linux commands reference3.1.a linux commands reference
3.1.a linux commands reference
 
Linux command line cheatsheet
Linux command line cheatsheetLinux command line cheatsheet
Linux command line cheatsheet
 
2. UNIX OS System Architecture easy.pptx
2. UNIX OS System Architecture easy.pptx2. UNIX OS System Architecture easy.pptx
2. UNIX OS System Architecture easy.pptx
 
Basic unix commands_1
Basic unix commands_1Basic unix commands_1
Basic unix commands_1
 
Unix files
Unix filesUnix files
Unix files
 
Unit 7
Unit 7Unit 7
Unit 7
 
Basic Linux
Basic LinuxBasic Linux
Basic Linux
 
Lession1 Linux Preview
Lession1 Linux PreviewLession1 Linux Preview
Lession1 Linux Preview
 
The Linux Command Cheat Sheet
The Linux Command Cheat SheetThe Linux Command Cheat Sheet
The Linux Command Cheat Sheet
 
14.Linux Command
14.Linux Command14.Linux Command
14.Linux Command
 
Linux Fundamentals
Linux FundamentalsLinux Fundamentals
Linux Fundamentals
 
Linux file system nevigation
Linux file system nevigationLinux file system nevigation
Linux file system nevigation
 
Unit 12 finding and processing files
Unit 12 finding and processing filesUnit 12 finding and processing files
Unit 12 finding and processing files
 

Mehr von Dr. Girish GS

unix- Sort, uniq,tr,grep
unix- Sort, uniq,tr,grepunix- Sort, uniq,tr,grep
unix- Sort, uniq,tr,grepDr. Girish GS
 
unix- the process states, zombies, running jobs in background
unix-  the process states, zombies, running jobs in backgroundunix-  the process states, zombies, running jobs in background
unix- the process states, zombies, running jobs in backgroundDr. Girish GS
 
Customizing the unix environment
Customizing the unix environmentCustomizing the unix environment
Customizing the unix environmentDr. Girish GS
 
Basic regular expression, extended regular expression
Basic regular expression, extended regular expressionBasic regular expression, extended regular expression
Basic regular expression, extended regular expressionDr. Girish GS
 
Loop instruction, controlling the flow of progam
Loop instruction, controlling the flow of progamLoop instruction, controlling the flow of progam
Loop instruction, controlling the flow of progamDr. Girish GS
 
Logic instructions part 1
Logic instructions part 1Logic instructions part 1
Logic instructions part 1Dr. Girish GS
 
Bcd arithmetic instructions
Bcd arithmetic instructionsBcd arithmetic instructions
Bcd arithmetic instructionsDr. Girish GS
 
Bcd and ascii arithmetic instructions
Bcd and ascii arithmetic instructionsBcd and ascii arithmetic instructions
Bcd and ascii arithmetic instructionsDr. Girish GS
 
Ascii arithmetic instructions
Ascii arithmetic instructionsAscii arithmetic instructions
Ascii arithmetic instructionsDr. Girish GS
 
Program control instructions
Program control instructionsProgram control instructions
Program control instructionsDr. Girish GS
 

Mehr von Dr. Girish GS (14)

Unix- the process
Unix-  the processUnix-  the process
Unix- the process
 
unix- Sort, uniq,tr,grep
unix- Sort, uniq,tr,grepunix- Sort, uniq,tr,grep
unix- Sort, uniq,tr,grep
 
unix- the process states, zombies, running jobs in background
unix-  the process states, zombies, running jobs in backgroundunix-  the process states, zombies, running jobs in background
unix- the process states, zombies, running jobs in background
 
Unix - Filters
Unix - FiltersUnix - Filters
Unix - Filters
 
Customizing the unix environment
Customizing the unix environmentCustomizing the unix environment
Customizing the unix environment
 
Basic regular expression, extended regular expression
Basic regular expression, extended regular expressionBasic regular expression, extended regular expression
Basic regular expression, extended regular expression
 
Loop instruction, controlling the flow of progam
Loop instruction, controlling the flow of progamLoop instruction, controlling the flow of progam
Loop instruction, controlling the flow of progam
 
Logic instructions part 1
Logic instructions part 1Logic instructions part 1
Logic instructions part 1
 
Bcd arithmetic instructions
Bcd arithmetic instructionsBcd arithmetic instructions
Bcd arithmetic instructions
 
Bcd and ascii arithmetic instructions
Bcd and ascii arithmetic instructionsBcd and ascii arithmetic instructions
Bcd and ascii arithmetic instructions
 
Ascii arithmetic instructions
Ascii arithmetic instructionsAscii arithmetic instructions
Ascii arithmetic instructions
 
Rotate instructions
Rotate instructionsRotate instructions
Rotate instructions
 
Program control instructions
Program control instructionsProgram control instructions
Program control instructions
 
Memory interface
Memory interfaceMemory interface
Memory interface
 

Kürzlich hochgeladen

UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)
UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)
UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)Dr SOUNDIRARAJ N
 
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)dollysharma2066
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfROCENODodongVILLACER
 
Heart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxHeart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxPoojaBan
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfAsst.prof M.Gokilavani
 
main PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidmain PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidNikhilNagaraju
 
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionSachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionDr.Costas Sachpazis
 
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor CatchersTechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catcherssdickerson1
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxKartikeyaDwivedi3
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile servicerehmti665
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxDeepakSakkari2
 
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsyncWhy does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsyncssuser2ae721
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girlsssuser7cb4ff
 

Kürzlich hochgeladen (20)

POWER SYSTEMS-1 Complete notes examples
POWER SYSTEMS-1 Complete notes  examplesPOWER SYSTEMS-1 Complete notes  examples
POWER SYSTEMS-1 Complete notes examples
 
UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)
UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)
UNIT III ANALOG ELECTRONICS (BASIC ELECTRONICS)
 
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
Call Us ≽ 8377877756 ≼ Call Girls In Shastri Nagar (Delhi)
 
Risk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdfRisk Assessment For Installation of Drainage Pipes.pdf
Risk Assessment For Installation of Drainage Pipes.pdf
 
Heart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptxHeart Disease Prediction using machine learning.pptx
Heart Disease Prediction using machine learning.pptx
 
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdfCCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
CCS355 Neural Networks & Deep Learning Unit 1 PDF notes with Question bank .pdf
 
main PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfidmain PPT.pptx of girls hostel security using rfid
main PPT.pptx of girls hostel security using rfid
 
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Serviceyoung call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
young call girls in Rajiv Chowk🔝 9953056974 🔝 Delhi escort Service
 
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCRCall Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
Call Us -/9953056974- Call Girls In Vikaspuri-/- Delhi NCR
 
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
9953056974 Call Girls In South Ex, Escorts (Delhi) NCR.pdf
 
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptxExploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
Exploring_Network_Security_with_JA3_by_Rakesh Seal.pptx
 
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective IntroductionSachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
Sachpazis Costas: Geotechnical Engineering: A student's Perspective Introduction
 
young call girls in Green Park🔝 9953056974 🔝 escort Service
young call girls in Green Park🔝 9953056974 🔝 escort Serviceyoung call girls in Green Park🔝 9953056974 🔝 escort Service
young call girls in Green Park🔝 9953056974 🔝 escort Service
 
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor CatchersTechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
TechTAC® CFD Report Summary: A Comparison of Two Types of Tubing Anchor Catchers
 
Concrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptxConcrete Mix Design - IS 10262-2019 - .pptx
Concrete Mix Design - IS 10262-2019 - .pptx
 
Call Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile serviceCall Girls Delhi {Jodhpur} 9711199012 high profile service
Call Girls Delhi {Jodhpur} 9711199012 high profile service
 
Biology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptxBiology for Computer Engineers Course Handout.pptx
Biology for Computer Engineers Course Handout.pptx
 
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsyncWhy does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
Why does (not) Kafka need fsync: Eliminating tail latency spikes caused by fsync
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girls
 
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
🔝9953056974🔝!!-YOUNG call girls in Rajendra Nagar Escort rvice Shot 2000 nigh...
 

File systems and inodes

  • 1. Introduction to Unix and OS Module 2 More File Attributes Dr. Girisha G S Dept. of CSE SoE,DSU, Bengaluru
  • 2. Agenda • File System and inodes • Hard links – ln command • umask command • find command
  • 3. File Systems and inodes File system: - Each physical drive can be divided into several partitions - Each partition can contain one file system - Each file system has its own inode table - All attributes of a file except its name and contents are available in a table – inode (index node), accessed by the inode number - Each file is assigned an inode number which is unique within the file system - The inode contains the following attributes of a file:
  • 4. - To know inode number of a file, issue the ls command with –i option: $ ls -il myfile.txt 9059 -rw-r--r-- 1 kumar metal 51813 Jan 31 11:15 myfile Where, 9059 is the inode number Hard Links - A Unix file may have multiple names - A hard link is a reference to an existing file, not a copy of a file - A hard link is used to provide alternate means of referencing a file -rw-rw-r- - 1 guest other 72 sep 12 09:59 emp.lst - Link count corresponds to number of files that reference the original file. This count is normally 1 when the file is created - To see the hard link count of a file, use the ls -l command, the second column really is the number of hard links: Link count $ ls –l emp.lst
  • 5. ln – creating hard links - A file is linked with the ln command which takes two filenames as arguments Syntax: ln [options] existing_filename new_filename Example: link emp.lst with employee $ ln emp.lst employee - The –i option to ls shows that they have the same inode number, meaning that they are actually one and the same file: $ ls –li emp.lst employee 29518 -rwxr-xr-x 2 kumar metal 915 may 4 09:58 emp.lst 29518 -rwxr-xr-x 2 kumar metal 915 may 4 09:58 employee - The link count, which is normally one for unlinked files, is shown to be two
  • 6. umask - Umask value is used to set the default permission of a file and directory while creating - umask command is used to see the default mask for the file or directory - The default permission set for the file and directory upon their creation is: rw-rw-rw- (octal 666) for regular files rwxrwxrwx (octal 777) for directories - The default value is transformed by subtracting umask value from it to remove one or more permission - The computation that takes place during their permission assignment is shown below 666 777 -022 -022 644 755 - To display the current umask value, use the umask command $ umask 022 rw-r- -r- - (644) for ordinary files rwxr-xr-x (755) for directories
  • 7. - find command recursively examines a directory tree to look for files matching some criteria, and then takes some action on the selected files. find : locating files Syntax: find path_list selecton_criteria action - It recursively examines all files specified in path_list - It then matches each file for one or more selection-criteria - Finally It takes some action on those selected files Working of find command Options for matching criteria -inum n Selects file having inode no n -name flname The name of the file for search -type x What type of file to search for f- ordinary file d- directory file -perm p Find files based permission p
  • 8. -size n Find files based on size +n – match files larger than n bytes -n - match files smaller than n bytes -user usr Find files owned by user usr options for action component -print Prints selected file on standard output -exec cmd Execute command cmd on a file -ls Execute ls command on selected files -mtime x Find files which are based on modification time +x – modified morethan x days ago -x – modified less than x days ago Example 1: Search for files in whole file system with a.out $ find / -name a.out -print
  • 9. Example 2: Find and report all files with extension .c in the current working directory $ find . -name “*.c” -print Exercises: 1. Find and report all files begin with an upper case letter 2. Use find command to locate from your current directory the following i) all files with extension .html or .HTML ii) files modified yesterday 3. Use find command to locate the following i) all symbolic link files with permission 666 in the parent directory ii) all files with number of links equal to 5 iii) display the content of the file name example.c in the home directory

Hinweis der Redaktion

  1. A file is a collection of data items stored on disk. A UNIX file system is a collection of files and directories stored on disk in a hierarchical structure. All other files and directories on the system, regardless of what physical storage device they may reside on, are located below the root The root directory is represented by the / (forward slash) character.Each file system is stored in a separate whole disk partition. An Inode number points to an Inode. An Inode is a data structure that stores the following information about a file : Please note that, neither the name of the file nor the inode number is stored in the inode Unix divided physical disks into logical disks called partitions. Each partition is a standalone file system
  2. "ls -i" lists the inode of a file The "-i" option lists the inode number before the filename A separate link exists to the same file contents When you execute the command ls -l in UNIX, you get detailed information about files: permissions, file size, date of last modification, etc. A while ago, I got a question from one of my students who wondered what the second column meant. According to the documentation, it’s the “number of hard links,”  but what does that actually mean? the number of hard links.  file with a link count of only 1 has no (other) hard links.  A file with more than 1 link has other name(s)
  3. After the above command, user may refer to the same file either with emp.lst or employee
  4. T On a Linux system, each file and directory is assigned access rights for the owner of the file, the members of a group of related users, and everybodyo display the current umask value, use the umask command
  5. The find command is used to locate files on a unix system. Find will search ant set directories you specify for files that match the suppied criteria. search for files in a directory hierarchy. the search can be based on different criteria, and the matching files can be run through defined actions To find all the files whose name is a.out in a current working directory.: Path_list: directory to start searching Criteria: criteria for the actual search Action: action you want to take on the files found -name flname: searches for a certain filename flname -type x: searches for files of type x where x is -user usr : searches for files owned by user usr
  6. -size n: searches for files with a size of n