Shared Flashcard Set

Details

Sun Certified associate
Sun Cert
182
Computer Science
Undergraduate 1
12/29/2008

Additional Computer Science Flashcards

 


 

Cards

Term
What is the core of the Operating system?
Definition
Kernel
Term
what is the Command interpreter called?
Definition
Shell
Term
what are Korn, Bourn, C shell?
Definition
3 Primary shells
Term
What is the default Bourn Shelll prompt for a regular user and root user?
Definition
Bourn Shell uses $ for a regular user and the  # for root?
Term
What is the default C shell prompt for a regular user and root user?
Definition
Host name followed by a % sign for regular and host name followed by # sign
Term
What is the default Korn prompt for a regular user and root user?
Definition
Regular user is $ and root is #
Term
What opens a single terminal window instead of starting a full desktop session?
Definition
Failsafe Login
Term
What Option buttons on login allow 3 types of sessions?
Definition
Desktop, Lost DeskTop, FailSafe
Term
List two Desktop Environments
Definition
Common (CDE) and Jave (JDE)
Term
How many Work spaces area available by default when logging in to your desk top session?
Definition
Four
Term
What is the general Syntax of a UNIX command?
Definition

Command , Option and Argument

Command specifies what the sytem does or executes

Option starts with a - (-a, ls -l ).

Argument specifys whats affected (file, dir or txt)

 

Cal 12 2000

is an example of a command and 2 arguments

Term
What is this ";" used for?
Definition

The semi colon is used to seperate each command to enter multipul commands at once.

The shell executes each command from left to right

 

Format would be 

Command>option>argument; Command>option>argument

Term
What does Ctrl- S do?
Definition
Halts output to screen
Term
What does Ctrl - W do?
Definition
Removes last word on the command line
Term
What does Ctrl -U do?
Definition
Removes all charaters on the current line
Term
List two options to search man pages
Definition

you can search by Section or Keyword

Term
What does Ctrl -c do?
Definition
Interrupts a command
Term
What is an Inode?
Definition
the inode contains information about the type of info,

permissions,ownership info,and location where data is stored.

Term
what will the pwd command tell you?
Definition
Identifies the directory you are currently accessing
Term
How do you display directory contents?
Definition

ls to display contents

ls -options filename

-a,  -l, -ld, and -R

Term
What does ls -a do?
Definition
list all files in a directory including hidden files
Term
What does ls -l do?
Definition

(long list)

used to view detailed info about  the contents of a dir

 

ls -l dir1

would allow you to view the detailed contents of dir1

Term
What does ls -ld do?
Definition
used to view detailed info about a directory without viewing its contents
Term
What does ls -R do?
Definition
To recursively display contents of its directory and its sub directory
Term
What is ls -F or File used for?
Definition
used to display file type
Term
What are 4 possible outputs from file or ls -F command?
Definition

/ = directory

* = executable

(none)plane txt or ASCII

@ = Symbolic link

Term
What is a Relative path name?
Definition

lists the directories in the path relative to the current working directory.

 

 

Term
What is an Absolute path name?
Definition
lists all the directories in the path starting with the root directory.
Term
What is the more command used for?
Definition

used to view or page thru the contents of a text file

 


 

Term
What will the tail command give you?
Definition

Tail command is used to view the last 10 lines of a file

 

option(s)

-n = dispalys n lines from the end of the file

+n = displays file content from line n end to the end of the file

Term
what is the wc command used for?
Definition

word count = displays numbers of lines, words, and characters contained in a file

 

options

-l = line count

-w =word count

-c = byte count

-m = character count

Term
List 3 common print commands
Definition

lp

lpstat

cancel

