Explain three filter commands in UNIX?
head - list the first N lines of a file
tail - list the last N lines of a file
cut - remove columns in each line of a file.
How can you grep out a value in a string?
I'm not sure why you would want to use 'grep' on a string - a string is typically a single line, and grep is used to find matches in one or more files.
If the string is very long, say 32000 characters or so, you could take the string and echo it or cat it thru grep, but again, if there is a match, the entire string would be print anyway.
Unix really doesn't use file extensions, but if you want to look for them recursively, then use:
ls -R *txt
First, I should mention the obligitary comment that you should use ssh rather than rsh (OpenSSH, for example, ships with AIX, I think on the bonus or linux tools CD).
However, if you want to use rsh, configuring it on AIX is exactly the same as on every other platform.
On the host that you want to rsh to create a .rhosts file in the user's home directory, owned by the user with permission 600. Put in it
Code:
host user
where "host" is the host you are coming from and "user" is the user account you are coming from.
There are other options and files, but this will work, so check out the man page if you want more info.
Is the ls command in Linux equivalent to ls -FC?
The 'ls' command is the same in Linux and Unix systems. System Administrators may set up an alias that has the -FC or other options but the command itself with no other parameters (ls) is just the 'ls' command.
What is present in Unix to protect it from viruses?
Unix uses anti-virus programs the same way other systems do; there is nothing present in the system to protect it from virus programs.
What is named and unnamed pipe in unix?
In Unix, pipes are basically how information flows between processes. Unnamed pipes are created and destroyed within the processes life cycle. Named pipes exist until removed with an unlink() command and can be used with unrelated processes.
Why do you think Unix and Linux share more commands than Windows XP and Unix?
Because Linux was modeled after Unix, and designed to be a suitable free replacement. Windows is targeted at a slightly different market, and was primarily designed to be operated using a GUI, not the command line.
Hot fixes
How do you create dummy file in unix?
using touch command of UNIX. syntax touch <filename> will create dummy regular file.
What is the architecture of Unix?
- The functioning of UNIX operating system is handled in three levels. At the heart of UNIX is the kernel, which interact with actual hardware. Kernel is the fundamental part(core) of the OS. That resides in main memory at all times. On the outer crust are the application packages and user programs. The dilled layer is the shell which acts as a mediator that translates the commands given by the application programs in the outer later and conveys them to the kernel layer. The kernel then executes these commands using the inner hardware.
Differtiate window NOS over unix NOS?
If both Windows and Unix are using TCP/IP as their primary NOS there isn't much difference to speak of.
How do you open a PDF file from the Unix command line?
There is no standardized viewer for viewing PDF files from the console. PDF files were intended to be worked with on graphical workstations. There are a couple that can use SVGAlib (thus they only work on Linux), and there may be similar programs on some proprietary implementations, but nothing in widespread usage.
When do the wild cards loses its meaning in unix?
Wildcards can lose their meaning in at least two ways; if the character is escaped by a backslash (\) or on the command line if used within single quotes (').
How you add the group students to your Linux or Solaris system?
You can create a new group with the command groupadd.
Ex. 'groupadd students'
What is path variable in unix?
It is special variable that has a lit of directories there all our applications are located. In other to find out this PATH variable in UNIX type operating system use env command and look for PATH variable in ENVIRONMENT variables list or use bash line: echo $PATH this will return only $PATH variable.
For example my PATH variable is:
/Users/david/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin
When you will try to launch a program by writing it's name in console all those directories you see in PATH variable will be checked for that application.
What command would you use to create a new directory on a unix type of system?
Use the 'mkdir' command
What are the different shells in Unix?
There are many possible Unix shells that users have access to. Some of these are:
sh - Bourne shell (the original shell)
ksh - Korn shell
bash - Bourne-again shell
csh - C shell
tcsh - variant of the C shell and other features
zsh - the 'z' shell
rsh - Restricted shell
ksh93 - '93 version of ksh
What is an operating system interface?
It is a set of commands or actions that an operating system can perform and a way for a program or person to activate them.
What is the difference between unix command and utilities?
Utilities are programs that can run or execute. Commands are slightly different than utilities. Command refers to the name of the program and any arguments you specify to that program to change its behavior.
In Unix-like operating systems what does 'unlink' do?
Unix-like operating systems are used to save files on a computer operating system. When using this type of system, to unlink a file means to erase or delete it.
Is there a define type program for Unix?
If you are asking about how can you find the type of file something is, the command is 'file' followed by the filename. This command will attempt to tell you something about the file and how it might be used.
How does the shell work with the kernel?
I THINK KERNAL IS THE INNERMOST PART OF THE COMPUTER.
AND ALL REATED TO HARDWARE MEANS TIME SHARNG,MEMORY MANAGEMENT ETC IS DONE BY KERNAL.
WHILE SHELL IS OUTER MOST PART OF COMPUTER.
IT ACTS AS AN INTERFACE B/W USE AND OS.
IN B/W KERNAL AND SHELL THR IS OS.
O.S IS IN BETWEEN KERNAL AND SHELL
======================
I will take it this way...
Superficial idea about the shell communication is very simple.
Shell is a program(for Linux a process) which has been written to using the Kernal modules(Kernal is again a software program consist of many module).Kernal module provides different API which the shell programmer use to call depending upon the command placed by the user.
Writting our own shell is bit difficult as it need through understanding of how the kenel behaves.
How can you recover the overwritten files in SCO Unix HTFS file system?
Answer
Recovering any 'deleted' and/or 'overwritten' file in a typical Unix system is problematic and much more difficult to do reliably than it is with, say, a typical Windows system. This is a function of the way the files are stored on a Unix system, not a problem with, or feature of, the operating system itself. I suggest you obtain and study Wietse Venema's TCT (The Coroner's Toolkit) for further information. [JMH]