Labels

Thursday, October 27, 2011

How to Start Networking in Backtrack

This is always a huge topic and it seems simple to many of us but the fact of the matter is we have a lot of "new" people so we need to be clear about this sort of thing. (Note all commands should be run as root or with sudo)

1. To start networking in Backtrack 4 final issue the following command.

/etc/init.d/networking start

This will attempt to start all the interfaces in the /etc/network/interfaces file.

root@bt:~# cat /etc/network/interfaces
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet dhcp

auto eth1
iface eth1 inet dhcp

auto eth2
iface eth2 inet dhcp

auto ath0
iface ath0 inet dhcp

auto wlan0
iface wlan0 inet dhcp


If you don't have or don't want some of these interfaces then simply remove the from this file and they will not start.

If you need to set a static IP just set the variables in the /etc/network/interfaces file

auto eth0
iface eth0 inet static
address 192.168.0.100
netmask 255.255.255.0
network 192.168.0.0
broadcast 192.168.0.255
gateway 192.168.0.1

You will also need to make sure you set a nameserver in /etc/resolv.conf

root@bt:~# cat /etc/resolv.conf
nameserver 192.168.0.1


So for example if all you have is eth0 and wlan0 on your system and you want them both to get a adress via DHCP then remove every thing else for the file with the exception of the lo interface. Here is a example.

root@bt:~# cat /etc/network/interfaces
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet dhcp

auto wlan0
iface wlan0 inet dhcp



Now if are lazy and want all this to start at boot you can simply issue this command as root

update-rc.d networking defaults

This will create all the proper sym-links

What about ssh?

So while I am on the subject I may as well go over ssh. In order to use ssh on backtrack 4 final you need to generate the keys first.

sshd-generate

after that you can start ssh like this:

/etc/init.d/ssh start


or you can add it to the boot sequence like this:

update-rc.d ssh defaults

Well thats enough to get up and running. I hope this was somewhat helpful to any one just getting started with backtrack.
Continue Reading »

Tuesday, October 25, 2011

Install BackTrack in VMWare.

Follow the basic install instructions here to get BackTrack installed in a VMware machine.
Log into BackTrack. To install the VMWare drivers, the kernel source and headers need to be in place. By default in the BackTrack 4 final release, the kernel (denoted by {version} ) is configured and ready. However in some cases, you might need to make sure you have the latest kernel sources by typing in:
apt-get update apt-get install linux-source cd /usr/src tar jxpf linux-source-{version}.tar.bz2 ln -s linux-source-{version} linux cd linux zcat /proc/config.gz > .config make scripts make prepare

Now that your kernel sources and headers are in place, run the “Install VMWare tools” for the specific guest VM.
Mount the VMWare tools virtual cd, copy over the VMWare tools package and run the installer:
mount /dev/cdrom3 /mnt/cdrom cp /mnt/cdrom/VMwareTools-{version}.tar.gz /tmp/ cd /tmp/ tar zxpf VMwareTools-{version}.tar.gz cd vmware-tools-distrib ./vmware-install.pl

Complete the VMWare tools installation as required. Run “fix-splash” to reintroduce the green framebuffer console. Reboot.

Continue Reading »

Monday, October 24, 2011

Setting DNS Server di Ubuntu

When using the internet, then it implies that we use DNS (Domain Name System). The main function of this control system is to translate host names into IP numbers (IP address) or vice versa so that the name is easily remembered by Internet users. System control also serves to provide information about a host to the entire Internet network. About how the DNS Server itself will not be discussed in this article but the way its setting alone secaara simple.

1. Installing Bind

Software that is widely used as a DNS server is Bind. Of course we must first install this application.

# Sudo apt-get install bind9

Next install again the next package, namely dnsutils

# Sudo apt-get install dnsutils

2.The next step, ie edit the Ethernet card that will be used later.

# Nano / etc / network / interfaces

Select the Ethernet to be used for example eth0 with ip 192.168.44.2 DNS Servers it. The contents also his netmask and gateway.

3. Then edit the file / etc / bind / named.conf.options

# Nano / etc / bind / named.conf.options

Remove the "/ /" and enter DNS Server ip the same as before.

4.  Next, edit the file / etc / bind / named.conf.local

# Nano / etc / bind / named.conf.local

Here the DNS server is named bayuwicaksono.com. Correction on the setting of the second zone, which is on file "/ etc/bind/db.192"; not a file "/ etc/bind/db.44";.

