It is recommended that you read Part 1 and Part 2 before reading this.

This primer will specifically deal with all aspects of filesystem interaction with python. I will do my best to cover very important aspects of OS module but if I miss something, it would be great if you can comment on what’s missing etc.

os Module

There are many functions in these modules. These functions help you interact with the filesystem. The functionality provided is highly portable in a strictly system independent manner.

To get information about the operating, and to get or set the information over the processes, you can employ the following functions. There is an increasing number of list of system dependent functions as well, which can master once you have a mastery of the following.

There are certain functions which manipulate the file descriptors as well. This information is highly important as almost everything in linux/unix is represented through a file or a file descriptor. The directories and communication end points etc are also part of a file methodology. There are few important function which you should learn as a primer.

If you want to manage processes you can use some of the functions from the os module as well. For process management there are many functions which are distributed in other modules as well.

I hope that will help in understanding the operating system interaction as given by python.