Tuesday, February 16, 2010

Download Unix variations (derivatives)

Download Unix variations (derivatives)
Free derivatives of Unix can be easily downloaded via the Internet.The different versions of Unix and Unix-like operating systems available for download include FreeBSD, OpenBSD, Red Hat Fedora Linux, Debian Linux, Ubuntu Linux, and Sun Solaris.
You can still try these operating systems by using virtual machines, without worrying about your existing data or OS being affected. You can install your preferred version of Unix inside the virtual machine to get a separate “computer” running inside your existing OS. These virtual machines can be set up using software such as Sun Microsystems’ VirtualBox, which is available as a free download.
Download FreeBSD Unix
The FreeBSD operating system is meant for use on the following architectures:
1.       x86 machines, with Pentium or Athlon cores
2.       AMD64 compatible machines, which include Athlon 64, Opteron and EM64T
3.       Alpha/AXP
4.       IA-64, PC-98
5.       UltraSPARC
FreeBSD is an offshoot of BSD, the version of UNIX which was developed at the University of California, Berkeley.

Download OpenBSD Unix
A free, multiplatform 4.4BSD-based UNIX-like system is developed by the OpenBSD project. This system has the benefits of portability, standardization and integrated cryptography among key features. Binary emulation of programs from SVR4 (Solaris), FreeBSD, SunOS, Linux, BSD/OS and HP-UX is possible with OpenBSD Unix.
Download Solaris Unix
The Solaris OS exhibits good scalability, performance, and security on SPARC, Opteron, AMD and Intel Xeon-based systems. The latest version of the Solaris Unix has used exceptional technologies for facilitating robust computing infrastructures. The Solaris operating system integrates many popular open source applications, including Apache, Tomcat and Secure Shell. Open source packages are available on this platform, with the result that time needed for porting is cut down.
Download Ubuntu Linux
Ubuntu is good for laptops, desktops and servers and contains all the essential programs that you may require, from word processors to compilers for various programming languages. Users interested in Ubuntu can download, use and share Ubuntu with friends or associates free of cost.
Download Fedora Linux
The Fedora Project builds versions of a general purpose operating system made exclusively from free software. Fedora Linux is quite popular among open source software development enthusiasts.
Download Debian Linux
Debian uses the Linux kernel and many of its basic tools are derived from the GNU project. Debian GNU/Linux has more than 8710 packages and precompiled software bundled conveniently for easy installation.
Download Gentoo Linux
Gentoo Linux can be quickly and easily customized by end users. Among the highlights of the Gentoo Linux experience are the easy configurability and good performance. Also, ample developer support is available via the communities.Gentoo is called a metadistribution by many users because of its easy adaptability.
Download Slackware Linux
Slackware Linux is a UNIX-like system. It contains an easy to use installation program, extensive online documentation, and a menu-driven package system. A complete installation of Slackware allows you the X Window System, C/C++ development environments, an ftp server, the GNU Image Manipulation Program and Netscape Communicator among other key features.
Download Mandriva Linux
Mandriva Linux attempts to turn the regular Linux into a more user-friendly operating system. Mandriva Linux is easy-to-use and innovative. This is manifest in the numerous awards Mandriva has received.
Download openSUSE Linux
The openSUSE project is a community program which is sponsored by Novell. The openSUSE system is the most user-friendly of all the versions of Linux.This system is excellent for both developers and casual users to feel a great Linux experience.

Summary Unix Commands

Directories and Path:
/                              "root" directory
/usr                        directory usr (sub-directory of / "root" directory)

Moving around the file system:
pwd                       Show the current directory.
cd                            Change current directory to your HOME directory.
cd /usr/isura      Change current directory to /usr/isura.
cd INIT                  Change current directory to INIT which is a  sub-directory of the current directory.
cd ..                        Change current directory to the parent directory
cd $STRMWORK               Change current directory to the directory defined by the environment variable            
cd ~bob              Change the current directory to the user bob's home directory (if you have permission).