5. The next step by adding the file / etc / bind / db.local into the directory / etc / bind / db.bayuwicaksono.com

# Cp / etc / bind / db.local / etc / bind / db.bayuwicaksono.com

Then edit the files you have added earlier

# Nano / etc / bind / db.bayuwicaksono.com


Here only name server is loaded and also the DNS server ip alone that could have also added to mailserver, ftp server or the other.

6.The next step is almost the same as the previous step by adding the file / etc/bind/db.127 into the directory / etc/bind/db.192

# Cp / etc/bind/db.127 / etc/bind/db.192

Then edit the files you have added earlier

# Nano / etc/bind/db.192

7. Then edit the file / etc / resolv.conf

# Nano / etc / resolv.conf

8. Then again edit the file / etc / hosts file to add the host computer information.

# Nano / etc / hosts

9. The final step to restart the services that have been in previous settings.

# / Etc/init.d/bind9 restart

# / Etc / init.d / networking restart


10. After all the settings then the live test DNS server is already running.
Continue Reading »

BackTrack Clean Hard Drive Install

This method of installation is the simplest available. The assumption is that the whole hard drive is going to be used for BackTrack.

1. Boot BackTrack on the machine to be installed. Once booted, type in “startx” to get to the KDE graphical
    interface.
2. Double click the “install.sh” script on the desktop, or run the command “ubiquity” in console.


3. Select your geographical location and click “forward”.  Same for the Keyboard layout.
4. The next screen allows you to configure the partitioning layout. The assumption is that we are deleting the 
    whole drive and installing BackTrack 



5. Accept the installation summary and client “Install”. Allow the installation to run and complete. Restart 
    when done.


6. Log into BackTrack with the default username and password root / toor. Change root password.
7. Fix the framebuffer splash by typing “fix-splash” ( or “fix-splash800? if you wish a 800×600 framebuffer), 
     reboot.
Continue Reading »

Saturday, October 22, 2011

how to install Kubuntu KDE in Ubuntu

Ubuntu default desktop uses Gnome window manager, which can be a difficult transition for Windows users. KDE desktop will be much more familiar to Windows users, such as KDE has something comparable to the start menu.

If you've installed Ubuntu, and you do not want to completely reset with Kubuntu, you can only install the KDE window manager to install kubuntu-desktop package and its dependencies.

You can install kubuntu using GUI tools, but the easiest way is to open a terminal window, and type the following command:

sudo apt-get install kubuntu-desktop

You will be prompted for a password, and then you will be asked again to ask if you really want to install. Press Y to continue, and let the install begin.

Download all the updates can take a while, so you might want to get a cup of coffee or something. You will be prompted to choose the login manager, which you can select as gdm (ubuntu) or kdm (kde). I decided to leave the default gdm.

Reboot the computer, and when you get to the login prompt, click the Options button in the lower left corner:

You will be prompted to select the session you want. Here we will click KDE to continue.

Login, and you should now see the KDE desktop! All applications are found in a menu-like "Start", as you can see:

Note: If you are running Ubuntu inside VMware and end up with some display issues which is really weird screen resolution is really great, but the desktop shows at 800 × 600 instead (see screenshot), there is a fix for this.

When I encountered this problem, I also can not use a mouse. I rebooted, and logged back into Ubuntu desktop instead of KDE, and go into the directory / etc/X11 /.

You may notice that your xorg.conf file backed up during installation xorg.conf.1 / KDE Kubuntu. Just copy xorg.conf.1 back into xorg.conf, reboot, and everything should be fine.

Again, do not mess with the xorg.conf file unless you are really experiencing this problem.
Continue Reading »

Friday, October 21, 2011

How to Install VGA Driver nVidia GeForce on Ubuntu

Times where I will discuss how to install nVidia drivers on Ubuntu, just here's how:
1) Download Newest Nvidia drivers from www.nvidia.com
2) Open the module blacklist as admin

gksudo gedit / etc / modprobe.d / blacklist.conf

Add these lines and save:
blacklist vga16fb
blacklist nouveau
blacklist rivafb
blacklist nvidiafb
blacklist rivatv

3) Previously installed Uninstall any Nvidia drivers:


sudo apt-get –purge remove nvidia-*
or
sudo apt-get --purge remove nvidia-*


4) Reboot your computer

5) Choose the kernel recovery mode, choose root -> ok

