This document provides an overview of common UNIX commands. It begins by explaining what UNIX is and its multi-user capabilities. It then describes the kernel, structure of the UNIX system, and different flavors of UNIX. It provides details on many common commands like man, ls, cd, cat, more, less, touch, chmod and others. It also covers directories, files, permissions and changing permissions with chmod.
After completing this section, students should be able to log into the Linux system, understand and manipulate the UNIX file system, describe the role of the shell, use basic file commands like cd, ls, cp, and rm, use standard input/output and piping, and understand the UNIX philosophy. The document provides an introduction to UNIX operating systems, shells, file systems, basic commands, and input/output redirection.
This document provides an index of 21 coding topics that include performing arithmetic operations, comparison of numbers, compound interest calculation, prime number checking, and palindrome checking. It also includes displaying a Fibonacci series, calculating simple interest, and swapping numbers without using three variables. The index provides the topic name and number for each item.
File is a container for storing information. It can be treated as a sequence of characters. Unlike the old DOS files, a UNIX file doesn‟t contain eof (end- of –file) mark. A file‟s size is not stored in the file, nor even its name. All files attributes are kept in separate area of hard disk, not accessible to humans, but only to the kernel.ThesisScientist.com
The document provides an overview of essential Linux commands and programs for navigating the file system, examining and managing files, and accessing utilities and documentation. It discusses the development of UNIX and Linux, basic commands for executing utilities like date and hostname, passing arguments to utilities, listing processes with ps, and redirecting outputs. It also covers navigating directories, copying, moving, removing files, and deciphering error messages.
This document provides an introduction and overview of Linux shell scripting. It begins by explaining key concepts like the kernel, shell, processes, redirection and pipes. It then covers variables, writing and running scripts, quotes, arithmetic, arguments, exit status, wildcards, and basic programming commands like echo, if/test, loops, case. The document concludes with more advanced commands like functions, I/O redirection, traps and examples.
This document provides an overview of basic Unix commands including ls, cd, pwd, mkdir, rm, rmdir, cp, find, touch, echo, cat, who, and du. It explains what each command is used for and provides examples of common usages. The document serves as a beginner's guide to learning Unix commands.
This document provides an overview of file administration in Linux. It describes the three types of files in Linux - ordinary disk files which contain user data, special files which represent devices, and directory files which contain other files and directories. It outlines guidelines for naming files and directories, explaining which characters to avoid. It also introduces the file command for determining a file's type and describes the basic Linux directory structure with files and directories organized in a tree format.
This document lists and briefly describes many common Linux terminal commands starting with the letters A through X. It includes basic commands for navigating files and directories, manipulating text, installing and managing software packages, networking tasks, and more. Some of the commands described are apt-get, cd, cp, grep, ls, man, mkdir, mv, ping, rm, tar, top, and vi.
After completing this section, students should be able to log into the Linux system, understand and manipulate the UNIX file system, describe the role of the shell, use basic file commands like cd, ls, cp, and rm, use standard input/output and piping, and understand the UNIX philosophy. The document provides an introduction to UNIX operating systems, shells, file systems, basic commands, and input/output redirection.
This document provides an index of 21 coding topics that include performing arithmetic operations, comparison of numbers, compound interest calculation, prime number checking, and palindrome checking. It also includes displaying a Fibonacci series, calculating simple interest, and swapping numbers without using three variables. The index provides the topic name and number for each item.
File is a container for storing information. It can be treated as a sequence of characters. Unlike the old DOS files, a UNIX file doesn‟t contain eof (end- of –file) mark. A file‟s size is not stored in the file, nor even its name. All files attributes are kept in separate area of hard disk, not accessible to humans, but only to the kernel.ThesisScientist.com
The document provides an overview of essential Linux commands and programs for navigating the file system, examining and managing files, and accessing utilities and documentation. It discusses the development of UNIX and Linux, basic commands for executing utilities like date and hostname, passing arguments to utilities, listing processes with ps, and redirecting outputs. It also covers navigating directories, copying, moving, removing files, and deciphering error messages.
This document provides an introduction and overview of Linux shell scripting. It begins by explaining key concepts like the kernel, shell, processes, redirection and pipes. It then covers variables, writing and running scripts, quotes, arithmetic, arguments, exit status, wildcards, and basic programming commands like echo, if/test, loops, case. The document concludes with more advanced commands like functions, I/O redirection, traps and examples.
This document provides an overview of basic Unix commands including ls, cd, pwd, mkdir, rm, rmdir, cp, find, touch, echo, cat, who, and du. It explains what each command is used for and provides examples of common usages. The document serves as a beginner's guide to learning Unix commands.
This document provides an overview of file administration in Linux. It describes the three types of files in Linux - ordinary disk files which contain user data, special files which represent devices, and directory files which contain other files and directories. It outlines guidelines for naming files and directories, explaining which characters to avoid. It also introduces the file command for determining a file's type and describes the basic Linux directory structure with files and directories organized in a tree format.
This document lists and briefly describes many common Linux terminal commands starting with the letters A through X. It includes basic commands for navigating files and directories, manipulating text, installing and managing software packages, networking tasks, and more. Some of the commands described are apt-get, cd, cp, grep, ls, man, mkdir, mv, ping, rm, tar, top, and vi.
This document discusses managing and processing processes in a system. It explains that every running program is a separate process with a unique process ID. It describes how to obtain information on running processes, start new processes, and end processes through various commands. It also covers job control in UNIX, allowing users to start, suspend, resume, and kill groups of processes associated with a job.
This document provides an overview of GNU/Linux and Bash basics, including their history, file system structure, users and permissions, processes, and Bash functionality. It covers topics such as files and directories, links, file types, locations in the file system, users and groups, process states and signals, the Bash command line interface versus scripts, variables, file streams and pipelines, text processing utilities, program execution and process management, file system management, permissions, and basic network tasks. The document is intended to introduce users to fundamental Linux and Bash concepts.
This document provides an overview of the vi editor and standard input/output redirection in Unix/Linux. It begins with an introduction to vi, describing how to start and end a vi session, cursor movement commands, text insertion/deletion commands, searching, and find/replace. It then covers common filters like grep, sort, find, cut, and tr. The last section discusses input/output redirection, the standard files, and how to redirect input, output, errors, and combine redirections. The document is intended as a tutorial for learning basic vi and I/O redirection skills.
Linux uses a hierarchical file system structure with directories like /bin, /sbin, /etc to organize binaries, configuration files, and other resources. Users can navigate this structure using commands like cd, ls, and pwd. Files can be viewed, copied, moved, deleted and have their permissions and attributes modified using commands like cat, cp, mv, rm, chmod and chown. Output from commands can be redirected, piped to other commands, or used for command substitution. The find command allows searching for files.
The document provides an overview of common Unix commands for navigating directories, managing files, and examining file contents. It discusses commands for changing directories (cd), printing the working directory (pwd), listing directory contents (ls), creating/deleting directories and files (mkdir, rmdir, touch, cp, rm, mv), and managing file permissions (chown, chgrp, chmod). It also covers commands for reading/writing text files (more, less, cat), finding files (find), identifying file types (file), counting lines (wc), and searching files (grep).
system management -shell programming by gaurav raikarGauravRaikar3
This document discusses shell programming and system administration. It provides an overview of shell scripts, their purpose, and common operations. It also describes the system architecture including hardware, kernel, shell, and utilities. It discusses using VMware and Fedora OS and the Python programming language. Finally, it lists several commands for file system management and viewing system information.
Useful Linux and Unix commands handbookWave Digitech
This article provides practical examples for most frequently used commands in Linux / UNIX. Helpful for Engineers and trainee engineers, Software developers. A handy notes for all Linux & Unix commands.
P2Cinfotech is one of the leading, Online IT Training facilities and Job Consultant, spread all over the world. We have successfully conducted online classes on various Software Technologies that are currently in Demand. To name a few, we provide quality online training for QA, QTP, Manual Testing, HP LoadRunner, BA, Java Technologies.
Unique Features of P2Cinfotech:
1. All online software Training Batches will Be handled by Real time working Professionals only.
2. Live online training like Real time face to face, Instructor ? student interaction.
3. Good online training virtual class room environment.
4. Special Exercises and Assignments to make you self-confident on your course subject.
5. Interactive Sessions to update students with latest Developments on the particular course.
6. Flexible Batch Timings and proper timetable.
7. Affordable, decent and Flexible fee structure.
8. Extended Technical assistance even after completion of the course.
9. 100% Job Assistance and Guidance.
Courses What we cover:
Quality Assurance
Business Analsis
QTp
JAVA
Apps Devlepoment Training
Register for Free DEMO:
www.p2cinfotech.com p2cinfotech@gmail.com +1-732-546-3607 (USA)
This document provides an overview of Section 5 of Course 1 on secure programming. It covers topics like shells and environments, configuration, logging, and calling external programs. The learning objectives are to understand how shells work and how environments can impact security. It also discusses operations management best practices related to these topics. It includes mini-labs on shells where students can explore concepts like relative paths, substitutions and how they can enable exploits. The document emphasizes applying the principle of least privilege and white listing to improve security.
The document provides information about shells in Linux operating systems. It defines what a kernel and shell are, explains why shells are used, describes different types of shells, and provides examples of shell scripting. The key points are:
- The kernel manages system resources and acts as an intermediary between hardware and software. A shell is a program that takes commands and runs them, providing an interface between the user and operating system.
- Shells are useful for automating tasks, combining commands to create new ones, and adding functionality to the operating system. Common shells include Bash, Bourne, C, Korn, and Tcsh.
- Shell scripts allow storing commands in files to automate tasks.
The document provides an overview of basic Linux commands organized into the following sections:
1. General purpose utilities such as date, echo, printf, calculator applications
2. Linux file system structure and commands for viewing file attributes, permissions, ownership
3. Commands for file handling, concatenation, pagination and comparing files
This document discusses shell scripting and provides information on various shells, commands, and scripting basics. It covers:
- Common shells like Bourne, C, and Korn shells. The Bourne shell is typically the default and fastest, while the C shell adds features like alias and history.
- Basic bash commands like cd, ls, pwd, cp, mv, less, cat, grep, echo, touch, mkdir, chmod, and rm.
- The superuser/root user with full privileges and password security best practices.
- How login works and the difference between .login and .cshrc initialization files.
- Exiting or logging out of shells.
This document discusses shells and shell scripting in Linux. It provides information on common Linux shells like Bash, Bourne shell, C shell, etc. It describes the basic functions of shells like command interpretation, I/O redirection, variables, parameters and more. Shell scripts allow automating tasks and complex series of commands. The document also covers shell script basics, special parameters, variables, I/O redirection operators and more shell scripting concepts.
The document discusses namespaces in C#. Key points:
- Namespaces prevent naming conflicts by allowing names to be separated into different declarative regions.
- The .NET Framework uses the System namespace. Other common namespaces include System.IO.
- Namespaces become important as the number of classes, methods, etc. grows to avoid conflicts.
- Namespaces are declared using the namespace keyword followed by the name.
- The using directive imports namespaces so their contents can be accessed without qualification.
- Namespaces can be nested within each other and multiple namespaces of the same name can be declared.
The document provides an overview of Unix and shell scripting. It discusses the history and architecture of Unix operating systems. It then covers various Unix commands and utilities for file management, processes, communication, and system administration. Finally, it describes the basics of shell scripting including variables, conditional statements, loops, and here documents.
The document discusses file and directory permissions in Linux/Unix systems. It describes how permissions are represented and controlled using commands like ls, chmod, and umask. Permissions determine whether a user can read, write, or execute files and view contents of directories. Chmod allows setting permissions for owners, groups and others using letters or numbers. Umask sets default permissions for new files and directories based on permissions being masked.
This document provides an overview of Linux shell scripting (Bash) basics. It discusses writing scripts using editors like vi or vim, setting permissions using chmod, executing scripts, variables, arithmetic operations, file manipulation commands, pipes, reading from files, command substitution, background processes, arrays, output redirection, and input redirection. Examples are provided for many common scripting tasks and commands.
This document provides an overview of various Unix/Linux commands and concepts. It discusses the introduction to Unix including defining an operating system and its functionalities. It describes the evolution and structure of Unix. It covers usage of simple commands like date, who, ls and file commands like cat, cp, mv etc. It explains the Unix file system hierarchy and concepts like input/output redirection and wildcards. It also discusses environmental variables, file permissions and commands related to pipes and filters like sort and grep. Finally, it talks about editors like vi and shell programming concepts.
Chapter 2 Introduction to Unix ConceptsMeenalJabde
The document provides an introduction to Unix concepts including:
1. It describes the architecture of Unix as having 4 layers - hardware, kernel, shell commands, and application layer. The kernel interacts with hardware and manages tasks like memory and process scheduling.
2. It lists some basic Unix commands like ls, echo, printf, who, date, passwd, cal and explains how to combine commands using operators like && and ||.
3. It explains Unix files and directories are organized in a hierarchical tree structure with the root directory at the top. There are different types of files like ordinary, special, pipes and symbolic links.
Linux is an open-source operating system that provides free and secure software. It allows applications and users to access computer devices and functions through the kernel, which manages communication between hardware, software, and processes. Files, directories, programs, and devices are all treated as files in the Linux file system hierarchy, accessed through commands like ls, mkdir, and rmdir.
This document discusses managing and processing processes in a system. It explains that every running program is a separate process with a unique process ID. It describes how to obtain information on running processes, start new processes, and end processes through various commands. It also covers job control in UNIX, allowing users to start, suspend, resume, and kill groups of processes associated with a job.
This document provides an overview of GNU/Linux and Bash basics, including their history, file system structure, users and permissions, processes, and Bash functionality. It covers topics such as files and directories, links, file types, locations in the file system, users and groups, process states and signals, the Bash command line interface versus scripts, variables, file streams and pipelines, text processing utilities, program execution and process management, file system management, permissions, and basic network tasks. The document is intended to introduce users to fundamental Linux and Bash concepts.
This document provides an overview of the vi editor and standard input/output redirection in Unix/Linux. It begins with an introduction to vi, describing how to start and end a vi session, cursor movement commands, text insertion/deletion commands, searching, and find/replace. It then covers common filters like grep, sort, find, cut, and tr. The last section discusses input/output redirection, the standard files, and how to redirect input, output, errors, and combine redirections. The document is intended as a tutorial for learning basic vi and I/O redirection skills.
Linux uses a hierarchical file system structure with directories like /bin, /sbin, /etc to organize binaries, configuration files, and other resources. Users can navigate this structure using commands like cd, ls, and pwd. Files can be viewed, copied, moved, deleted and have their permissions and attributes modified using commands like cat, cp, mv, rm, chmod and chown. Output from commands can be redirected, piped to other commands, or used for command substitution. The find command allows searching for files.
The document provides an overview of common Unix commands for navigating directories, managing files, and examining file contents. It discusses commands for changing directories (cd), printing the working directory (pwd), listing directory contents (ls), creating/deleting directories and files (mkdir, rmdir, touch, cp, rm, mv), and managing file permissions (chown, chgrp, chmod). It also covers commands for reading/writing text files (more, less, cat), finding files (find), identifying file types (file), counting lines (wc), and searching files (grep).
system management -shell programming by gaurav raikarGauravRaikar3
This document discusses shell programming and system administration. It provides an overview of shell scripts, their purpose, and common operations. It also describes the system architecture including hardware, kernel, shell, and utilities. It discusses using VMware and Fedora OS and the Python programming language. Finally, it lists several commands for file system management and viewing system information.
Useful Linux and Unix commands handbookWave Digitech
This article provides practical examples for most frequently used commands in Linux / UNIX. Helpful for Engineers and trainee engineers, Software developers. A handy notes for all Linux & Unix commands.
P2Cinfotech is one of the leading, Online IT Training facilities and Job Consultant, spread all over the world. We have successfully conducted online classes on various Software Technologies that are currently in Demand. To name a few, we provide quality online training for QA, QTP, Manual Testing, HP LoadRunner, BA, Java Technologies.
Unique Features of P2Cinfotech:
1. All online software Training Batches will Be handled by Real time working Professionals only.
2. Live online training like Real time face to face, Instructor ? student interaction.
3. Good online training virtual class room environment.
4. Special Exercises and Assignments to make you self-confident on your course subject.
5. Interactive Sessions to update students with latest Developments on the particular course.
6. Flexible Batch Timings and proper timetable.
7. Affordable, decent and Flexible fee structure.
8. Extended Technical assistance even after completion of the course.
9. 100% Job Assistance and Guidance.
Courses What we cover:
Quality Assurance
Business Analsis
QTp
JAVA
Apps Devlepoment Training
Register for Free DEMO:
www.p2cinfotech.com p2cinfotech@gmail.com +1-732-546-3607 (USA)
This document provides an overview of Section 5 of Course 1 on secure programming. It covers topics like shells and environments, configuration, logging, and calling external programs. The learning objectives are to understand how shells work and how environments can impact security. It also discusses operations management best practices related to these topics. It includes mini-labs on shells where students can explore concepts like relative paths, substitutions and how they can enable exploits. The document emphasizes applying the principle of least privilege and white listing to improve security.
The document provides information about shells in Linux operating systems. It defines what a kernel and shell are, explains why shells are used, describes different types of shells, and provides examples of shell scripting. The key points are:
- The kernel manages system resources and acts as an intermediary between hardware and software. A shell is a program that takes commands and runs them, providing an interface between the user and operating system.
- Shells are useful for automating tasks, combining commands to create new ones, and adding functionality to the operating system. Common shells include Bash, Bourne, C, Korn, and Tcsh.
- Shell scripts allow storing commands in files to automate tasks.
The document provides an overview of basic Linux commands organized into the following sections:
1. General purpose utilities such as date, echo, printf, calculator applications
2. Linux file system structure and commands for viewing file attributes, permissions, ownership
3. Commands for file handling, concatenation, pagination and comparing files
This document discusses shell scripting and provides information on various shells, commands, and scripting basics. It covers:
- Common shells like Bourne, C, and Korn shells. The Bourne shell is typically the default and fastest, while the C shell adds features like alias and history.
- Basic bash commands like cd, ls, pwd, cp, mv, less, cat, grep, echo, touch, mkdir, chmod, and rm.
- The superuser/root user with full privileges and password security best practices.
- How login works and the difference between .login and .cshrc initialization files.
- Exiting or logging out of shells.
This document discusses shells and shell scripting in Linux. It provides information on common Linux shells like Bash, Bourne shell, C shell, etc. It describes the basic functions of shells like command interpretation, I/O redirection, variables, parameters and more. Shell scripts allow automating tasks and complex series of commands. The document also covers shell script basics, special parameters, variables, I/O redirection operators and more shell scripting concepts.
The document discusses namespaces in C#. Key points:
- Namespaces prevent naming conflicts by allowing names to be separated into different declarative regions.
- The .NET Framework uses the System namespace. Other common namespaces include System.IO.
- Namespaces become important as the number of classes, methods, etc. grows to avoid conflicts.
- Namespaces are declared using the namespace keyword followed by the name.
- The using directive imports namespaces so their contents can be accessed without qualification.
- Namespaces can be nested within each other and multiple namespaces of the same name can be declared.
The document provides an overview of Unix and shell scripting. It discusses the history and architecture of Unix operating systems. It then covers various Unix commands and utilities for file management, processes, communication, and system administration. Finally, it describes the basics of shell scripting including variables, conditional statements, loops, and here documents.
The document discusses file and directory permissions in Linux/Unix systems. It describes how permissions are represented and controlled using commands like ls, chmod, and umask. Permissions determine whether a user can read, write, or execute files and view contents of directories. Chmod allows setting permissions for owners, groups and others using letters or numbers. Umask sets default permissions for new files and directories based on permissions being masked.
This document provides an overview of Linux shell scripting (Bash) basics. It discusses writing scripts using editors like vi or vim, setting permissions using chmod, executing scripts, variables, arithmetic operations, file manipulation commands, pipes, reading from files, command substitution, background processes, arrays, output redirection, and input redirection. Examples are provided for many common scripting tasks and commands.
This document provides an overview of various Unix/Linux commands and concepts. It discusses the introduction to Unix including defining an operating system and its functionalities. It describes the evolution and structure of Unix. It covers usage of simple commands like date, who, ls and file commands like cat, cp, mv etc. It explains the Unix file system hierarchy and concepts like input/output redirection and wildcards. It also discusses environmental variables, file permissions and commands related to pipes and filters like sort and grep. Finally, it talks about editors like vi and shell programming concepts.
Chapter 2 Introduction to Unix ConceptsMeenalJabde
The document provides an introduction to Unix concepts including:
1. It describes the architecture of Unix as having 4 layers - hardware, kernel, shell commands, and application layer. The kernel interacts with hardware and manages tasks like memory and process scheduling.
2. It lists some basic Unix commands like ls, echo, printf, who, date, passwd, cal and explains how to combine commands using operators like && and ||.
3. It explains Unix files and directories are organized in a hierarchical tree structure with the root directory at the top. There are different types of files like ordinary, special, pipes and symbolic links.
Linux is an open-source operating system that provides free and secure software. It allows applications and users to access computer devices and functions through the kernel, which manages communication between hardware, software, and processes. Files, directories, programs, and devices are all treated as files in the Linux file system hierarchy, accessed through commands like ls, mkdir, and rmdir.
The document discusses Linux commands for file management, viewing and shell programming. It describes common commands like ls, cd, cp, mv, rm, mkdir which allow navigating and manipulating files and directories. It also covers commands for viewing file contents like cat, head, tail, grep. Commands for compression like tar, gzip, zip and decompression like gunzip, unzip are mentioned. The document also has a section on shell programming which explains how to write shell scripts using commands and variables. It provides examples of using pipes, redirections and command options.
The document discusses the UNIX operating system. It describes UNIX as a stable, multi-user, multi-tasking system used for servers, desktops and laptops. It also discusses the different components that make up the UNIX system, including the kernel, shell, and programs. It explains the directory structure and file hierarchy with the root directory at the top. It provides examples of different types of files and concludes by describing some basic date and time commands in UNIX.
The document provides an overview of shells, shell scripting, and the UNIX file system. It discusses what shells are and common shells like tcsh, csh, ksh, bash, and sh. It covers shell configuration files like .cshrc and .bashrc, environment variables, the ~/bin directory, and aliases. It also gives examples of customizing shells like tcsh and bash as well as login/logout files like .login and .logout.
Linux is a fully-networked, multi-user, multitasking operating system similar to Unix. It was created in 1991 by Linus Torvalds and is now used widely due to its low cost, stability, and ability to run on different hardware platforms. Linux uses a command line interface where users log in and issue commands to perform tasks like copying files, installing software, and checking system resources. Common commands include ls to list files, cd to change directories, and man to view manuals.
This document provides an overview of Linux, shells, and shell scripts. It begins with a short history of Linux and how it originated from efforts to create an affordable UNIX-like operating system that could run on personal computers. It then defines what a shell is and describes common shell commands. The remainder of the document explains what shell scripts are, how to write them, and includes examples of common scripting elements like variables, conditionals, loops, arithmetic, and file operations.
This document provides an overview of Linux, shells, and shell scripts. It begins with a short history of Linux and how it originated from efforts to create an affordable UNIX-like operating system that could run on personal computers. It then defines what a shell is and describes common shell commands. The remainder of the document explains what shell scripts are, how to write them, and includes examples of common scripting elements like variables, conditionals, loops, arithmetic, and file operations.
This document provides an introduction to Unix and Linux operating systems. It discusses what Unix is, how it relates to Linux, and why Unix/Linux is useful for programmers and scientists. It then covers how to connect to a Unix/Linux system using a terminal, what shells are, navigating the file system using commands like ls, cd, pwd, and how to manage files with commands like cp, mv, rm. The document also discusses file permissions, running programs, and input/output redirection techniques like piping.
This document provides an overview of Red Hat Linux and Linux fundamentals. It discusses Linux origins with the GNU project and Linus Torvalds' creation of the Linux kernel. It also describes open source software, different Red Hat distributions like Red Hat Enterprise Linux and Fedora, Linux principles like treating everything as a file, and basic Linux commands. The document is divided into units covering Linux usage basics, running commands and getting help, and browsing the filesystem.
Linux is a fully-featured open source operating system based on Unix. It was created by Linus Torvalds in 1991 and has since grown in popularity. Linux uses a kernel to manage hardware resources and runs on multiple hardware platforms. Users interact with Linux through a shell and can execute commands, manage files and directories, and perform other tasks. Common Linux commands include ls, cd, pwd, cp, and more.
This document provides an introduction to Linux and its components. It discusses that Linux is an operating system like Windows and Mac OS that manages communication between hardware and software. It then outlines the course curriculum which will cover topics such as the Linux kernel, shell, commands, file system, permissions and networking tools. Several sections then provide more detail on key aspects of Linux including what an operating system is, the parts of an operating system like the kernel and shell, and why Linux is widely used and advantageous over other operating systems.
Unix/Linux is an operating system developed in the 1960s that uses a command line interface. It is the predecessor to Linux, which is now a widely popular open-source variant of Unix. The document provides an overview of basic Unix/Linux commands and concepts for navigating files and directories, editing and manipulating files, running programs, and accessing remote systems. It explains commands like ls, cd, pwd, cat, less, grep, diff, kill, and scp.
This document provides an introduction and overview of the UNIX operating system. It discusses that UNIX is an operating system, like Windows, that manages communication between software and hardware. Popular versions of UNIX include Linux and Android. The document outlines reasons for using UNIX such as reliability, low/no cost, and open source access. It describes the core components of UNIX including the kernel, bootloader, daemons, and shells. Key features like being portable, multi-user, and providing security are highlighted. Common UNIX commands and utilities are listed along with file permissions, redirection, pipes, and filters.
The document discusses Linux commands for file management and viewing. It describes commands for navigating directories (cd), changing file permissions (chmod), copying files (cp), finding files (find), listing directory contents (ls), creating and removing directories (mkdir, rmdir), moving and renaming files (mv), viewing file contents (cat, head, tail), comparing files (cmp, diff), searching files (grep), and more. It also covers commands for compressing, archiving, and backing up files like tar, gzip, zip, and commands for counting, sorting, and filtering file contents.
The document provides information about an upcoming UNIX and Shell Scripting workshop, including contact information for the workshop instructor R. Chockalingam, and covers topics that will be discussed such as the architecture and components of the UNIX operating system, basic UNIX commands, text editors, the file system structure, flags and arguments, and more.
The document summarizes the contents of a training presentation on the Unix and GNU/Linux command line. It covers shells and command line interpreters, the filesystem structure including common directories, file handling commands like ls, cd, cp, and an introduction to pipes and I/O redirection. Special files and directories like symlinks, devices, and ~ (home directory) are explained. File permissions and ownership are also mentioned.
The document summarizes the contents of a training on the Unix and GNU/Linux command line. It covers shells and command line interpreters, the filesystem structure, file handling commands like ls, cd, cp, and file permissions. It also discusses standard input/output redirection, pipes, process control and environment variables. The training contents are organized into 5 sections covering these topics at an introductory level.
This document provides a summary of the Unix and GNU/Linux command line. It begins with an overview of files and file systems in Unix, including that everything is treated as a file. It then discusses command line interpreters (shells), and commands for handling files and directories like ls, cd, cp, and rm. It also covers redirecting standard input/output, pipes, and controlling processes. The document is intended as training material and provides a detailed outline of its contents.
This document provides an introduction to Unix/Linux operating systems. It discusses that Unix was developed in the 1960s and is the predecessor to Linux. It then covers connecting to Unix/Linux systems, the shell interface, navigating the file system using commands like ls, cd, pwd. It also summarizes key commands for working with files like cp, mv, rm and editing files. Finally, it touches on permissions, running programs, input/output redirection and accessing remote systems using ssh/scp.
Digital Marketing Trends in 2024 | Guide for Staying AheadWask
https://www.wask.co/ebooks/digital-marketing-trends-in-2024
Feeling lost in the digital marketing whirlwind of 2024? Technology is changing, consumer habits are evolving, and staying ahead of the curve feels like a never-ending pursuit. This e-book is your compass. Dive into actionable insights to handle the complexities of modern marketing. From hyper-personalization to the power of user-generated content, learn how to build long-term relationships with your audience and unlock the secrets to success in the ever-shifting digital landscape.
Salesforce Integration for Bonterra Impact Management (fka Social Solutions A...Jeffrey Haguewood
Sidekick Solutions uses Bonterra Impact Management (fka Social Solutions Apricot) and automation solutions to integrate data for business workflows.
We believe integration and automation are essential to user experience and the promise of efficient work through technology. Automation is the critical ingredient to realizing that full vision. We develop integration products and services for Bonterra Case Management software to support the deployment of automations for a variety of use cases.
This video focuses on integration of Salesforce with Bonterra Impact Management.
Interested in deploying an integration with Salesforce for Bonterra Impact Management? Contact us at sales@sidekicksolutionsllc.com to discuss next steps.
Programming Foundation Models with DSPy - Meetup SlidesZilliz
Prompting language models is hard, while programming language models is easy. In this talk, I will discuss the state-of-the-art framework DSPy for programming foundation models with its powerful optimizers and runtime constraint system.
Fueling AI with Great Data with Airbyte WebinarZilliz
This talk will focus on how to collect data from a variety of sources, leveraging this data for RAG and other GenAI use cases, and finally charting your course to productionalization.
How to Interpret Trends in the Kalyan Rajdhani Mix Chart.pdfChart Kalyan
A Mix Chart displays historical data of numbers in a graphical or tabular form. The Kalyan Rajdhani Mix Chart specifically shows the results of a sequence of numbers over different periods.
Digital Banking in the Cloud: How Citizens Bank Unlocked Their MainframePrecisely
Inconsistent user experience and siloed data, high costs, and changing customer expectations – Citizens Bank was experiencing these challenges while it was attempting to deliver a superior digital banking experience for its clients. Its core banking applications run on the mainframe and Citizens was using legacy utilities to get the critical mainframe data to feed customer-facing channels, like call centers, web, and mobile. Ultimately, this led to higher operating costs (MIPS), delayed response times, and longer time to market.
Ever-changing customer expectations demand more modern digital experiences, and the bank needed to find a solution that could provide real-time data to its customer channels with low latency and operating costs. Join this session to learn how Citizens is leveraging Precisely to replicate mainframe data to its customer channels and deliver on their “modern digital bank” experiences.
Taking AI to the Next Level in Manufacturing.pdfssuserfac0301
Read Taking AI to the Next Level in Manufacturing to gain insights on AI adoption in the manufacturing industry, such as:
1. How quickly AI is being implemented in manufacturing.
2. Which barriers stand in the way of AI adoption.
3. How data quality and governance form the backbone of AI.
4. Organizational processes and structures that may inhibit effective AI adoption.
6. Ideas and approaches to help build your organization's AI strategy.
GraphRAG for Life Science to increase LLM accuracyTomaz Bratanic
GraphRAG for life science domain, where you retriever information from biomedical knowledge graphs using LLMs to increase the accuracy and performance of generated answers
A Comprehensive Guide to DeFi Development Services in 2024Intelisync
DeFi represents a paradigm shift in the financial industry. Instead of relying on traditional, centralized institutions like banks, DeFi leverages blockchain technology to create a decentralized network of financial services. This means that financial transactions can occur directly between parties, without intermediaries, using smart contracts on platforms like Ethereum.
In 2024, we are witnessing an explosion of new DeFi projects and protocols, each pushing the boundaries of what’s possible in finance.
In summary, DeFi in 2024 is not just a trend; it’s a revolution that democratizes finance, enhances security and transparency, and fosters continuous innovation. As we proceed through this presentation, we'll explore the various components and services of DeFi in detail, shedding light on how they are transforming the financial landscape.
At Intelisync, we specialize in providing comprehensive DeFi development services tailored to meet the unique needs of our clients. From smart contract development to dApp creation and security audits, we ensure that your DeFi project is built with innovation, security, and scalability in mind. Trust Intelisync to guide you through the intricate landscape of decentralized finance and unlock the full potential of blockchain technology.
Ready to take your DeFi project to the next level? Partner with Intelisync for expert DeFi development services today!
Driving Business Innovation: Latest Generative AI Advancements & Success StorySafe Software
Are you ready to revolutionize how you handle data? Join us for a webinar where we’ll bring you up to speed with the latest advancements in Generative AI technology and discover how leveraging FME with tools from giants like Google Gemini, Amazon, and Microsoft OpenAI can supercharge your workflow efficiency.
During the hour, we’ll take you through:
Guest Speaker Segment with Hannah Barrington: Dive into the world of dynamic real estate marketing with Hannah, the Marketing Manager at Workspace Group. Hear firsthand how their team generates engaging descriptions for thousands of office units by integrating diverse data sources—from PDF floorplans to web pages—using FME transformers, like OpenAIVisionConnector and AnthropicVisionConnector. This use case will show you how GenAI can streamline content creation for marketing across the board.
Ollama Use Case: Learn how Scenario Specialist Dmitri Bagh has utilized Ollama within FME to input data, create custom models, and enhance security protocols. This segment will include demos to illustrate the full capabilities of FME in AI-driven processes.
Custom AI Models: Discover how to leverage FME to build personalized AI models using your data. Whether it’s populating a model with local data for added security or integrating public AI tools, find out how FME facilitates a versatile and secure approach to AI.
We’ll wrap up with a live Q&A session where you can engage with our experts on your specific use cases, and learn more about optimizing your data workflows with AI.
This webinar is ideal for professionals seeking to harness the power of AI within their data management systems while ensuring high levels of customization and security. Whether you're a novice or an expert, gain actionable insights and strategies to elevate your data processes. Join us to see how FME and AI can revolutionize how you work with data!
Trusted Execution Environment for Decentralized Process MiningLucaBarbaro3
Presentation of the paper "Trusted Execution Environment for Decentralized Process Mining" given during the CAiSE 2024 Conference in Cyprus on June 7, 2024.
Monitoring and Managing Anomaly Detection on OpenShift.pdfTosin Akinosho
Monitoring and Managing Anomaly Detection on OpenShift
Overview
Dive into the world of anomaly detection on edge devices with our comprehensive hands-on tutorial. This SlideShare presentation will guide you through the entire process, from data collection and model training to edge deployment and real-time monitoring. Perfect for those looking to implement robust anomaly detection systems on resource-constrained IoT/edge devices.
Key Topics Covered
1. Introduction to Anomaly Detection
- Understand the fundamentals of anomaly detection and its importance in identifying unusual behavior or failures in systems.
2. Understanding Edge (IoT)
- Learn about edge computing and IoT, and how they enable real-time data processing and decision-making at the source.
3. What is ArgoCD?
- Discover ArgoCD, a declarative, GitOps continuous delivery tool for Kubernetes, and its role in deploying applications on edge devices.
4. Deployment Using ArgoCD for Edge Devices
- Step-by-step guide on deploying anomaly detection models on edge devices using ArgoCD.
5. Introduction to Apache Kafka and S3
- Explore Apache Kafka for real-time data streaming and Amazon S3 for scalable storage solutions.
6. Viewing Kafka Messages in the Data Lake
- Learn how to view and analyze Kafka messages stored in a data lake for better insights.
7. What is Prometheus?
- Get to know Prometheus, an open-source monitoring and alerting toolkit, and its application in monitoring edge devices.
8. Monitoring Application Metrics with Prometheus
- Detailed instructions on setting up Prometheus to monitor the performance and health of your anomaly detection system.
9. What is Camel K?
- Introduction to Camel K, a lightweight integration framework built on Apache Camel, designed for Kubernetes.
10. Configuring Camel K Integrations for Data Pipelines
- Learn how to configure Camel K for seamless data pipeline integrations in your anomaly detection workflow.
11. What is a Jupyter Notebook?
- Overview of Jupyter Notebooks, an open-source web application for creating and sharing documents with live code, equations, visualizations, and narrative text.
12. Jupyter Notebooks with Code Examples
- Hands-on examples and code snippets in Jupyter Notebooks to help you implement and test anomaly detection models.
Skybuffer AI: Advanced Conversational and Generative AI Solution on SAP Busin...Tatiana Kojar
Skybuffer AI, built on the robust SAP Business Technology Platform (SAP BTP), is the latest and most advanced version of our AI development, reaffirming our commitment to delivering top-tier AI solutions. Skybuffer AI harnesses all the innovative capabilities of the SAP BTP in the AI domain, from Conversational AI to cutting-edge Generative AI and Retrieval-Augmented Generation (RAG). It also helps SAP customers safeguard their investments into SAP Conversational AI and ensure a seamless, one-click transition to SAP Business AI.
With Skybuffer AI, various AI models can be integrated into a single communication channel such as Microsoft Teams. This integration empowers business users with insights drawn from SAP backend systems, enterprise documents, and the expansive knowledge of Generative AI. And the best part of it is that it is all managed through our intuitive no-code Action Server interface, requiring no extensive coding knowledge and making the advanced AI accessible to more users.
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc
How does your privacy program stack up against your peers? What challenges are privacy teams tackling and prioritizing in 2024?
In the fifth annual Global Privacy Benchmarks Survey, we asked over 1,800 global privacy professionals and business executives to share their perspectives on the current state of privacy inside and outside of their organizations. This year’s report focused on emerging areas of importance for privacy and compliance professionals, including considerations and implications of Artificial Intelligence (AI) technologies, building brand trust, and different approaches for achieving higher privacy competence scores.
See how organizational priorities and strategic approaches to data security and privacy are evolving around the globe.
This webinar will review:
- The top 10 privacy insights from the fifth annual Global Privacy Benchmarks Survey
- The top challenges for privacy leaders, practitioners, and organizations in 2024
- Key themes to consider in developing and maintaining your privacy program
Freshworks Rethinks NoSQL for Rapid Scaling & Cost-EfficiencyScyllaDB
Freshworks creates AI-boosted business software that helps employees work more efficiently and effectively. Managing data across multiple RDBMS and NoSQL databases was already a challenge at their current scale. To prepare for 10X growth, they knew it was time to rethink their database strategy. Learn how they architected a solution that would simplify scaling while keeping costs under control.
This presentation provides valuable insights into effective cost-saving techniques on AWS. Learn how to optimize your AWS resources by rightsizing, increasing elasticity, picking the right storage class, and choosing the best pricing model. Additionally, discover essential governance mechanisms to ensure continuous cost efficiency. Whether you are new to AWS or an experienced user, this presentation provides clear and practical tips to help you reduce your cloud costs and get the most out of your budget.
Best 20 SEO Techniques To Improve Website Visibility In SERPPixlogix Infotech
Boost your website's visibility with proven SEO techniques! Our latest blog dives into essential strategies to enhance your online presence, increase traffic, and rank higher on search engines. From keyword optimization to quality content creation, learn how to make your site stand out in the crowded digital landscape. Discover actionable tips and expert insights to elevate your SEO game.
2. 2
What is Unix?
A multi-user networked operating system
» “Operating System”
– Handles files, running other programs, input/output
– Looks like DOS…but more powerful
– The internet was designed on it, thus networking is an
intrinsic part of the system
» “Multi-user”
– Every user has different settings and permissions
– Multiple users can be logged in simultaneously
3. 3
Kernel (OS)
Interacts directly with the hardware
through device drivers
Provides sets of services to programs,
insulating these programs from the
underlying hardware
Manages memory, controls access, maintains
file system, handles interrupts, allocates
resources of the computer
Programs interact with the kernel
through system calls
4. 4
Structure of the UNIX system
Applications
Shell
Kernel (OS)
Hardware
There are many
standard applications:
• file system
commands
• text editors
• compilers
• text processing
5. 5
Unix and Users
Most flavors of Unix (there are many)
provide the same set of applications
to support humans (commands and
shells).
Although these user interface programs
are not part of the OS directly, they are
standardized enough that learning your
way around one flavor of Unix is enough.
6. 6
Flavors of Unix
There are many versions of Unix that
are used by lots of people:
SysV (from AT&T)
BSD (from Berkeley)
Solaris (Sun)
IRIX (SGI)
AIX (IBM)
LINUX (free software)
7. 7
Unix vs. Linux
Age
» Unix: born in 1970 at AT&T/Bell Labs
» Linux: born in 1992 in Helsinki, Finland
Sun, IBM, HP are the 3 largest vendors of Unix
» These Unix flavors all run on custom hardware
Linux is FREE!
» Linux was written for Intel/x86, but runs on many platforms
8. 8
UNIX Shell
A system program that allows a user to execute:
» shell functions (internal commands)
» other programs (external commands)
» shell scripts
Linux/UNIX has a bunch of them, the most common
are
» tcsh, an expanded version of csh (Bill Joy, Berkley, Sun)
» bash, one of the most popular and rich in functionality
shells, an expansion of sh (AT&T Bell Labs)
» ksh, Korn Shell
» zhs
» ...
9. 9
Command Format
Format: command name and 0 or more arguments:
% commandname [arg1] ... [argN]
% sign – represents prompt.
Arguments can be
» options (switches to the command to indicate a mode of
operation) ; usually prefixed with a hyphen (-) or two (--) in GNU
style
» non-options, or operands, basically the data to work with (actual
data, or a file name)
10. 10
Shell I/O
Shell is a “power-user” interface, so the user interacts
with the shell by typing in the commands.
The shell interprets the commands, that may produce
some results, they go back to the user and the control is
given back to the user when a command completes
(in general).
In the case of external commands, shell executes actual
programs that may call functions of the OS kernel.
These system commands are often wrapped around a
so-called system calls, to ask the kernel to perform an
operation (usually privileged) on your behalf.
11. 11
Command I/O
Input to shell:
» Command name and arguments typed by the user
Input to a command:
» Keyboard, file, or other commands
Standard input: keyboard.
Standard output: screen.
These STDIN and STDOUT are often together referred to as a
terminal.
Both standard input and standard output can be redirected
from/to a file or other command.
File redirection:
» < input
» > output
» >> output append
13. 13
man
Manual Pages
The first command to remember
Contains info about almost everything :-
» other commands
» system calls
» c/library functions
» other utils, applications, configuration files
To read about man itself type:
% man man
NOTE: unfortunately there’s no
% man woman ...
14. 14
which
Displays a path name of a command.
Searches a path environmental variable for
the command and displays the absolute path.
To find which tcsh and bash are actually in
use, type:
% which tcsh
% which bash
% man which for more details
15. 15
chsh
Change Login Shell
Login shell is the shell that interprets commands
after you logged in by default.
You can change it with chsh (provided that your
system admin allowed you to do so).
To list all possible shells, depending on
implementation:
% chsh -l
% cat /etc/shells
% chsh with no arguments will prompt you for the
shell.
16. 16
whereis
Display all locations of a command (or some other
binary, man page, or a source file).
Searchers all directories to find commands that
match whereis’ argument
% whereis tcsh
17. 17
passwd
Change your login password.
A very good idea after you got a new one.
It’s usually a paranoid program asking your
password to have at least 6 chars in the
password, at least two alphabetical and one
numerical characters. Some other restrictions (e.g.
dictionary words or previous password similarity) may
apply.
Depending on a privilege, one can change user’s
and group passwords as well as real name, login
shell, etc.
% man passwd
19. 19
cal
Calendar
» for month
» entire year
Years range: 1 -
9999
No year 0
% cal current month
% cal 2 2000 Feb 2000, leap
year
% cal 2 2100 not a leap year
% cal 2 2400 leap year
% cal 0 error
% cal 2002 whole year
20. 20
clear
Clears the screen
There’s an alias for it: Ctrl+L
Example sequence:
» % cal
» % clear
» % cal
» Ctrl+L
21. 21
sleep
“Sleeping” is doing nothing for some time.
Usually used for delays in shell scripts.
% sleep 2 2 seconds pause
22. 22
Command Grouping
Semicolon: “;”
Often grouping acts as if it were a single
command, so an output of different commands
can be redirected to a file:
% (date; cal; date) > out.txt
23. 23
alias
Defined a new name for a command
% alias
» with no arguments lists currently active aliases
% alias newcommand oldcommand
» defines a newcommand
% alias cl cal 2003
% cl
25. 25
history
Display a history of
recently used
commands
% history
» all commands in the
history
% history 10
» last 10
% history -r 10
» reverse order
% !!
» repeat last command
% !n
» repeat command n in the
history
% !-1
» repeat last command =
!!
% !-2
» repeat second last
command
% !ca
» repeat last command that
begins with ‘ca’
26. 26
apropos
Search man pages
for a substring.
% apropos word
Equivalent:
% man -k word
% apropos date
% man -k date
% apropos password
28. 28
shutdown
Causes system to shutdown or reboot cleanly.
May require superuser privileges
% shutdown -h now - stop
% shutdown -r now - reboot
30. 30
Directories
Files are grouped together in other files called directories -
analogous to folders in Windows
Directory paths are separated by a forward slash: /
» Example: /homes/iws/robh/classes/cse326
The hierarchical structure of directories (the directory tree)
begins at a special directory called the root, or /
» Absolute paths start at / (root directory)
– Example: /homes/iws/robh/classes/cse326
» Relative paths start in the current directory
– Example: classes/cse326
Your home directory “~” is where your personal files are
located, and where you start when you log in.
» Example: /homes/iws/robh
31. 31
Directories (cont’d)
Handy directories to know: ~ Your home directory, .. The parent
directory, . The current directory
ls
» LiSts the contents of a specified files or directories (or the current
directory if no files are specified)
» Syntax: ls [<args> … ]
» Example: ls backups/
» Has whole bunch of options, e.g
– % ls -a : all files except those starting with a “.”
pwd
» personal working directory - displays Working Directory
find
» Looks up a file in a directory tree.
» Syntax: find . -name name
» Example: find . (-name ‘w*’ -or -name ‘W*’ )
32. 32
Directories (cont’d further)
cd
» Change current Directory to a new one – absolute or relative
» Syntax: cd <directory>
» Examples:
– cd backups/unix-tutorial
– cd ../class-notes
– cd returns to home directory
mkdir
» MaKe DIRectory - Creates a directory
» Syntax: mkdir <directories>
» Example: mkdir backups class-notes
rmdir
» ReMove DIRectory, which must be empty first
» Syntax: rmdir <directories>
» Example: rmdir backups class-notes
33. 33
Files
Unix file types (e.g. “executable files, ” “data files,” “text
files”) are not determined by file extension (e.g.
“foo.exe”, “foo.dat”, “foo.txt”) – unlike in Windows
Thus, the file-manipulation commands are few and
simple …
Many use only 2 letters
rm
» ReMoves a file, without a possibility of “undelete!”
» Syntax: rm <file(s)>
» Example: rm tutorial.txt backups/old.txt
34. 34
Files (cont’d)
cp
» CoPies a file / directory, preserving the original
» Syntax: cp [options] <sources> <destination>
» Example: cp tutorial.txt tutorial.txt.bak
» Useful option: -i to prevent overwriting existing files and
prompt the user to confirm.
mv
» MoVes or renames a file / directo, destroying the original
» Syntax: mv <sources> <destination>
» Examples:
– mv tutorial.txt tutorial.txt.bak
– mv tutorial.txt tutorial-slides.ppt backups/
35. 35
cat
Display and concatenate files.
% cat
» Will read from STDIN and print to STDOT every line you
enter.
% cat file1 [file2] ...
» Will concatenate all files in one and print them to STDOUT
% cat > filename
» Will take whatever you type from STDIN and will put it into
the file filename
To exit cat or cat > filename type Ctrl+D to
indicate EOF (End of File).
36. 36
more / less
Pagers to display contents of large files page by
page or scroll line by line up and down.
Have a lot of viewing options and search capability.
Interactive. To exit: ‘q’
37. 37
less
less ("less is more") a bit more smart than the more
command
to display contents of a file:
» % less filename
To display line numbers:
» % less -N filename
To display a prompt:
» % less -P"Press 'q' to quit" filename
Combine the two:
» % less -NP"Blah-blah-blah" filename
For more information:
» % man less
38. 38
touch
By touching a file you either create it if it did not
exists (with 0 length).
Or you update it’s last modification and access
times (update the time stamps of the files listed on
the command line to the current time)
There are options to override the default behavior.
% touch file
% man touch
39. 39
script
Writes a log (a typescript) of whatever
happened in the terminal to a file.
% script [file]
% script
» all log is saved into a file named typescript
% script file
» all log is saved into a file named file
To exit logging, type:
» % exit
40. 40
File attributes
Every file has some attributes:
Access Times:
when the file was created
when the file was last changed
when the file was last read
Size
Owners (user and group)
Permissions
Type – directory, link, regular file, etc.
ACLs – access control lists (not today)
41. 41
File Time Attributes
Time Attributes:
when the file was last changed ls -l
sort by modification time ls -lt
42. 42
File Owners
Each file is owned by a user.
You can find out the username of the
file's owner with the -l or -o option to
ls:
$ ls -l foo
-rw-rw---- 1 hollingd grads 13 Jan 10 23:05 foo
permissions
owner group
size
time
name
43. 43
File Permissions
Each file has a set of permissions that control
who can mess with the file.
There are three types of permissions:
read abbreviated r
write abbreviated w
execute abbreviated x
There are 3 sets of permissions:
1. user
2. group
3. other (the world, everybody else)
44. 44
ls -l and permissions
-rwxrwxrwx
User Group Others
Type of file:
- – plain file
d – directory
s – symbolic link
(others)
45. 45
rwx
Files:
r - allowed to read.
w - allowed to write
x - allowed to execute
Directories:
r - allowed to see the names of the
contents
w - allowed to add and remove files.
x - allowed to “enter” the directory
46. 46
Changing Permissions
chmod - changes the permissions
associated with a file or directory.
The simplest chmod looks like this:
chmod mode file
47. 47
chmod – numeric modes
Consider permission for each set of users
(user, group, other) as a 3-bit no.
r – 4
w – 2
x – 1
A permission (mode) for all 3 classes is a 3-
digit octal no.
755 – rwxr-xr-x
644 – rw-r—r--
700 – rwx------
48. 48
chmod - examples
$ chmod 700 CS571
$ ls –o Personal
drwx------ 10 kschmidt 4096 Dec 19 2004 CS571/
$ chmod 755 public_html
$ chmod 644 public_html/index.html
$ ls –ao public_html
drwxr-xr-x 16 kschmidt 4096 Jan 8 10:15 .
drwx--x--x 92 kschmidt 8192 Jan 8 13:36 ..
-rw-r--r-- 5 kschmidt 151 Nov 16 19:18 index.html
$ chmod 644 .plan
$ ls –o .plan
-rw-r--r-- 5 kschmidt 151 Nov 16 19:18 .plan
49. 49
chmod – symbolic modes
Can be used to set, add, or remove
permissions
Mode has the following form:
[ugoa][+-=][rwx]
u – user g – group o – other a – all
+ add permission - remove permission =
set permission
51. 51
grep
l Searches its input for a pattern.
l The pattern can be a simple substring or a complex
regular expression.
l If a line matches, it’s directed to STDOUT; otherwise,
it’s discarded.
l % echo “blah-foo” | grep blah
» Will print the matching line
l % echo “blah-foo” | grep zee
» Will not.
52. 52
Shell as a user interface
A shell is a command interpreter, an
interface between a human (or
another program) and the OS
runs a program, perhaps the ls program.
allows you to edit a command line.
can establish alternative sources of input
and destinations for output for programs.
Is, itself, just another program
53. 53
Bourne-again Shell (bash)
Extension of the Bourne Shell (sh)
Contains many of the Korn Shell (ksh)
extensions
You may use the shell of your choice
(tcsh, zsh, etc.).
54. 54
Session Startup
Once you log in, your shell will be
started and it will display a prompt.
(for our examples, we will use $ as the
prompt. It is not part of the input)
When the shell is started it looks in
your home directory for some
customization files.
You can change the shell prompt, your
PATH, and a bunch of other things by
creating customization files.
55. 55
Incorrect login
You will receive the “Password:”
prompt even if you type an incorrect or
nonexistent login name
– Can you guess why?
Nothing will happen while you type your
password. It's fine
56. 56
Logging off
exit builtin (command)
Exits the shell
If it is the login (top-level) shell, then it
disconnects you
A shell is just another program that
is running. Can recursively invoke
shells
Please don’t just disconnect w/out
exiting
57. 57
Standard I/O
When you enter a command the shell
creates a subshell to run the process
or script.
The shell establishes 3 I/O channels:
Standard Input (0) – keyboard
Standard Output (1) – screen
Standard Error (2) – screen
These streams may be redirected
to/from a file, or even another command
58. 58
Programs and Standard I/O
Program
Standard Input
(STDIN)
Standard Output
(STDOUT)
Standard Error
(STDERR)
59. 59
Terminating Standard Input
If standard input is your keyboard, you can type
stuff in that goes to a program.
To signal the end of input press Ctrl-D (^D), the
EOF signal, on a line by itself, this closes the
input stream.
The shell is a program that reads from standard
input.
60. 60
Shell metacharacters
Some characters have special meaning
to the shell. These are just a few:
I/O redirection
< > |
wildcards
* ? [ ]
others
& ; $ ! ( ) space tab newline
These must be escaped or quoted to
inhibit special behavior
61. 61
Wildcards
* – matches 0 or more characters
? – matches exactly 1 character
[<list>] – matches any single character in
<list>
E.g.
ls *.cc – list all C++ source files in directory
ls a* – list all files that start w/’a’
ls a*.jpeg – list all JPEGs that start w/’a’
ls * - (make sure you have a subdirectory, and try it)
62. 62
Wildcards (more examples)
ls file?
- matches file1, file2, but not
file nor file22
ls file?.*.DEL
- matches file1.h.DEL,
file9.cc.DEL, file3..DEL but not
file8.DEL nor file.html.DEL
These are not regular expressions!
63. 63
Wildcards - classes
[abc] matches any of the enclosed characters
ls T[eE][sS][tT].doc
[a-z] matches any character in a range
ls [a-zA-Z]*
[!abc…] matches any character except those
listed.
ls [!0-9]*
64. 64
Shell Variables
bash uses shell variables to store
information
Shell variables are used to affect the
behavior of the shell, and many other
programs
We can access these variables:
set new values for some to customize the
shell.
find out the value of some to help
accomplish a task.
65. 65
Setting/Viewing Variables
To assign (in sh, ksh, bash):
VAR=someString
OTHER_VAR=“I have whitespace”
Note, no whitespace around the ‘=‘!
To view (dereference) a variable:
$ echo $VAR
someString
$ echo $OTHER_VAR
I have whitespace
66. 66
Shell maintains some variables
Some common ones:
PATH – list of directories shell searches for
non-shell commands
PS1 – Primary prompt
USER – user's login name
HOME – user’s home directory
PWD – current working directory
67. 67
Other Useful Ones
SHELL – the login shell
TERM – the type of terminal interface
HISTFILE – where your command
history is saved
EDITOR – holds user's preferred editor
HOSTNAME – machine's hostname
SHELLOPTS – status of various shell
options (see Bash's set built-in)
68. 68
Displaying Shell Variables
Prefix the name of a shell variable with
"$".
The echo command will do:
$ echo $HOME
$ echo $PATH
You can use these variables on any
command line:
$ ls -al $HOME
69. 69
Setting Shell Variables
You can change the value of a shell
variable with an assignment command
(this is a shell builtin command):
HOME=/etc
PATH=/usr/bin:/usr/etc:/sbin
NEWVAR="blah blah blah"