Important Port number | Some Useful Default Ports by Linuxtopic

default port for http, default port for ftp, default port for mysql, default port for dns, default port for nfs, default port for samab, default port of linux, default port, default port for dhcp, default port for tftp, default port for squid, linux tutorial, linux
Some Important Ports Number 

default port for http, default port for ftp, default port for mysql, default port for dns, default port for nfs, default port for samab, default port of linux, default port, default port for dhcp, default port for tftp, default port for squid, linux tutorial, linux



Important Port Number list 

1 . To see the  list of all port
vi /etc/services
2 . To see the used port of  of the services, for example we want to display mysql port
grep -i  < Service name > /etc/servicesgrep -i mysql /etc/services

mysql                3306/tcp                        # MySQL
mysql                3306/udp                       # MySQL
mysql-cluster    1186/tcp                        # MySQL Cluster Manager
mysql-cluster    1186/udp                       # MySQL Cluster Manager
mysql-cm-agent  1862/tcp                      # MySQL Cluster Manager Agent
mysql-cm-agent  1862/udp                    # MySQL Cluster Manager Agent
mysql-im          2273/tcp                        # MySQL Instance Manager
mysql-im          2273/udp                       # MySQL Instance Manager
mysql-proxy     6446/tcp                        # MySQL Proxy
mysql-proxy     6446/udp                       # MySQL Proxy
sphinxql            9306/tcp                        # Sphinx search server (MySQL listener)


Some Important Port Number  and full form 

Port Port Number Description
FTP 20 file transfer protocol : Transferring data
FTP 21 file transfer protocol : Start connection
SSH 22 Secured Shell
Telnet 23 Remote Administration
SMTP 25 Simple Mail Transfer Protocol : Mail Transfer Agent ( MTA )
DNS 53 Domain Name System
Bootp 67
DHCP 68 Dynamic Host Configuration Protocol
TFTP 69 Trivial File Transfer Protocol
HTTP 80 Hyper Text Transfer Protocol
Kerberos 88 computer network authentication protocol which works on the basis of 'tickets' to allow nodes communicating over a non-secure network to prove their identity to one another in a secure manner.
POP3 110 Post Office Protocol 3 : Mail delivery Agent
NTP 123 Network Time Protocol
NetBIOS 137 used in Samba
SMB 139 Used in SMB ( smbd )
NetBIOS 139 used datagram
SMBD 445 Post Office Protocol 3 : Mail delivery Agent
IMAP 143 Internet Message Access Protocol
HTTPS 443 Hyper Text Transfer Protocol : used ssl for secure web
Syslogd 514
Ldaps 636
FTPs 989 File Transfer Protocol Secure : used for data transfer
FTPs 990 File Transfer Protocol Secure : used for connection create
IMAPs 993 Internet Message Access Protocol
POP3s 995 Post Office Protocol 3
OpenVPN 1194
Ldaps 636
NFS 2049 Network File System
MySQL 3306 It's a database system
Squid 3128 it's a proxy server







Add/Delete Routing Table in Windows | Routing Command in Windows | Route Add


routing in windows, routing table in windows, route add command, add static route, ip r, delete route, delete route in linux, delete route command, route add default gw, route table, windows routing table command, windows routing table, windows route delete, linuxtopic,
Routing In Windows
Tags: routing in windows, routing table in windows, route add command, add static route, ip r, delete route, delete route in linux, delete route command, route add default gw, route table, windows routing table command, windows routing table, windows route delete, linuxtopic, 

Go to the Start -> Run

Type cmd for command prompt

type following command   



Add Route Temp : 


# route  add   < network >  mask <subnet/netmask> < gateway/router> 

Ex - route add  10.20.3.0 mask 255.255.255.0  10.20.2.1

Add Route Permanent  :

# route  add   < network >  mask <subnet/netmask> < gateway/router>  -p 

Ex - route add  10.20.3.0 mask 255.255.255.0  10.20.2.1 -p

Here P = Persistent Route




Add/Delete Static Route in Linux | Routing Command in Linux | IP Routing


routing in linux, ip routing, ip route command,add static route linux, add route in linux, add route in ubuntu, ip r, delete route, delete route in linux, delete route command
routing in linux
Tags: routing in linux, ip routing, ip route command,add static route linux, add route in linux, add route in Ubuntu, ip r, delete route, delete route in linux, delete route command        