6) Log in and cd to the directory where you saved your file

7) Install the drivers

sudo sh NVIDIA-Linux-x86-260.19.12.run

8) Start GDM

sudo service gdm start
Continue Reading »

Thursday, October 20, 2011

How to install Visio in Linux

Visio is one application that might be a favorite in the flowcharts ordiagrams and concepts. Visio is an application output window, butmake no mistake in Linux can be installed visio but its applicationnamed "him". Well it looks like the following



How to install it simply type the command on the console / terminal:

# Sudo apt-get install him




Continue Reading »

Tuesday, October 18, 2011

Membuat Paging di CodeIgniter

Mengapa kita perlu menggunakan paging pada sebuah applikasi web? Anda mungkin akan bertanya-tanya tentang hal itu. Paging adalah salah satu cara untuk melakukan optimasi query. Dalam sebuah kasus saya pernah mengerjakan project yang datanya dalam satu tabel itu sampai ratusan ribu record. Seandainya data tersebut di tampilkan pada sebuah halaman web saja, maka akan menghabiskan tempat. Dan akan terasa tidak enak untuk dilihat. Oleh karena itu digunakan paging untuk mengantisipasi hal itu.
CodeIgniter mempunyai class pagination untuk mengatasi hal tersebut dan penggunaannya pun juga sangat mudah. Untuk lebih jelasnya mari kita praktekkan saja.
Disini nanti kita akan buat sebuah controller dengan nama admin.php dan disimpan pada folder application/controllers. Masukkan code berikut ini kedalam file tersebut.
view plaincopy to clipboardprint?

<?php
class admin extends Controller {
 
    function admin()
    {
        parent::Controller();
        $this->load->model('admin_model');                
    }
     
    function artikel() {                            
        $data=$this->admin_model->artikel();
        $this->load->view('mypaging',$data);              
    }
}
?>

Kemudian buatlah file admin_model.php dan simpan ke dalam folder application/models kemudian masukkan code berikut ini :
view plaincopy to clipboardprint?

<?php
class admin_model extends Model{  
     
    function admin_model(){  
        parent::Model();
    }
     
    function artikel(){
        $string_query       = "select * from artikel order by artikelid";
        $query          = $this->db->query($string_query);            
        $config['base_url']     = base_url().'index.php/admin/artikel/';
        $config['total_rows']   = $query->num_rows();
        $config['per_page']     = '30';
        $num            = $config['per_page'];
        $offset         = $this->uri->segment(3);
        $offset         = ( ! is_numeric($offset) || $offset < 1) ? 0 : $offset;
         
        if(emptyempty($offset))
        {
            $offset=0;
        }
         
        $this->pagination->initialize($config);        
         
        $data['query']      = $this->db->query($string_query." limit $offset,$num");  
        $data['base']       = $this->config->item('base_url');
     
        return $data;
    }
}
?>

Kemudian buatlah file mypaging.php dan simpan kedalam folder application/views. Masukkan code berikut ini ke dalam file tersebut.
view plaincopy to clipboardprint?

<html>  
<head>  
<title>My Paging</title>  
</head>  
<body>
<table>
<thead>
    <tr>      
        <th>Artikel ID</th>                              
        <th>Judul</th>
        <th>Date</th>
        <th>Post by</th>                                
        <th>View</th>
    </tr>
</thead>
<tbody>
    <?    
    foreach($query->result() as $row)
    {                    
        echo  
        "<tr>          
            <td>$row->artikelid</td>
            <td>$row->title</td>
            <td>$row->artikeldate</td>                    
            <td>$row->postby</td>                                        
            <td>$row->view</td>
        </tr>";        
    }
    ?>        
</tbody>
</table>
<p align="center"><?=$this->pagination->create_links();?></p>
</body>
</html>

Tiga file sudah kita buat, selanjutnya akan saya jelaskan code-code pada masing-masing file tersebut. Di dalam controller admin.php tedapat constructor yang memanggil file admin_model.php. Dibawahnya lagi terdapat code berikut:
view plaincopy to clipboardprint?

function artikel() {                            
    $data=$this->admin_model->artikel();
    $this->load->view('mypaging',$data);              
}

