Linux Sysfs Questions & Answers – 3

«
»
This set of Linux / Unix questions and answers focuses on sysfs. This is set 3.

1. Sysfs is initialised in ______ file via sysfs_init function.
a) fs/sysfs/mount.c
b) sysfs/mount.c
c) fs/mount.c
c) none of the mentioned
View Answer

Answer: a
Explanation: None.

2. Kernel objects are exported as _____ via sysfs.
a) regular files
b) symbolic links
c) directories
d) none of the mentioned
View Answer

Answer: c
Explanation: None.
advertisement

3. Sysfs internally stores the pointer to the ____ that implements the directory in the file system.
a) kobjects
b) kstructures
c) kinodes
d) none of the mentioned
View Answer

Answer: a
Explanation: None.

4. Attributes can be exported for objects in the form of _______ in the file system.
a) regular files
b) directories
c) symbolic links
d) none of the mentioned
View Answer

Answer: a
Explanation: None.

5. In sysfs every subsystem has
a) a shared attribute structure
b) its own attribute structure
c) a shared & own attribute structure
d) none of the mentioned
View Answer

Answer: b
Explanation: None.
advertisement

6. sysfs is based on
a) rootfs
b) ramfs
c) initramfs
d) none of the mentioned
View Answer

Answer: b
Explanation: None.

7. Which one of the following is a notification to user space from the kernel that something has changed in the system’s configuration?
a) hotplug event
b) module event
c) attach event
d) none of the mentioned
View Answer

Answer: a
Explanation: None.

8. In the device driver model the device_driver object contains the
a) name of the device driver
b) embedded kobjects
c) method for probing a device
d) all of the mentioned
View Answer

Answer: d
Explanation: None.
advertisement

9. A ____ is a higher level view of a device that abstracts out low level implementation details/
a) inode
b) class
b) major number
d) minor number
View Answer

Answer: b
Explanation: None.

10. When a device is removed from the system
a) files and directories of that device in the sysfs are removed automatically
b) all the files of sysfs are preserved until the system turn offs
c) it does not create any change in the sysfs
d) none of the mentioned
View Answer

Answer: a
Explanation: None.

Sanfoundry Global Education & Learning Series – Linux Administration & Programming.
Here’s the list of Best Reference Books in Linux Commands & Shell Programming.
Here’s the list of Best Reference Books in Linux Kernel, Device-Drivers & System Programming.

advertisement

To practice all questions on Linux Administration & Programming, here is complete set of 1000+ Multiple Choice Questions and Answers on Linux.

advertisement
advertisement
advertisement
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He is Linux Kernel Developer & SAN Architect and is passionate about competency developments in these areas. He lives in Bangalore and delivers focused training sessions to IT professionals in Linux Kernel, Linux Debugging, Linux Device Drivers, Linux Networking, Linux Storage, Advanced C Programming, SAN Storage Technologies, SCSI Internals & Storage Protocols such as iSCSI & Fiber Channel. Stay connected with him @ LinkedIn