Route manipulates the kernels IP routing tables.  Its primary use  is  to
set  up static routes to specific hosts or networks via an interface after
it has been configured with the ifconfig  program.


Add Route :

# route  add -net  < network >  netmask <subnet/netmask> gw  < gateway>

Ex - route add -net 10.20.3.0 netmask 255.255.255.0 gw 10.20.2.1

OR

# route  add -net  < network >  netmask <subnet/netmask> gw  < gateway>  <device>

Ex - route add -net 10.20.3.0 netmask 255.255.255.0 gw 10.20.2.1 eth1


Delete  Route :

# route  del -net  < network >  netmask <subnet/netmask> gw  < gateway>

Ex - route del -net 10.20.3.0 netmask 255.255.255.0 gw 10.20.2.1

OR

# route  del -net  < network >  netmask <subnet/netmask> gw  < gateway> <device>

Ex - route del -net 10.20.3.0 netmask 255.255.255.0 gw 10.20.2.1 eth1



Difference Between HTTP and HTTPs | http vs https


http vs https, http vs https difference, full form of http, full form of https, http stands for, http status codes, http definition, https default port, http default port, hypertext, hypertext transfer protocol
http vs https

http vs https, http vs https difference, full form of http, full form of https, http stands for, http status codes, http definition, https default port, http default port, hypertext, hypertext transfer protocol




Question :  what's Different between HTTP and HTTPs ?

                                   HTTP                   |                       HTTPS                            
  • HTTP ( Hyper Text Transfer Protocol )   HTTPs (Hyper Text Transfer Protocol                                                                                                                                 over Secure Socket Layer)
  • Work on Port  80                                             Work on port 443      
  • use plan text for data transfer ,                         use encryption for data transfer
  • No certification required                                  HTTPs  need certification
  • Operates at application layer                          Operate at  transport layer


All Interview Question : Click Here

What is a Boot Process ? | Linux Booting Interview Questions | Boot Process


boot process, boot process in linux, boot process in computer, boot process steps, booting process, booting process of linux, booting process in hindi, linux basic, boot sequence, booting sequence in linux, linux basics,boot process, boot process in linux, boot process in computer, boot process steps, booting process, booting process of linux, booting process in hindi, linux basic, boot sequence, booting sequence in linux, linux basics,

Interview Question for Linux Administrator ?















Question 1:

What is boot process in Linux?
                              OR
Explain Boot Sequence in Linux?



  1.             BIOS

  2.             POST                                                                         
                                 
  1th boot device is harddisk |

  3.             HDD

  4.             MBR   

            Boot Loader   
         Partition Table 
           Magic Number  

 5.             SPLASH                   

 6.              GRUB                      

 7.             KERNEL                 

 8.             INITRD                   

 9.              FSTAB                    

 10.           INITTAB                

  11.           RC FILE                 



Question 2:  What different between SSH and Telnet?

SSH                                                                 Telnet

Secure                                                                                 Not Secured
Port 22                                                                                Port 23
Send Data with Encryption Format                                      Send Data on plan text
Used a public key Authentication                                        not use any key

Question 3:  What's different between HTTP and HTTPs?

HTTP                                                              HTTPs

HTTP (Hyper Text Transfer Protocol)                                 HTTPs (Hyper Text Transfer Protocol Secure)
Work on Port 80                                                                 Work on port 443      
Use plan text for data transfer                                              Use encryption for data transfer
No certification required                                                      HTTPs need certification

Operates at application layer                                                Operate at transport layer
Question 4:  what's Different between NFS And Samba ?

NFS                                                              SAMBA


NFS is a protocol
SAMBA is a program that provide SMB/CIFS (Server Message Block / Common Internet File System)
NFS work's only Linux Operation System
SAMBA work's both Linux and windows OS
NFS port 2049
SAMBA port 137:netbios, nmbd, 138:smbd, 139:netbios datagram and 445:smbd
NFS Trust by default all and it's not used any authentication
SAMBA used authentication
NFS provides UNIX file system
None Provide

How To Get Hard Disk Information Serial Number In Linux | LinuxTopic



Q.  how to get hard disk serial number in linux centos6 ?
Q.  how to get hard disk Model number in linux centos6 ?
Q.  how to get hard disk full detail in linux centos6 ?