Fungsi artikel ini akan memanggil fungsi artikel() yang ada pada admin_model dan menyimpan return valuenya ke dalam variable $data. Setelah itu fungsi ini akan memanggil file mypaging.php yang ada di folder views dengan memberikan parameter $data.
Di dalam admin_model.php sendiri terdapat fungsi artikel. Di dalam fungsi ini kita akan melakukan query untuk mengambil data di table artikel. Berikut ini scriptnya:
view plaincopy to clipboardprint?

$string_query   = "select * from artikel order by artikelid";
$query      = $this->db->query($string_query);

Kita juga akan melakukan konfigurasi untuk paging yang kita buat.
    $config['base_url'] = base_url().'index.php/admin/artikel/';
Script di atas digunakan untuk mengatur arah link dari paging yang kita buat.
    $config['total_rows'] = $query->num_rows();
Script di atas digunakan untuk mengetahui total record dari query yang kita jalankan.
    $config['per_page'] = '30';
Script di atas digunakan untuk mengatur jumlah baris yang akan di tampilkan dalam satu halaman.

Sekarang kita akan melihat script dalam file mypaging.php di folder view. Di situ terdapat script untuk menampilkan paging.
    <?=$this->pagination->create_links();?>
Script ini akan membuat paging secara otomatis
Continue Reading »

Monday, October 17, 2011

Validasi di CodeIgniter

Masalah keamanan adalah masalah klasik yang selalu menghantui semua pengguna dan pengembang website, dan untuk mencegah agar tidak terjadi hal-hal yang tidak kita inginkan salah satunya adalah dengan melakukan validasi data. CodeIgniter mempunyai sebuah class untuk melakukan validasi yaitu form_validation. Validasi biasa dilakukan ketika user mengisikan data pada sebuah form.
            Baik langsung saja saya jelaskan bagaimana caranya menggunakan class form_validation.
Buat sebuah controller dengan nama form.php dan masukkan kode berikut ini.
view plaincopy to clipboardprint?

<?php
class Form extends Controller {
    function form()
    {
        parent::Controller();
        $this->load->library('form_validation');
    }

    function index()
    {      
        $this->form_validation->set_rules('username', 'Username', 'required');
        $this->form_validation->set_rules('password', 'Password', 'required');
        $this->form_validation->set_rules('passconf', 'Password Confirmation', 'required');
        $this->form_validation->set_rules('email', 'Email', 'required|valid_email');
       
        if($this->input->post("submit"))
        {      
            if ($this->form_validation->run() == FALSE)
            {
                $this->load->view('myform');
            }
            else
            {
                echo "data yang anda masukkan sudah valid";
            }
        }
        else
        {
            $this->load->view("myform");
        }
    }
}
?>

Simpan file form.php tersebut dalam folder application/controllers.
Kemudian buatlah file myform.php dan masukkan kode berikut ini.
view plaincopy to clipboardprint?

<html>
<head>
<title>My Form</title>
</head>
<body>

<?=$this->form_validation->error_string(); ?>
<form method="post" action="<?=$base;?>form" >
<h5>Username</h5><input type="text" name="username" value="<?=$this->form_validation->set_value("username");?>" size="50" />
<h5>Password</h5><input type="text" name="password" value="" size="50" />
<h5>Password Confirm</h5><input type="text" name="passconf" value="" size="50" />
<h5>Email Address</h5><input type="text" name="email" value="<?=$this->form_validation->set_value("email");?>" size="50" />
<input type="submit" value="Submit" />
</form>
</body>
</html>

Simpan file myform.php tersebut dalam folder application/views.
Sekarang saya akan menjelaskan arti dari code-code tersebut. Di dalam class Form.php tadi terdapat constructor yang di dalamnya terdapat code
$this->load->library('form_validation');
Code ini digunakan untuk memanggil class form_validation yang berada pada folder library. Setelah itu di bawah constructor terdapat fungsi index(). Di dalam fungsi ini rule/aturan validasi di definisikan. Di situ di tuliskan ada 4 field yang diberi masing-masing role, antara lain :
view plaincopy to clipboardprint?

$this->form_validation->set_rules('username', 'Username', 'required');
$this->form_validation->set_rules('password', 'Password', 'required');
$this->form_validation->set_rules('passconf', 'Password Confirmation', 'required');
$this->form_validation->set_rules('email', 'Email', 'required|valid_email');