Term
what does the lp command do?
Definition
sends print requests to printers
Term
what does the lpstat command do?
Definition
displays information about the current status of the LP print service, including the status of print jobs
Term
what does the lp -d do?
Definition
sends print request to destination (desired printer)
Term
what does the lp -o do?
Definition
sends print request with no banner printed
Term
what does the lp -n do?
Definition
sends request to printer with number of copies
Term
what does the lp -m do?
Definition
send request to printer to send a mail message when complete
Term
what does the lpstat -p do?
Definition
status of all printers
Term
what does thelpstat -o do?
Definition
status of all output requests
Term
what does thelp stat -d do?
Definition
system default printer
Term
what does the lpstat -t do?
Definition
complete status of all printers
Term
what does the lpstat -a do?
Definition
Lists printers accepting print requests
Term
what does the lpstat printername do?
Definition
The command used before executing the cancel command to identify the print Request-id
Term
what does the cp -i do?
Definition
Prevents you from over writting existing files or directories
Term
what does the cp -r do?
Definition
copies recursivly.  Includes  the contents of a directory, including the contents of all subdirectories, when you copy a directory
Term
what does the MV command do?
Definition
the command used to rename a single file within the same directory or to move a file to a different dir or move a dir and contents to a diffenrent dir
Term
what does the rm command do?
Definition
Remove
Term
what does the rmdir command do?
Definition
permanently remove empty directories
Term
what does this command do rm -r?
Definition
remove directories that are not empty
Term
What is Symbolic link?
Definition
A path name to another file or directory
Term
what does the ln -s command do?
Definition

will create a symbolic link file

 

ln -s source_file target_file

Term
What is vi editor?
Definition

command line , interactive editor.  used when windows desktop is not available.  only text editor to edit certian files without changing the permissions and all talking place in the buffer

 

Term
list the 3 vi editor modes
Definition

command = delet, change or copy text

 edit = to enter text to a file 

  last line = advanced editing commands(:)

Term
what will this command do vi -R?
Definition
prevents accidental overwriting of the file content by opening in Read only mode
Term
what will this command do vi -r?
Definition
recovers the specified file or lists the files that can be recovered.
Term
what will typing "/string" do?
Definition
searches forward thru a string
Term
what will typing "?string" do?
Definition
searchs backwards for the string
Term
what is the  "set" command used for?
Definition
used  to customize a vi session
Term
What will the command ":set nu" do?
Definition
shows line numbers
Term
What will the command :set nonu do?
Definition
Hides line numbers
Term
What will the command :set ic do?
Definition
Instructs searches to ignore case
Term
What will the command :set all do?
Definition
Displays all set vi variables and their current values
Term
What will the command :set list do?
Definition
Displays invisible characters such as ^I for a tab $ for end of line characters
Term
What are Korn shell metacharacters?
Definition
specific charaters, generally symbols having speacial meaning to the shell
Term
What are File name substitution Metacharaters?
Definition

they are substitution characters

>Asterisk (*) zero or more characters (f* = Fxxxx)

>Question Mark (?) any single character (f? = Fx)

>Square Bracket ([]) set or range of characters

ls [a-f]*

Term
If you see "z?:" after a search what does it mean
Definition
no such file or directory
Term
what will this do (' ')?
Definition
instructs the shell to ignore all enclosed metacharacters
Term
what will this do(` `)?
Definition
instructs the shell to execute and display the output for a UNIX system command
Term
what will this do(" " )?
Definition
instructs shell to ignor all inclosed metacharacters
Term
what will this do \ ?
Definition
prevents shell from interpreting the next character as a metacharacter
Term
what does this symbol do $ ?
Definition
indicates that the following text is the name of a shell variable
Term
What is echo command used for?
Definition
used to display the value that is stored inside a shell variable
Term
What is set command used for?
Definition
list shell variables with thier current values
Term
What is an export command used for?
Definition
IT makes the value of a variable known to a sub shell
Term
What is the EDITOR variable do?
Definition
defines default editor
Term
What is a logname variable do?
Definition
sets login name of user
Term
What does a PATH variabile do?
Definition
specifies a colon-delimited list of directories to be searched when the shell needs to find a command to be executed
Term
What is PS1 variable?
Definition
Specifies the primary KORN shell prompt ($)
Term
What is PS2 Variable?
Definition
specifies the secondary KORN shell prompt (>)
Term
What does the history -n command do
Definition
Displays the command history without line numbers
Term
What does the history -r command do?
Definition
Displays the history list in reverse order
Term
What does the history cd ls command do?
Definition
to display the most recent CD command to the most recent date command
Term
What is the r command
Definition

alias built into the KORN shell that enables you to repeat a command

 

example you pull history

 159 cal

160 ls

 161 cd

$r 160

this would rerun he ls command

 

Term
What is the set -o vi command do?
Definition
turn on and enable the shell history editing feature
Term
What is output redirection ?
Definition

sends the output from a command into a file instead of sending the output to a screen.

(>)

Term
what is input redirection?
Definition

forces a command to to read the input from a file instead of the keyboard

(<)