To Get Full Details of  HDD - Hard Disk Drive,

hdparm -I /dev/sda
/dev/sda:

ATA device, with non-removable media
        Model Number:       WDC WD3200AAJS-00L7A0
        Serial Number:      WD-WMAV2CL18142
        Firmware Revision:  01.03E01
        Transport:          Serial, SATA 1.0a, SATA II Extensions, SATA Rev 2.5
Standards:
        Supported: 8 7 6 5
        Likely used: 8
Configuration:
        Logical         max     current
        cylinders       16383   16383
        heads           16      16
        sectors/track   63      63
        --
        CHS current addressable sectors:   16514064
        LBA    user addressable sectors:  268435455
        LBA48  user addressable sectors:  625142448
        Logical/Physical Sector size:           512 bytes
        device size with M = 1024*1024:      305245 MBytes
        device size with M = 1000*1000:      320072 MBytes (320 GB)
        cache/buffer size  = 8192 KBytes
Capabilities:
        LBA, IORDY(can be disabled)
        Queue depth: 32
        Standby timer values: spec'd by Standard, with device specific minimum
        R/W multiple sector transfer: Max = 16  Current = 16
        Recommended acoustic management value: 128, current value: 254
        DMA: mdma0 mdma1 mdma2 udma0 udma1 udma2 udma3 udma4 udma5 *udma6
             Cycle time: min=120ns recommended=120ns
        PIO: pio0 pio1 pio2 pio3 pio4
             Cycle time: no flow control=120ns  IORDY flow control=120ns
Commands/features:
        Enabled Supported:
           *    SMART feature set
                Security Mode feature set
           *    Power Management feature set
                Write cache
           *    Look-ahead
           *    Host Protected Area feature set
           *    WRITE_BUFFER command
           *    READ_BUFFER command
           *    NOP cmd
           *    DOWNLOAD_MICROCODE
                Power-Up In Standby feature set
           *    SET_FEATURES required to spinup after power up
                SET_MAX security extension
                Automatic Acoustic Management feature set
           *    48-bit Address feature set
           *    Device Configuration Overlay feature set
           *    Mandatory FLUSH_CACHE
           *    FLUSH_CACHE_EXT
           *    SMART error logging
           *    SMART self-test
           *    General Purpose Logging feature set
           *    64-bit World wide name
           *    Segmented DOWNLOAD_MICROCODE
           *    Gen1 signaling speed (1.5Gb/s)
           *    Gen2 signaling speed (3.0Gb/s)
           *    Native Command Queueing (NCQ)
           *    Host-initiated interface power management
           *    Phy event counters
                DMA Setup Auto-Activate optimization
           *    Software settings preservation
           *    SMART Command Transport (SCT) feature set
           *    SCT Read/Write Long (AC1), obsolete
           *    SCT Write Same (AC2)
           *    SCT Features Control (AC4)
           *    SCT Data Tables (AC5)
                unknown 206[12] (vendor specific)
                unknown 206[13] (vendor specific)
Security:
        Master password revision code = 65534
                supported
        not     enabled
        not     locked
        not     frozen
        not     expired: security count
                supported: enhanced erase
        60min for SECURITY ERASE UNIT. 60min for ENHANCED SECURITY ERASE UNIT.
Logical Unit WWN Device Identifier: 50014ee057c8ea8b
        NAA             : 5
        IEEE OUI        : 0014ee
        Unique ID       : 057c8ea8b
Checksum: correct



How To Configure DNS Server In Linux CentOS by Linuxtopic


domain name, domain name system, domain name server, dns, dns server, dns full form, dns in hindi, dns configuration, dns configuration in hindi, dns server is not responding, dns server address, dns zones, dns entryQ. How to configure dns server in linux ?
Q. step by step dns server configuration in linux ?

domain name, domain name system, domain name server, dns, dns server, dns full form, dns in hindi, dns configuration, dns configuration in hindi, dns server is not responding, dns server address, dns zones, dns entry
IP  - 10.20.2.33
Hostname - khandwa.lokesh.com 
OS  - CentOS 6
PORT  - 53
The Domain Name System (DNS) is a hierarchical distributed naming system for computers, services, or any resource connected to the Internet or a private network. It associates various information with domain names assigned to each of the participating entities. It's convert ip to name or name to ip.