Fungsi untuk memberikan role validation adalah $this->form_validation->set_rules();
Fungsi ini memiliki 3 parameter. Parameter pertama adalah nama field yang akan diberi role. Parameter kedua adalah label dari field tersebut. Label disini digunakan ketika terjadi error maka label tersebut akan tampil sebagai error message. Parameter ketiga adalah role itu sendiri. CodeIgniter menyediakan banyak role, antara lain seperti contoh di atas adalah required yang artinya bahwa field tersebut tidak boleh kosong. Contoh yang lain adalah valid_email yang artinya field tersebut harus berisi alamat email. Dan masih banyak lagi role-role yang lain. Anda bisa membacanya di http://codeigniter.com/user_guide/libraries/form_validation.

Kembali pada topik cara memberikan role validation. Di sini anda bisa memberikan lebih dari satu role, yaitu dengan menambahkan tanda | pada parameter ketiga. Anda dapat melihat contoh di atas pada baris yang ke empat, yaitu memberikan role required dan valid_email pada field email.

Lalu anda bertanya, Bagaimana kalau saya punya fungsi sendiri untuk melakukan validasi? Jawabnya mudah, CodeIgniter mendukung fungsi yang anda buat sendiri. Lalu bagaimana caranya memanggil fungsi validasi yang telah saya buat? Yaitu dengan menggunakan fungsi callback. Contoh pada field username saya melakukan pengecekan tambahan.

$this->form_validation->set_rules('username','Username','required|callback_username_check');

Maka secara otomatis system akan memanggil fungsi username_check().
view plaincopy to clipboardprint?

function username_check($str)
{
    if ($str == 'test')
    {
        $this->form_validation->set_message('username_check', 'The %s field can not be the word "test"');
        return FALSE;
    }
    else
    {
        return TRUE;
    }
}


Letakkan fungsi username_check() di dalam controller.

Code selanjutnya adalah pengecekan penekanan tombol, jika tombol ditekan maka akan melakukan validasi. Fungsi untuk melakukan validasi adalah $this->form_validation->run() . Fungsi ini akan mengembalikan nilai TRUE jika tidak ada kesalahan pada waktu input. Dan mengembalikan nilai FALSE jika ada kesalahan pada waktu input.