List directory contents:
ls                             list a directory
ls -l                         list a directory in long ( detailed ) format
ls -a                        List the current directory including hidden files.
ls -ld *                    List all the file and directory names in the current directory using long format.

Changing file permissions and attributes
chmod 755 file                   Changes the permissions of file.
chgrp user file                   Makes file belong to the group user.
chown cliff file                   Makes cliff the owner of file.
chown -R cliff dir              Makes cliff the owner of dir and everything in its directory tree.

Moving, renaming, and copying files:
cp file1 file2                        copy a file
mv file1 newname          move or rename a file
mv file1 ~/AAA/               move file1 into sub-directory AAA in your home directory.
rm file1                                 remove or delete a file
rm -r dir1                             recursively remove a directory and its contents
mkdir dir1                            create directories
mkdir -p dirpath               create the directory dirpath, including all implied directories in the path.
rmdir dir1                             remove an empty directory

Viewing and editing files:
cat filename                        Dump a file to the screen in ascii.
more filename                  Progressively dump a file to the screen:  ENTER = one line down
                                                SPACEBAR = page down               q=quit
vi filename                          Edit a file using the vi editor. 
emacs filename                Edit a file using the emacs editor. Not all systems will have emacs.

head filename                   Show the first few lines of a file.
head -n  filename            Show the first n lines of a file.
tail -n filename                  Show the last n lines of a file.

echo $SHELL                       You can find out what shell you are using by the command:
you can create a file with a list of shell commands and execute. This is called a shell script. This is in fact the primary purpose of most shells( bat files in Windows). 

Environment variables
You can teach your shell to remember things for later using environment variables.
For example under the bash shell:

export CASROOT=/usr/local/CAS3.0               Defines the variable CASROOT with the value
/usr/local/CAS3.0.           By prefixing $ to the variable name, you can evaluate it in any command:

cd $CASROOT         Changes your present working directory to the  value of CASROOT
echo $CASROOT       Prints out the value of CASROOT, or /usr/local/CAS3.0
printenv CASROOT    Does the same thing in bash and some other shells.

grep string filename > newfile           Redirects  the output of the above grep command to a file
grep string filename >> existfile        Appends the output of the grep command to the end of


ls -l | more         This commands takes the output of the long format directory list command
"ls -l" and pipes it through the more command (also known as a filter).

du -sc * | sort -n | tail 

The command "du -sc" lists the sizes of all files and directories in the current working directory. That is piped through "sort -n" which orders the output from smallest to largest size. Finally, that output is piped through "tail" which displays only the last few (which just happen to be the largest) results.

Command Substitution
You can use the output of one command as an input to another command in another way called command substitution. 
cat `find . -name aaa.txt`              which will cat ( dump to the screen ) all the files named aaa.txt that
exist in the current directory or in any subdirectory tree.

Searching for strings in files: The grep  command
grep string filename    prints all the lines in a file that contain the string

Searching for files : The find command

find search_path -name filename
find . -name aaa.txt    Finds all the files named aaa.txt in the current directory or any subdirectory tree.
find / -name vimrc      Find all the files named 'vimrc' anywhere on the system.
find /usr/local/games -name "*xpilot*"       Find all files whose names contain the string 'xpilot' which exist within the '/usr/local/games' directory tree.

Reading and writing tapes, backups, and archives: The tar

tar xv      Extracts (x) files from the default tape drive while listing (v = verbose)    the file names to the screen.

tar tv      Lists the files from the default tape device without extracting them.    
tar xvf archive.tar                       extract from the archive file
tar cvfz archive.tar.gz dname      Create a gzip compressed tar archive containing everything in the directory 'dname'. This does not work with all versions of tar.

tar xvfz archive.tar.gz               Extract a gzip compressed tar archive.  Does not work with all versions of tar.

compress part.igs    Creates a compressed file part.igs.Z
uncompress part.igs  Uncompresseis part.igs from the compressed file part.igs.Z.
gzip usually gives better compression than standard compress,