Term
what is stdin and whats is its number?
Definition
starndard command input  (0)
Term
what is stdout and what is its number?
Definition
Standard Output (1)
Term
what is stderr and what is its number?
Definition
standard error (2)
Term
What is the | (pipe) character used for?
Definition
used to redirect the standard output to the input of another command
Term
what will the command do "2> filename"?
Definition
redirection surpresses error messages from appearing on screen and redirects to standard error file
Term
What is this ".kschrc"?
Definition
executed everytime you log on and defines specific settings in the KORN shell.
Term
What is UID?
Definition
user identification number and it identifies who owns the file.
Term
What is GID?
Definition
group id, group users who owns the file
Term
What will the command ls -n do ?
Definition
Will help determine ownership of a files and directories.
Term
What is chmod command used for?
Definition
used to change the permission set for files and directories using symbolic or octal mode
Term
what is the default umask value in Solaris
Definition
022
Term
what is the initial permission value automaticly assigned by the Solaris OS for a new file.
Definition
rw-rw-rw-
Term
what is the initial permission value automaticly assigned by the Solaris OS for a new directory.
Definition
rwxrwxrwx
Term
what is ACL and what does it do?
Definition
Access control list.  It enables the owner of a file or directory to grant or deny specific user access
Term
What does the command getfacl -a do?
Definition

Displays all info about ACL

 

Term
What does the command setfacl -m do?
Definition
creates or modifies ACL entries on files
Term
What does the command setfcal -s do?
Definition
substitutes new ACL entries for old
Term
What does the command setfcal -d do?
Definition
Deletes one or more ACL
Term
What does the command setfcal -r do?
Definition
Recalculates the ACL
Term
What does the command getfacl command do?
Definition
will display the trivial ACL entries for a file or directory
Term
What command is used to display the actual list of ACL entries?
Definition
getfacl
Term
Which command is used to modify the ACL entries of a file
Definition
setfacl
Term
What will setfacl -r -m do?
Definition
will recalculate the ACL mask entry
Term
Using the CHMOD command on a file that already has an ACL on it will recalculate the mask
Definition
true
Term
Can you use the file manager GUI to perform common ACL configuration tasks?
Definition
yes
Term
Do ACL permissions modify the umask permissions settings to provide a second level of file and directory access protection
Definition

NO

The ACL permissions provide a second level of access protection, but ACL's cannot modify the umask permissions settings

Term
What do grep, egrep,and fgrep do?
Definition
Allows you to search the contents of files for patterns or strings of characters
Term
What does grep do?
Definition
Searches the contents of one or more files for specific character patterns globaly
Term
what does fgrep do?
Definition
Search for a file for a literal string or a group of characters.
Term
What is the find command used for?
Definition
used to locate files or directories in the directory hierrarchy
Term
What will the command find -size [+|-]n do
Definition
find files that are larger than +n or smaller than -n or exactly n
Term
What will the commandfind -atime[+|-]n do?
Definition
find files that have been accessed more then +n days, less than -ndays, or exacty n days ago
Term
What will the commandfind -ntime [+|-]n do?
Definition
find files that have been modified more then +n days, less than -ndays, or exacty n days ago
Term
What will the command find -user loginIDdo?
Definition
finds all files that are owned by the login ID
Term
What will the command find -type do?
Definition
Finds a file type
Term
What will the command find  -perm do?
Definition
Finds Files that have certian access permission Bits
Term
what are Daemons?
Definition

processes that run in the background and provide services.

Term
What is a PID?
Definition
used by the Kernal to track control and manage the process.
Term
What does the PS command do?
Definition

Lists the process that are scheduled to run.

Dispays the PID, TTY, Time and CMD

Term
What does ps -ef do?
Definition
used to view a listing if all the processes currently scheduled to  run on the system
Term
what does pgrep do?
Definition

will display the PID of every process that matches the specific criteria.

 

Term
What does pgrep -x do?
Definition
Displays the PID that matches the pattern exactly
Term
What does pgrep -n do?
Definition
displays only the most recently created PID that contains the pattern
Term
what does pgrep -U uid
Definition

Displays only the PIDs that belong to the specified user

Term
What does pgrep -l do?
Definition
Displays name of the process along with the PID
Term
What does pgrep -t term do?
Definition
Displays only those processes that are associated with a terminal in the term list
Term
what does the ptree command do?
Definition

Displays a process tree based on the specified PID

Term
What is SIGKILL (9)?
Definition

kill

Signal that kills a process