Selanjutnya kita lihat file myform.php, di dalam file ini terdapat code <?=$this->form_validation->error_string(); ?>. Code ini digunkan untuk menampilkan semua error yang akan terjadi pada waktu input data. Jika anda ingin memisahkan error message tersebut per field sangat mudah. Yaitu dengan menggunakan fungsi <?=$this->form_validation->error(‘nama_field');?>. Di dalam fungsi ini terdapat sebuah parameter yang berisikan nama field yang akan ditampilkan error messagenya.

Di dalam file myform.php juga terdapat code ="<?=$this->form_validation->set_value("username");?>. Code ini digunakan untuk menampilkan nilai yang telah diinputkan sebelumnya. Namun itu hanya berlaku untuk tag input form atau textarea saja. Untuk tag checkbox ,select dan radio menggunakan fungsi yang berbeda-beda.

Continue Reading »

Sunday, October 16, 2011

Getting Started Create a Website with CodeIgniter

CodeIgniter has a concept of MVC (Model View Controller) in the creation of websites. MVC concept has many maanfaat among others split between logic and presentation, thus making the website could be more structured. Models are typically used to query the database for example insert, update, delete or select. While the View is used to display the output of existing processes. Controller is used to connect between the Model and View. Controllers can also be used to validate input before the data entered into the database. Next let's start creating a simple application example showing the words "hello world".




<?php
class Helloworld extends Controller {
    function Helloworld()
    {
        parent::Controller();
        $this->load->model('helloworld_model');  
    }

    function index()
    {
        $data = $this->helloworld_model->data();
        $this->load->view('output',$data);
    }
}
?>



explanation:
Remember the naming class must use capital letters at the beginning.
The script $ this-> load-> model ('helloworld_model') is used to access files named helloworld_model model.
The script $ data = $ this-> helloworld_model-> data (); used to call the function data () that existed at helloworld_model. Function has a return value that was then in the capacity into the variable $ data.
The script $ this-> load-> view ('output', $ data); used to call the view that output is accompanied by a variable named $ data in it.

4.Buatlah a model file and name it helloworld_model.php and place it in a folder system / application / models. Fill the file is as follows:




<?php
class Helloworld_model extends Model {
    function Helloworld_model()
    {
        parent::Model();
    }

    function data()
    {
        $data['test'] = 'Hello World !!';
        return $data;
    }
}
?>

5.Make a view file and name it output.php and place it in a folder system / application / view. Fill the file is as follows:

<html>
<head>
<title>Hello World !!</title>
</head>
<body>
<h1><?=$test;?></h1>
</body>
</html>


6. Please access your browser eg http://localhost/CodeIgniter/
Continue Reading »

Saturday, October 15, 2011

How to install Google Chrome in Ubuntu

Welcome to the sofyan id, in this tutorial, I will discuss on how to install the application search google chrome on ubuntu.

Software: Google Chrome.
Operating System: Ubuntu.
Skill Level: Newbie.
Estimated Time: 20 Minutes.
Google Chrome is a search application (bworser) to explore the Internet world. Google Chrome is an application developed by Google's corporate giants. Google Chrome is a lightweight and simple, yet very powerful.

The first phase to install google chrome, Google Chrome Download apalikasi here first.
Open the link above, at the time of writing this tutorial, view the website at the link above can be seen in this picture.



Click the Download Google Chrome, it will exit the dialog you need to download the package as shown in Figure 2. Because we're going to install Google Chrome on Linux, then select a package for Debian / Ubuntu. There are two versions; 32bit and 64bit versions, matching the Ubuntu operating system you use.
After that, click the Agree button, then Install, and wait until the download is complete.

The second phase of installing google chrome on ubuntu


First open the Google Chrome installer file that you downloaded as shown in Figure 3 by the double click. Wait until the ubuntu software center out. Having come out as in Figure 4, click the install button to install Google Chrome. Before the installation process, you will be prompted to enter a user password, and wait until installation process is complete.


When finished, it will be written in an Installer as in figure 5. Now you have successfully installed Google Chrome on Ubuntu.


Now you've finished installing Google Chrome, you can open the application through the menu Google Chrome in Ubuntu.

Continue Reading »

Monday, October 10, 2011

Operating File and Directory Structure in Ubuntu

Experiment 1: Directory
1.Melihat HOME directory
$ pwd
$ Echo $ HOME

2. view current directory and parent directory
$ pwd
$ Cd.
$ pwd
$ Cd ..
$ pwd
$ cd

3.make one directory, more than one directory or sub directory
$ pwd
$ Mkdir A B C A / D A / E B / F A / D / A
$ Ls-l
$ Ls-l A
$ Ls-l A / D

4. Remove one or more directories can only be done on an empty directory and can only be removed by the owner unless it is granted permission to access
$ Rmdir B (There is an error, why?)
$ Ls-l B
$ Rmdir B / F B
$ Ls-l B (There is an error, why?)

5.Navigasi directory with cd instructions to move from one directory to another directory.
$ pwd
$ Ls-l
$ Cd A
$ pwd
$ Cd ..
$ pwd
$ Cd / home / <user> / C
$ pwd
$ Cd / <user / C (There is an error, why?)
$ pwd



Experiment 2: Manipulation of the file
1.Perintah cp to copy files or entire directories
$ Cat> example
Creating a file
[Ctrl-d]
$ Cp examples example 1
$ Ls-l
$ Cp sample A
$ Ls-l A
$ Cp examples example 1 A / D
$ Ls-l A / D

2.Perintah mv to move files
$ Mv example contoh2
$ Ls-l
$ Mv example 1 contoh2 A / D
$ Ls-l A / D
$ Mv example example 1 above C
$ Ls-l C

3.Command rm to delete files
$ Rm contoh2
$ Ls-l
$ Rm-i example
$ Rm-rf A C
$ Ls-l

Experiment 3: Symbolic Link
1.Make shortcut (file link)
$ Echo "Hello, what Mr. Mouse"> halo.txt
$ Ls-l
$ Ln z halo.txt
$ Ls-l
$ Cat z
$ Mkdir mydir
$ Ln z mydir / halo.juga
$ Cat mydir / halo.juga
$ Ln-s z bye.txt
$ Ls-l bye.txt
$ Cat bye.txt


Experiment 4: Viewing File Contents
$ Ls-l
$ File halo.txt
$ File bye.txt

Experiment 5: Search for files
1.Commend find
$ Find / home-name "*. txt"-print> myerror.txt
$ Cat myerror.txt
$ Find. -Name "*. txt"-exec wc-l '{}' ';'

2.Perintah the which
$ The which ls

3.Perintah locate
$ Locate "*. txt"


Experiment 6: Search for text in files
$ Grep Hallo *. txt
Continue Reading »