Package install by Yum
yum install bind*
Open configuration file & Update
vi /etc/named.conf
// NAMED.CONF
//
// PROVIDED BY RED HAT BIND PACKAGE TO CONFIGURE THE ISC BIND NAMED(8) DNS
// SERVER AS A CACHING ONLY NAMESERVER (AS A LOCALHOST DNS RESOLVER ONLY).
//
// SEE /USR/SHARE/DOC/BIND*/SAMPLE/ FOR EXAMPLE NAMED CONFIGURATION FILES.
//
OPTIONS {
LISTEN-ON PORT 53 { 127.0.0.1; 10.20.2.33; }; ### MASTER DNS IP ###
LISTEN-ON-V6 PORT 53 { ::1; };
DIRECTORY "/VAR/NAMED";
DUMP-FILE "/VAR/NAMED/DATA/CACHE_DUMP.DB";
        STATISTICS-FILE "/VAR/NAMED/DATA/NAMED_STATS.TXT";
        MEMSTATISTICS-FILE "/VAR/NAMED/DATA/NAMED_MEM_STATS.TXT";
ALLOW-QUERY     { LOCALHOST; ANY; }; ### ANY ###
ALLOW-TRANSFER{ LOCALHOST; 10.20.2.34; }; #SLAVE DNS IP IF WE HAVE SLAVE DNS OTHERVISE DISABLE IT 
RECURSION YES;
DNSSEC-ENABLE YES;
DNSSEC-VALIDATION YES;
DNSSEC-LOOKASIDE AUTO;
/* PATH TO ISC DLV KEY */
BINDKEYS-FILE "/ETC/NAMED.ISCDLV.KEY";
MANAGED-KEYS-DIRECTORY "/VAR/NAMED/DYNAMIC";
};
LOGGING {
        CHANNEL DEFAULT_DEBUG {
                FILE "DATA/NAMED.RUN";
                SEVERITY DYNAMIC;
        };
};
ZONE "." IN {
TYPE HINT;
FILE "NAMED.CA";
};
INCLUDE "/ETC/NAMED.RFC1912.ZONES";
INCLUDE "/ETC/NAMED.ROOT.KEY";
domain name, domain name system, domain name server, dns, dns server, dns full form, dns in hindi, dns configuration, dns configuration in hindi, dns server is not responding, dns server address, dns zones, dns entry



Configure Zone file in
vi /etc/named.rfc1912.zone
ZONE "LOKESH.COM" IN {      #CHANGE YOUR DOMAIN NAME #
        TYPE MASTER;
        FILE "FORWARD.ZONE";    # FORWARD ZONE FILE #
        ALLOW-UPDATE { NONE; };
};
ZONE "LOCALHOST" IN {
        TYPE MASTER;
        FILE "NAMED.LOCALHOST";
        ALLOW-UPDATE { NONE; };
};
ZONE "1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.IP6.ARPA" IN {
        TYPE MASTER;
        FILE "NAMED.LOOPBACK";
        ALLOW-UPDATE { NONE; };
};
ZONE "33.2.20.10.IN-ADDR.ARPA2.20.10.IN-ADDR.ARPA" IN {   # SET YOUR DNS IP
        TYPE MASTER;
        FILE "REVERSE.ZONEREVERSE.ZONE";     # REVERSE ZONE FILE #
        ALLOW-UPDATE { NONE; };
}
ZONE "0.IN-ADDR.ARPA" IN {
        TYPE MASTER;
        FILE "NAMED.EMPTY";
        ALLOW-UPDATE { NONE; };



Create forward & reverse Zone files
Copy named.localhost & named.loopback file
cp /var/named/named.localhost /var/named/forward.zonecp /var/named/named.loopback /var/named/reverse.zone


Configure Forward Zone

vi /var/named/forward.zone
$TTL 1D
@   IN  SOA     KHANDWA.LOKESH.COM. RNAME.INVALID. (
                             0  ;SERIAL
                             1D        ;REFRESH
                             1H        ;RETRY
                             1W      ;EXPIRE
                             3H       ;MINIMUM
)
               NS          @
               A          127.0.0.1
@       IN  NS          KHANDWA.LOKESH.COM.
@       IN  NS          SECONDARYDNS.LOKESH.COM.  # SERCONDRY DNS NAME #
@       IN  A           10.20.2.33
@       IN  A           10.20.2.34# SECONDRY DNS IP #
@       IN  A           10.20.2..102
KHANDWA       IN  A   10.20.2.33
SECONDARYDNS    IN  A   10.20.2.34
CLIENT          IN  A   10.20.2.102


Configure Reverse Zone
vi /var/named/reverse.zone
$TTL 1D
@   IN  SOA     KHANDWA.LOKESH.COM. RNAME.INVALID. (
        0  ;SERIAL
        1D        ;REFRESH
        1H        ;RETRY
        1W      ;EXPIRE
        3H )       ;MINIMUM
)
               NS          @
               A          127.0.0.1
