Linux commands 1 ls - List files and directories Syntax: ‘ ls [options] [directory] ’ Example: ls ls - l ls /path/to/directory 2 cd - Change directory Syntax: cd [directory] Example: ‘ cd /path/to/ [ directory ] ’ 3 pwd - Print working directory Syntax: ‘ pwd ’ Example: pwd 4 mkdir - Create a new directory Syntax: ‘ mkdir [directory_name] ’ Example: mkdir new_directory 5 touch - Create a new file Syntax: ‘ touch [file_name] ’ Example: touch new_file.txt 6 rm - Remove files or directories Syntax: ‘ rm [options] [file/directory] ’ Example: rm file.txt rm - r directory 7 cp - Copy files or directories Syntax: ‘ cp [options] [source] [destination] ’ Example: cp file.txt /path/to/destination 8 mv - Move or rename files or directories Syntax: ‘ mv [source] [destination] ’ Example: mv old_file.txt new_file.txt mv file.txt /path/to/destination 9 cat - Concatenate and display file content Syntax: ‘ cat [fi le_name] ’ Example: cat file.txt 10 more - Display file content one page at a time Syntax: ‘ more [file_name] ’ Example: more file.txt 11 less - Display file content one page at a time (similar to more, but with more features) Syntax: ‘ less [file_name] ’ Example: less file.txt 12 head - Display the first few lines of a file Syntax: ‘ head [file_name] ’ Example: head file.txt 13 tail - Display the last few lines of a file Syntax: ‘ tail [file_name] ’ Example: tail file.txt 14 grep - Search for a specific pattern in files Syntax: ‘ grep [pattern] [file_name] ’ Example: grep "pattern" file.txt 15 wc - Count lines, words, and characters in a file Syntax: ‘ wc [options] [file_name] ’ Example: wc file.txt 16 chmod - Change file permissions Syntax: ‘ chmod [permissions] [file_name] ’ Example: chmod 755 file.txt 17 chown - Change file ownership Syntax: ‘ chown [user:group] [file_name] ’ Example: chown user:group file.txt 18 df - Display disk space usage Syntax: ‘ df [options] ’ Example: df - h 19 du - Show disk usage of files an d directories Syntax: ‘ du [options] [directory] ’ Example: du - h /path/to/directory 20 tar - Archive files Syntax: ‘ tar [options] [archive_name] [files/directories] ’ Example: tar - cvf archive.tar files 1 date : The date command can view or change the current date of the system clock. Syntax: c: \ > date ---------------------------------------------------------------------------------- --------------------------------------------------------------- OS PRACTICAL ANS Windows commands belwo 2 Time: T he time command can view or change the current time of the system. Syntax: c: \ > date ---------------------------------------------------------------------------------- --------------------------------------------------------------- 3 .Prompt: The prompt com mand allows us to change the MS - DOS prompt to display information. Syntax: PROMPT[Text] // d for date / t for time show Example : prompt $d / $t ------------------------------------------------------------------------------------------------- -------- ---------------------------------------- 4. md : creates a directory or subdirectory in a specific path or disk. Syntax: c: \ md [drive] path <directory name> Example: C: \ >md abc --------------------------------------------------------------------- ------------------------------------ ----------------------------------- 5 . Cd : CD Change directory is a command used to switch directories CD \ goes to the root of the drive. CD.. goes back one directory. Syntax: CD[D] [Drive:] [path] Example: C: \ Users \ O mega>cd \ --------------------------------------------------------------------------------------------------------- ----------------------------------- 6 . rd : RD command is used to remove a particular directory or subdirectory from the disk. Only an empty directory or subd Brectory subdirectory can remove. Syntax: rd [drive:] path <directory name> Example: C: \ > rd test 7. Copy: Allows us to copy one or more files to an alternate location. Syntax: copy [/D] [/V] [/N] [A|B] [+Source [/A|B] [destination[/A |/B]] 8. Xcopy: xcopy is a power ful version of the copy command with additional features; has the capability of moving files, directories, and even whole drives from one location to another. Syntax: xcopy <source> [<destination>] [/w] [/p] [/v] [/q] Example: C: \ abc> xcopy *.* /h test 9. chkdsk: checks the file sy stem and file system meatadata of a volume for logical and physical error. If used without parameter, chkdsk display only the status of the volume and does not fix any errors. If uesd with /f /r /x or /s parameter. It f8xes errors on the volume. Synatx : chkdsk [<volume>[[path]<filename>] [/f ][ /r ][/x ] [/s] ] --------------------------------------------------------------------------------------------------------- ------------------------------ 10. Defrag : locates and consolidates fragmented file on lo cal volumes to impore system performance. Syntax : defrag <volume> [<parameters>] Example: defrag c: /u /v --------------------------------------------------------------------------------------------------------- --------------------------- 10 . Format: The format command creates a new rost directory and file system for the dick. It the Can also check disk, and it for con bad areas on delete all data on the disk. To be able to we a new disk, you must first the disk. use this command to format Syntax: Format drive name>: Example: C: \ > format a; Fidsk: The fdisk commond is used to create and delete partitions on t he hard drive in earlier version of ms - pas and windows. Syntax: C: \ > fdisk [/status] /x Example: Cls: It is used to clear the cluster screen. --------------------------------------------------------------------------------------------------------- --------- ------------------ 14 . del: del command is used to delete files from the computer. Syntax: del[/P] [/F] [/S] [/Q] [/A] [[: attributes]] names 15. move: Allows us to move files or directories from one folder to another or from one drive to another. Syntax: move [/Y | - Y] [drive:] [path]filename [,...] destination. 16 echo : echo is one of the most commonly and widely used built - in commands that is typically used in scripting language and batch files to display a line of text/string on standard output or a file Syntax: ECHO [ON |OFF] ECHO[message] Type echo without parameters to display the current echo settings. Example: C: \ >echo “hi” Hi --------------------------------------------------------------------------------------------------------- ------------------- ------ 17 Diskcomp Compares the content of two floppy disks. If used without parameter, diskcompuses the current drive to compare both disks. diskemp [<doives >: [<chive2>:]] Disk copy - Copies the Contents of the floppy disk in the source. Drives to a for matted or unformatted floppy disk in the desti - nation drive. If used with parameters, diskcopy uses the Current drive for the source disk and the destination disk. Syntax - diskcopy [<drive1>: [<drive>2:]] [/v] 18 - diskpart : - The diskpart command interpreter helps you manage your Computer's drive (disks, partitions, volumes or virtual hard disks.. Syntax : - diskpart <parameters> 19 Doskey : calls doskey.exe ,which rec alss previously enterd commands - line commands, edit commands line, and creates macros. 20 fc : FC or file compare, is used to compare two files against each other. Once completed fc returns lines that differ between the two files. If no line differs, you wil l receive a message indicating no difference encountered. Syntax:Fc [options] file1 file2 Example: D: \ >fc f1.txt f2.txt 21 find : Allows us to search for text within a file. Syntax: find [SWITCH]” String” [Pathname/s] Example: C: \ >ren a.txt b.txt 22 rename : Use d to rename files and directories from the original name to a new name. Syntax: ren [drive:] [path] [filename1] [filename2] Example: C: \ >ren a.txt b.txt 23 set : Allows you to change one variable or string to another. Syntax: [variable=[string]] Example: set path=c: \ windows \ command 24 type : Allows the user to see the contents of a file. To edit the files, the user would need to use either edit or copy content. Syntax: Type[drive:] [path] filename Example: C: \ >type t1.txt 25 ver : Displays the version of MS - DOS or if running windows 95 or above the version of windows. Syntax: ver Example: C: \ Users \ abc>ver Case Study of Android O.S.: - Architecture: Android follows a layered architecture that consists of the following components: 1. Linux Kernel: Android is built on top of the Linux kernel, which provides core operating system services such as process management, memory management, devicedrivers, and security. 2. Libraries: Android includes a set of libraries written in C/C++ that provide essentialfunctionality to applications, such as graphics rendering, database access, and Networking. 3. Android Runtime (ART): It is the runtime environment in which Android applicationsrun. ART utilizes ahead - of - time (AOT) and just - in - time (JIT ) compilation techniques to optimize application performance. 4. Application Framework: The framework provides a set of APIs and tools for developers to build applications. It includes components such as activities, services,content providers, and broadcas t receivers. 5. Applications: These are the end - user applications that run on the Android platform,such as web browsers, email clients, and social media apps Services: Android OS provides various services that enhance the functionality of the platform, including: 1. Activity Manager: Manages the lifecycle of activities and their interactions. 2. Package Manager: Handl es the installation, removal, and management of applications. 3. Notification Manager: Manages the display of notifications to the user. 4. Location Manager: Provides access to location - based services such as GPS and network location. 5. Telephony Manag er: Offers access to telephony - related services such as making calls and sending messages.