gzip part.igs     Creates a compressed file part.igs.gz
gunzip part.igs   Extracts the original file from part.igs.gz

Looking for help: The man and apropos
man ls      Shows the manual page for the ls command
apropos build     Shows a list of all the man pages whose discriptions contain the word "build"

Basics of the  vi editor
Opening a file      vi filename 
Creating text
i      Insert before current cursor position
I      Insert at beginning of current line
a      Insert (append) after current cursor position
A     Append to end of line
r      Replace 1 character
R     Replace mode

Terminate insertion or overwrite mode
Deletion of text
x      Delete single character
dd    Delete current line and put in buffer ndd   Delete n lines (n is a number) and put them in buffer
D     delete the remainder of the line, starting with current cursor position
J      Attaches the next line to the end of the current line (deletes carriage return).
u           Undo last command
yy         Yank current line into buffer
nyy       Yank n lines into buffer
p           Put the contents of the buffer after the current line
P           Put the contents of the buffer before the current line
cursor positioning
ctrl + d    Page down
ctrl + u    Page up
:n             Position cursor at line n
:$             Position cursor at end of file
ctrl + g    Display current line number
j               move cursor down one line
k               move cursor up one line
0(zero)    go to begging of the line
$               go to end of the line

:0(zero)   go to first line of the file
:$              go to last line of the file
string substitution
:n1,n2:s/string1/string2/[g]       Substitute string2 for string1 on lines n1 to n2. If g is included (meaning global),  all instances of string1 on each lineare substituted. If g is not included,only the first instance per matching line issubstituted.

:1,$:s/dog/cat/g               Substitute 'cat' for 'dog', every instance for the entire file - lines 1 to $ (end of file) Saving and quitting and other "ex" commands

:w                                          Write the current file.
:w new.file                          Write the file to the name 'new.file'.
:w! existing.file                   Overwrite an existing file with the file currently being edited.
:wq                                        Write the file and quit.
:q                                           Quit.
:q!                                          Quit with no changes.
:e filename                          Open the file 'filename' for editing.
:set number                         Turns on line numbering
:set nonumber                    Turns off line numbering

Searching and Determining line numbers
/string                        string search forward 
?string                       string search backward
n                               move next occurrence forward
N                              move next occurrence forward
:=                            Return the number of lines in the bottom of the screen

Read individual characters of a file(can be use to identify strange characters)
od -c filename

Compare 2 files and export difference 
cat file1.txt file2.txt | sort |uniq -u > out.txt

Convert Dos file to Unix
vi the document and type :set ff=unix

Show no of columns group by column length (delimiter 'tab')
$ awk -F '\t' ' {print NF+1 } ' unique_medical_0-55k.txt  | sort | uniq -c
Export no of columns in each line (delimiter 'tab')
$awk -F '\t' ' {print NF+1 } ' unique_medical_0-55k.txt  > /tmp/a
you can use /[^39]command to find out row no of column whose length except 39

Monday, February 15, 2010

Graduate Enterprise Challenge Competition '09

Graduate Enterprise Challenge is a business plan competition that is open to undergraduate and graduate students in Sri Lanka. It is organised by the British Council and Sri Lanka Association of Software and Service Companies (SLASSCOM). This programme is a follow-up project to National Entrepreneurship Week Sri Lanka 2008 (NEW 08).
British Council has pioneered ‘Graduate Entrepreneurship’ development in Sri Lanka under the auspices of the Ministry of Higher Education and the University Grants Commission. NEW 08 is the latest of a series of activities organised by the British Council funded by the UK Prime Minister’s Initiative (PMI2) for the development of international education partnerships.
SLASSCOM acts as the catalyst of growth for the Sri Lankan IT and BPO industry by facilitating trade and business, propagation of education and employment, encouragement of research and innovation, and by supporting the creation of a progressive national policy framework.
more details:

University of Colombo School of Computing
Web based total printing solution for local and International consumers to reduce overall printing cost.
Melick Baranasooriya
Isura Sandaruwan Silva
S I Semage