@       IN  NS          KHANDWA.LOKESH.COM.
@       IN  NS          SECONDARYDNS.LOKESH.COM.
@       IN  PTR         LOKESH.COM.
MASTERDNS       IN  A   10.20.2.33
SECONDARYDNS    IN  A   10.20.2.34
CLIENT          IN  A   10.20.2.102
33     IN  PTR         KHANDWA.LOKESH.COM.
34     IN  PTR         SECONDARYDNS.LOKESH.COM.
102    IN  PTR        CLIENT.LOKESH.COM.


To test DNS configuration and zone files 
named-checkconf /etc/named.confnamed-checkzone lokesh.com /var/named/forward.zonenamed-checkzone lokesh.com /var/named/reverse.zone
Start the DNS service
service named startchkconfig named on
Adjust iptables to allow DNS server from outside of the network
vi /etc/sysconfig/iptables
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
-A INPUT -P UDP -M STATE --STATE NEW --DPORT 53 -J ACCEPT   # ADD LINE #
-A INPUT -P TCP -M STATE --STATE NEW --DPORT 53 -J ACCEPT   #ADD LINE #
-A INPUT -M STATE --STATE ESTABLISHED,RELATED -J ACCEPT

To Restart Service 
service iptables restart
To test DNS Server using dig command
dig khandwa.lokesh.com
; <<>> DIG 9.8.2RC1-REDHAT-9.8.2-0.30.RC1.EL6_6.3 <<>> KHANDWA.LOKESH.COM
;; GLOBAL OPTIONS: +CMD
;; GOT ANSWER:
;; ->>HEADER<<- OPCODE: QUERY, STATUS: NOERROR, ID: 11151
;; FLAGS: QR AA RD RA; QUERY: 1, ANSWER: 1, AUTHORITY: 1, ADDITIONAL: 0

;; QUESTION SECTION:
;KHANDWA.LOKESH.COM.            IN      A

;; ANSWER SECTION:
KHANDWA.LOKESH.COM.     86400   IN      A       10.20.2.33

;; AUTHORITY SECTION:
LOKESH.COM.             86400   IN      NS      KHANDWA.LOKESH.COM.

;; QUERY TIME: 0 MSEC
;; SERVER: 10.20.2.33#53(10.20.2.33)
;; WHEN: SAT JUL 11 21:26:14 2015
;; MSG SIZE  RCVD: 66
nslookup lokesh.com

Server: 10.20.2.33
Address: 10.20.2.33#53


Command for Check MX Record
host -t mx [hostname]
host -t MX khandwa.lokesh.com
Some Useful DNS Record

TypeValueDescriptionFunction
A1Address recordReturns a 32-bit IPv4 address, most commonly used to map hostnames to an IP address of the host.
AAAA28IPv6 Address recordReturns a 128-bit IPv6 address, most commonly used to map hostnames to an IP address of the host.
CNAME5Canonical name recordAlias of one name to another: the DNS lookup will continue by retrying the lookup with the new name.
DNSKEY48DNS Key RecordThe key record used in DNSSEC. Uses the same format as the KEY record.
LOC29Location recordSpecifies a geographical location associated with a domain name
MX15Mail exchange recordMaps a domain name to a list of message transfer agents for that domain
NS2Name server recordDelegates a DNS zone to use the given authoritative name servers
PTR12Pointer recordPointer to a canonical name. Unlike a CNAME, DNS processing stops and just the name is returned. The most common use is for implementing reverse DNS lookups, but other uses include such things as DNS-SD.
SOA6Start of [a zone of] authority recordSpecifies authoritative information about a DNS zone, including the primary name server, the email of the domain administrator, the domain serial number, and several timers relating to refreshing the zone.