what is major and minor?

Answer Posted / ajit mohan b

Major number
============
A number indicating which device driver should be used to
access a particular device. All devices controlled by the
same device driver have a common major device number.

Minor number
============
A number serving as a flag to a device driver.The minor
device numbers are used to distinguish between different
devices and their controllers.

Eg:

# ls -l /dev/sda1
brw-rw---- 1 root disk 8, 1 2008-09-04 08:28 /dev/sda1
rigel:~# ls -l /dev/sda2
brw-rw---- 1 root disk 8, 2 2008-09-04 08:28 /dev/sda2

You can see the major and minor device number (8,1) and
(8,2) in the ls listing for /dev/sdax

# ls -l /dev/scd0
brw-rw---- 1 root cdrom 11, 0 2008-09-04 08:28 /dev/scd0

You can see the major and minor device number (11,0)in the
ls listing for /dev/scd0

Is This Answer Correct ?    6 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How does grep work in linux?

521


How do I find the console in linux?

546


What is whois command?

538


How do I check my system performance?

569


What could be the problem when a command that was issued gave a different result from the last time it was used?

695






What is ulimit in linux?

566


What are the basic command in linux?

536


What is FC command?

493


How do makefiles work?

539


What is clang linux?

560


Enlist some linux networking and troubleshooting commands?

523


Which of the commands will replace all occurrences of the word rate with the word speed in the file racing?

494


What is $$ in shell script?

517


The command ‘umask -S’

590


How do you run a command for a limited time?

587