Term
What is SIGTERM (15)?
Definition

Terminate

A signal that terminates a process in a orderly manner

Term
What will pkill allow you to do?
Definition
allows you yo use process name to terminate a process
Term
What will the "Jobs" command do?
Definition
Lists all jobs that are currently running or are stopped in the background
Term
What does Job control command bg %n command do?
Definition

Runs the current or specified job in the background

(n is job id)

Term
What does Job control command fg %n do?
Definition
Brings the current or specified job into the foreground (n is job id)
Term
What does Job control command Control -Z do?
Definition
Stops the foreground job and places it in the background as a stopped job
Term
What does job control command stop %n do?
Definition
Stops a job that is running in the background (n is the Job ID)
Term
What does the (&)symbol at the end if the command line do?
Definition
Runs a job in the background
Term
What general format must there be to run a shell function?
Definition
A space must appear after the first brace and before the closing brace
Term
What does the typeset -f function command do?
Definition
displays a list of all functions with definitions
Term
What does the typeset +f function do?
Definition
lists just the function names
Term
What does set -o do?
Definition
shows current option settings
Term
What will set -o option_name do?
Definition
will turn an option on
Term
What will set +o option_name do?
Definition
will turn an option off
Term
What will the symbol "#!" be used for?
Definition
used to identify the program that interperts the lines in the script
Term
An exit status is a numeric value that indicates success or failure.  what are they?
Definition
a value of zero indicates success while a non-zero value indicates failure and held in the $? special shell variable
Term
What does the "&&" do?
Definition
Ensures that a command is performed only if the preceding command succeeds
Term
What is the "|| " used for?
Definition
Ensures that a command is performed only if the preceding command fails
Term
which file is a frequently used shell script that sets the working environment of the users
Definition
.profile file
Term
This is used to create and extract files from a file archive or any removable media such as USB flash drive or a tape device
Definition
tar command
Term
what does tar -c do?
Definition
creates a new tar file
Term

what does tar -t do?

Definition
lists the table of contents of the tar file
Term
what does tar -x do?
Definition
extracts from the tar file
Term

what does tar -v do?

Definition
Executes in verbose mode, writes to the standard output.
Term
what does tar -f do?
Definition
Specifies the archive file or tape drive.
Term
what does tar -h do?
Definition
Follows symbolic links as standard files or directories
Term

What will $tar tf /dev/rmt/0 show you?

 

Definition
This is the command to allows you to view the contentes of the archived directory on a tape
Term

What does the jar command do?

 

Definition
This command will combine multiple files into a single archive file.
Term

What does the jar -c command do?

 

Definition
creates a new Jar file
Term
what does the command jar -t do?
Definition
this command will list the table of contents of the jar file
Term
what does the command jar -x do?
Definition
Extracts files from the jar file.
Term

What does the command jar -f do?

 

Definition
specifies the jar file to process
Term
what does the jar -v command do?
Definition
Executes in verboe mode.
Term

what does this commmand do?

$jar cvf /tmp/bundle.jar *

Definition
this command will allow you to copy and compress multiple files into a single archive file.
Term
What does the compress command do?
Definition

This command reduces the size of a file, such that it occupies less disk space and takes less time for a transfer.

 compression reduces teh size of a text file by 50-60%

Term
what does 7az command do?
Definition
used to compress a file
Term
what does the zcat command do
Definition
allows you to view files that have been compressed via compress command
Term
what does the gzip command do?
Definition
reduces the size of a file.
Term
what does the gunzip command do?
Definition
restores a file that has been compresses with the gzip command
Term
what does the gzcat command do?
Definition
allows you to view files that were compressed with with gzip or compress
Term
what does the zip command do?
Definition
this command allows you to compress multiple files into a single archive file.
Term
what does the ./ rhostfile do?
Definition
provides an authentication procedure to determine if a remote user can access the local host with the identity of the local user
Term
if the .rhosts file contains a (+) what does that mean?
Definition
this means the user is able to login in from any known system on the network without a password.
Term
what does rlogin do?
Definition
establishes a remote login session on another system.
Term
what does the rsh command allow you to do?
Definition
This allows you to run a program on a remote system without having to log on to the remote system.
Term
what will telnet allow you to do?
Definition
It allows you to log onto a remote system and work in that environment
Term
what does the rcp command allow you to do?
Definition
It allows you to copy files or directories from one host to another.
Supporting users have an ad free experience!