Saturday, April 29, 2017

Knowledge About Hard Disk













There are various types of Hard Disks. Some of them are:

IDE : Integrated Device Electronic. Known as PATA as well.
PATA : Parallel advance technology attachment
- Mostly found in Desktop computers. But, don't use so much nowadays.

SATA: Serial advance technology attachment
- Used in Laptops, Desktops and Servers.

SCSI: Small Computer System Interface

SAS: Serial attached SCSI
- Mostly found in Servers.

Thursday, April 27, 2017

Using Computer Management Service in Windows














How to Open Computer Management Service Windows

- Press Windows and R keys together at the same time.
- Type compmgmt.msc in the run box and click OK.

Then, Computer Management Windows will be appeared.

There are Task Scheduler, Event Viewer, Shared Folders, Performance, Device Manager,  Disk Management and Internet Information Services (IIS) Manager.

Task Scheduler
       We can create and manage tasks in our computer.

Using Component Services In Windows














How to open component services in Windows

- Press Windows and R keys together at the same time.
- Type comexp.msc in the run box and click OK.
Then, component services window will be appeared.

In component services, we can use Event Viewer, Windows Logs and Services.

In Event Viewer, we can check all the events happened in our computers.
In Windows Logs, we can check the logs of Application, Security, Setup, System and Forward Event.

Wednesday, April 26, 2017

How to Configure EIGRP in Cisco Router


Router 1

Activate the connection to PC1

en
config t
int g0/0
ip address 192.168.1.1 255.255.255.0
no shut

Activate the connection to Router2

int s0/0/1
ip address 223.200.100.9 255.255.255.252
clock rate 64000
no shut


Activate the connection to Router 3
 

int s0/0/0
ip address 223.200.100.1 255.255.255.252
no shut
exit

Configure EIGRP


router eigrp 10
network 192.168.1.0 0.0.0255
network 223.200.100.0 0.0.0.3
network 223.200.100.8 0.0.0.3

end

Save the configuration

copy run start

Friday, April 14, 2017

How to configure RIP in Cisco Routers















RIP (Routing Information Protocol) is the oldest distance vector routing protocol. The maximum number of hop count is 15 and the hop count number 16 is defined as infinite distance. The converged time is slow if compared with other routing protocols such as EIGRP, OSPF and IS-IS. There are two versions in RIP: version 1 and version 2.

RIP V1

RIP v1 uses FLSM (fixed length subnet masking) and does not support VLSM(variable length subnet masking). Using FLSM causes IP wastes.

FLSM Examples,

192.168.1.0 /24
192.168.2.0 /24

RIP V2 

RIP V2 supports VLSM (variable length subnet masking). If there are different amount of hosts in an organization, we should use RIP v2.

For example,

HR Department : 20 hosts
Engineering Department: 50 hosts
IT department: 10 hosts
Sales department: 30 hosts


The following is the sample configuration of RIP in Cisco Routers.

Wednesday, April 12, 2017

DHCP Configuration in Cisco Router



DHCP is dynamic host configuration protocol. By configuration DHCP in a router, we don't need to give IPs to the hosts manually. DHCP automatically defines IPs for hosts. We can also configure DHCP in Cisco Routers as well.

The following is the sample configuration of DHCP in Cisco Router:


* Router *

en
config t
int g0/0
ip address 192.168.1.1 255.255.255.0
no shut
exit
ip dhcp pool Test
network 192.168.1.0 255.255.255.0
default-router 192.168.1.1
dns-server 192.168.1.1
end
copy run start


If you want to see sample configuration in packet tracer, you can download pkt file. Click here.

(Note: you need to have packet tracer installed in your computer to open pkt file).

Monday, April 10, 2017

String Reverse In PHP


<?php

$string = 'I am Thet Naing Win';

$string_reversed = strrev($string);

echo $string_reversed;

?>

Sunday, April 9, 2017

Cisco EtherChannel

















EtherChannel is combination of two or more physical ports into one logical/virtual port for redundancy or bandwidth needs.

Click here to download pkt file.


Note: You need cisco packet tracer to open pkt file.


How To Configure EtherCahnnel in Cisco Switches:

Switch1

Step 1 : Give Name to Switch 1

en
config t
hostname IT


Step 2 : Create VLan and give name to it

vlan 20
name IT
exit


Step 3 : Create Etherchannel

interface range f0/1 - 4
switchport mode access
switchport access vlan 20
channel-group 5 mode auto 
end

Thursday, April 6, 2017

Dell 5420













Some of my friends ask me about fair priced good used laptops. So, I post this post. This laptop is not bad for those who are looking for good used laptops with faired price. This laptop is good enough for office use.

Randomization in PHP


<?php

if(isset($_POST['roll'])){
  $rand = rand(000, 999);
  echo 'You roll a '.$rand;

}

?>

<form action="rand.php" method="POST">
<input type="submit" name="roll" value="Roll a Dice">
</form>

Ob Start in PHP


<?php ob_start(); ?>

<h1>Test</h1>
This is PHP Testing!

<?php

$direct_page = 'http://www.tnw87.com';
$direct = true;

if($direct == true){
  header('location: '.$direct_page);
}
ob_start_flush();

?>

Sunday, April 2, 2017

Matching With Function In PHP


<?php

$string = 'I am Thet Naing Win and who are you?';
$find = '/000/';

function Match($string){
  global $string;
  global $find;
  if(preg_match($find, $string)){
   return true;
  }else{
   return false;
  }
}

if(Match($string)){
  echo 'Match Found!';
}else{
  echo 'Match Not Found!';
}

?>

Matching In PHP


<?php

$string = 'Hi How are you?. I am Thet Naing Win. Nice to meet you!';

$find = '/000/';

if (preg_match($find, $string)){
  echo 'Match Found!';
}else{
  echo 'Match Not Found!';
}

?>

How To Use foreach In PHP


<?php

$food = array('Healthy'=>array('Salad', 'Milk', 'Coconet', 'Ground_nut'), 
              'Unhealthy'=>array('Alcohol', 'Beer', 'Ice_cream'));

foreach($food as $element => $inner_element){
  echo '</br><strong>'.$element.'</strong></br>';

foreach($inner_element as $item){
  echo $item.'</br>';
}
}

?>

Saturday, April 1, 2017

Array In PHP


<?php

$snack = array('Banana', 'Ice-cream', 'Coconet', 'Mango', 'Orange');

$snack[1]='Alcohol';

echo $snack[1];

//print_r($snack);

?>

Function In PHP


<?php

function Add($num1, $num2){
  $result = $num1 + $num2;
  return $result;
}

function Divide($num1, $num2){
  $result = $num1 / $num2;
  return $result;
}

$sum = Add(Add(10, 10), Divide(14, 2));
echo $sum;

?>