+ All Categories
Home > Documents > hat Administration

hat Administration

Date post: 07-Apr-2018
Category:
Upload: arunkumar-jolad
View: 223 times
Download: 0 times
Share this document with a friend

of 21

Transcript
  • 8/3/2019 hat Administration

    1/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Level 2 Redhat Administration

    BIOS-GRUB-INITProcess of changing root password

    Boot to Grub

    In the grub press P to enter the GRUB password, E to edit

    Root (hd0,0)

    Kernel /vmlinuz-2.6.18-53.el5 ro root=label=/1 rhgb quiet single

    Add this or 1 to boot to single user mode as root

    Initrd /initrd-2.6.18-53.el5.img

    Hit enter and b to boot the operating system.

    Note: This mode is used for backing up the file system or management

    of logical values.

    Sh-3.1# df h

    #whoami ( this will display as root)

    #passwd (execute root password change)

    Boot Process

    Power-ON

    BIOS (Ram, Keyboard, Mouse, Storage, etc.)

    Bootable Media (MBR) 512 bytes) [boot code is found in MBR]

    Stage1 GRUB (Grand unified boot loader)

    GRUB Stage 1.5 (provides menu to user where we select the operating system)

    #df h

    #cd /boot

    #ls ltr

  • 8/3/2019 hat Administration

    2/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    #cd grub/

    Note: we can find stage1 and stage2 files

    #which init

    #ls ltr /sbin [we can find which are required to execute]

    #cd /etc

    #ls ltr grub.conf

    # less grub.conf

    # less inittab -> in etc

    GRUB (stage2 )

    INIT -> /etc/inittab sets up the appropriate runlevel

    Runlevel

    #cd /etc/rc.d/

    # ls -ltr

    rc.local launch programs outside rc.sysinit. (outside runlevel)

    rc.sysinit script which is consulted in every run level.

    Rc (works same)

    init.d (has all programs / deamons / services which is there on your computer)

    All te directories rc0.d,rc1.d, -------------- link to init.d to run the p/d/s to specific to the runlevels.

    # cd rc1.d /

    # ls -ltr# ls -l s* (defines start scripts)

    # ls -l k* (defines kill scripts)

    To move to run level 3

    #init 3

    # tty (terminal/ conso1)

  • 8/3/2019 hat Administration

    3/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    # Run level

    RH5 (Linux Rescue)

    Changing the root password : when you have forgot the GRUB & ROOT password.This is calledlinux rescue or linux emergency.

    # reboot

    Set bios to boot from CD.

    Insert the linux boot image install CD/DVD.

    Boot: linux rescue

    Rescue method

    what type of media contains the rescue image?

    Local CDROM

    Hard drive

    NFS image

    ftp

    HTTP

    Choose the method to rescue the system from which you have installed the O's.

    sh-3.1 # df -h

    # cd /mnt/sysimage/

    # ls -ltr# df -h

    # passwd root

    # chroot /mnt/sysimge

    # df -h

    # who am i

  • 8/3/2019 hat Administration

    4/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    # passwd root

    Boot problems:

    # cd /etc

    # ls -l grub.conf

    # nano grub.conf

    [translates to dev/sda1 file system]

    (hd 0,0) -> translates to first partition

    # df -h

    /dev/sda1 99 M 11 M 83 M 12% /boot

    Note: hda, sda = hd0 ---> first hard drive

    [IDE/ATAPI [sata hard drive]

    hda1, sda1 = hd 0, 0 --> indicating first harddrive first partition.

    # ls -ltr /boot/

    # nano grub.conf

    title Red hat enterprsise linux server (2.6.18-53.el5) root (hd 0,0)

    change to 1 *( so that the system will not boot.)

    Error generated:

    Booting 'RedHat Enterprise Linux server (2.6.18-------)

    root (hd1,0)

    error 21: selected disk does not exist

    press any key to continue.

    We can directly edit the grub from grub menu. But that will remain only for that instance & willnot write the changes to hard drive /etc/grub.conf

    Boot problem 2

  • 8/3/2019 hat Administration

    5/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Add a new entry to the kernal & reboot the system.

    Booting 'Red Hat enterprise------]

    root [hd0,0]

    file system type is ext2fs, partition type 0x83 kernel /vmlinu-2.6.18-53.cl5 ro root =LABEL=/1rhgb quiet

    Error 15: file not found

    press any key to continue

    [Boot problem] 3

    # ed /boot/

    # ls -ltr

    #mv initrd-2.6.18-53.el5.img initrd -2.6.18-53.el5.img.corrupt

    #shutdown

    Booting 'red hat enterprise linux -------]

    root (hd0,0)

    file system type is et2fs, partition type 0x83 kernel/vmlinuz----

    [Linux-bz image, setup=0xle00, size=0x1b3654]

    initrd/ initrd-2.6.18-53.el5.img

    Error 15: file not found

    pres any key to continue.

    Try this: in Grub boot menu.

    Initrd/ initrd 2.6.18-53 el5.img.corrupt

    e.g. Pres b to boot# cd /boot/

    # ls -ltr

    # mv initrd-2.6.18-53.el5.img.corrup

    initrd-2.6.18-53.el5.img

    # cd grub /

  • 8/3/2019 hat Administration

    6/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    # ls -ltr

    # nano grub

    # reboot

    [Boot problem 4]

    fstab corrupt

    [file system table]

    # run level

    # cd /etc

    # less fstab [has translation b/w partitions & mount points]

    #mv fstab fstab.corrupt

    go through linux rescue booting through Bootable media.

    # df -h [u will not find any file system]

    # fdisk -l [display connected harddrive & partition info]

    # mkdir /mnt/sysimage

    # mount /dev/sda2 /mnt/sysimage/ [-> where linux redhat partition is available]

    # cd /mnt/sysimage/

    # ls ( will show the directory structure)

    # cd etc /

    # mv fstab.corrupt fstab

    # less fstab

    # reboot

  • 8/3/2019 hat Administration

    7/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Basic Provisioning of Partitions and File Systems

    Features:

    1. Ability to provision extra storage on-the-fly

    Steps:

    1. Identify available storage

    a. 'fdisk -l' - returns connected storage

    2. Create partitions on desired hard drive:

    a. 'fdisk /dev/sdb' - interacts with /dev/sdb drive

    b. 'n' - to add a new partition

    c. 'p' - primary

    d. '1' - start cylinder

    e. '+4096M' - to indicate 4 Gigabytes

    f. 'w' - to write the changes to the disk

    Note: use 'partprobe partition (/dev/sdb1)' to force a write to a hard drive's partition table on arunning system

    Note: 'fdisk' creates raw partitions

    3. Overlay (format) the raw partition with a file system

    a. mke2fs -j /dev/sdb1 - this will write inodes to partition

    4. Mount the file system in the Linux file system hierarchy:

    a. mkdir /home1 && mount /dev/sdb1 /home1

    b. mount OR df -h - either will reveal that /dev/sdb1 is mounted

    Note: lost+found directory is created for each distinct file system

    5. Configure '/home1' to auto-mount when the system boots

    a. nano /etc/fstab and copy and modify the '/home' entry

  • 8/3/2019 hat Administration

    8/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    To move an existing user to /home1

    # usermod -d /home1/student1 -m student1

    To create new user on /home1

    # useradd -d /home1/student1 student1

    To delete the user

    # userdel -r student1

    Swap Partitions & Files

    Features:1. Extra, virtual RAM for the OS

    Steps:1. Identify current swap spacea. swapon -s - enumerates partitions and/or files, which constitute swap storage

    b. free -m

    2. Select target drive and provision swap partitiona. fdisk /dev/sdbb. nc. 2d. 500e. +512 (cylinder 562) - 63 cylinders are required for 512MBf. t - change typeg. 82 - Linux Swap/Solarish. w - committ changes to disk

    3. Create the swap file system on the raw partition: /dev/sdb2a. mkswap /dev/sdb2

    4. Enable swapping - publish the swap space to the kernela. swapon /dev/sdb2 - this enables swapping on /dev/sdb2

    5. update /etc/fstaba. /dev/sdb2 swap swap defaults 0 0

  • 8/3/2019 hat Administration

    9/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    swapoff /dev/sdb2 - disables swapping on /dev/sdb2

    Task:

    1. Improve system performance by distributing swapping to /dev/sdb2a. swapon /dev/sdb2b. swapoff /dev/sda6c. disable /dev/sda6 via /etc/fstab

    Create Swap based on File

    Features:

    1. The ability to provision swap space based on a file, similar to pagefile.sys in Windows NT,

    etc., if you have an available disk space to partition2. Doesn't waste partitions

    Task:1. Create 512MB swap filea. dd if=/dev/zero of=/home1/swapfile1 bs=1024 count=524288b. mkswap /home1/swapfile1 - overlays swap file systemc. swapon /home1/swapfile1 - makes swap space avaialable to the kernel

    2. Ensure that when the system reboots, the swapfile is made available to the kernela. nano /etc/fstab - /home1/swapfile1 swap swap defaults 0 0

    3. Create 2GB swap filea. dd if=/dev/zero of=/home1/swapfile2 count=2G

    Logical Volume Management (LVM)

    Features:1. Ability to create volume sets and stripe sets2. LVM masks the underlying physical technology (ATA,ATAPI,IDE,SCSI,SATA,PATA,etc.)3. LVM represents storage using a hierarchy:a. Volume groupsa1. Physical volumes (/dev/sda2, /dev/sdb2, etc.)b. Logical Volumesb1. File systems

    4. LVM physical volumes can be of various sizes5. Ability to resize volumes on the fly

  • 8/3/2019 hat Administration

    10/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Note: Volume groups join: physical volumes (PVs) and Logical Volumes (LVs)

    6. Steps to setup LVM:1. Create LVM partitions via fdisk or parteda. fdisk /dev/sda, /dev/sdb, /dev/sdcb. nc. pd. +10Ge. t - change to type '8e' (LVM)f. wg. partprobe /dev/sda

    2. Create Physical Volumes using 'pvcreate'a. pvcreate /dev/sda3 /dev/sdb3 /dev/sdc3

    3. Create Volume Groups using 'vgcreate'a. vgcreate volgroup001 /dev/sda3 /dev/sdb3 /dev/sdc3

    Note: Volume groups can be segmented into multiple logical volumes

    4. Create one or more Logical Volumesa. lvcreate -L 10GB -n logvolvar1 volgroup001b. lvcreate -L 10GB -n logvolusr1 volgroup001

    5. Create File system on logical volume(s)a. mke2fs -j /dev/volgroup001/logvolvar1b. mke2fs -j /dev/volgroup001/logvolusr1

    6. Mount logical volumea. mkdir /var1b. mount /dev/volgroup001/logvolvar1 /var1c. mkdir /usr1d. mount /dev/volgroup001/logvolusr1 /usr1

    Note: Be certain to update: /etc/fstab so that volumes are mounted when the system reboots

    3-tiers of LVM display commands include:a. pvdisplay - physical volumes - represent raw LVM partitionsb. vgdisplay - volume groups - aggregate physical volumesc. lvdisplay - logical volumes - file systems - mount here

    Rename of Logical Volume:1. lvrename volume_group_name old new - used to rename volumes

  • 8/3/2019 hat Administration

    11/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Task: Rename 'logvolvar1' to 'logvolopt1'a. lvrename volgroup001 logvolvar1 logvolopt1

    Note: LVM is updated immediately, even while volume is mountedHowever, you must remount the logical volume to see the changesb. umount /var1 && mount /dev/mapper/volgroup001-logvolopt1 /opt1c. Update /etc/fstab

    Remove Logical Volume:Task: Remove 'logvolusr1' from the logical volume poola. umount /usr1b. lvremove /dev/mapper/volgroup001-logvolusr1c. use 'lvdisplay' to confirm removal

    Resize Logical Volume:Task: Grow (resize) 'logvolopt1' to 20GBa. lvresize -L 20GB /dev/volgroup001/logvolopt1b. lvdisplay - to confirm new size of logical volumec. df -h - will still reveal the current sized. Resize the file system to update the INODE table on the logical volume to account for the newstorage in 'logvolopt1''resize2fs -f -p /dev/volgroup001/logvolopt1'

    Note: You may resize file systems online if the following are met:1. 2.6x kernel series2. MUST be formatted with ext3

    Task: Shrink (resize) 'logvolopt1' to 15GBa. lvresize -L 15GB /dev/volgroup001/logvolopt1b. lvdisplayc. df -hd. resize2fs -f -p /dev/volgroup001/logvolopt1Note: online shrinking is not supportede. df -h

    Note: Check disk utilization prior to shrinking to reduce the risk of losing data

    LVM GUI Utility:system-config-lvm

    RAID

    Features:

  • 8/3/2019 hat Administration

    12/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    1. The ability to increase availability and reliability of data

    Tasks:1. Create a RAID-1 Device (/dev/md0..n)a. fdisk /dev/sdb - to create usable raw partitionsb. partprobe /dev/sdb - to force a kernel update of the partition layout of the disk: /dev/sdbb. mdadm --create /dev/md0 --level=1 --raid-devices=2 /dev/sdb5 /dev/sdb6c. cat /proc/mdstat - lists active RAID (md) informationd. mke2fs -j /dev/md0 - overlays a file system on the RAID devicee. mount /dev/md0 /raid1f. update: /etc/fstab

    Note: use 'mdadm --query /dev/md0' to get information about a RAID device

    Note: You may create RAID volumes/devices on a single or on multiple disksIdeally, your RAID volumes should span multiple physical disks to improve:a. reliabilityb. performancec. availability

    2. Remove the RAID-1 devicea. umount /dev/md0b. mdadm --manage --stop /dev/md0

    3. Create a RAID-5 Volumea. fdisk /dev/sdb - to create a partition number 7b. partprobe /dev/sdb - to update the kernel's view of the partition tablec. mdadm --create /dev/md0 --level=5 --raid-devices=3 /dev/sdb5 /dev/sdb6 /dev/sdb7d. watch cat /proc/mdstat - refreshes every 2 secondse. Overlay a file system: mke2fs -j /dev/md0f. mount /dev/md0 /raid5g. Test I/O to RAID-5 deviceh. Update: /etc/fstab

    RPM

    Features:1. Provides package managementa. Queryb. Installc. Uninstalld. Upgradee. Verify

  • 8/3/2019 hat Administration

    13/21

  • 8/3/2019 hat Administration

    14/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Removal:1. rpm -ev *.rpm - removes a pacakgeNote: removal process considers dependencies and will complain if the removal will break 1 or

    more packages. To get around this, use '--nodeps' option with 'rpm -ev --nodeps *.rpm'

    2. rpm -ev gftp

    Package Management GUI:1. Add/Remove Software2. system-config-packages

    YUM Configuration

    Features:1. The ability to centralize packages (updates)

    Setting up local yum repository:-

    Assuming you have your Linux distribution DVD / CDs copied into a directory named"/data/rhel_5.2dvd", then you would setup a yum repository file as shown below, to help youeliminate the need to copy/install individual packages all the time , and use the power of yuminstead:-

    [root@Unix Server]# cat /etc/yum.repos.d/localmedia.repo[rhel-localmedia]name=RedHat Enterprise Linux $releasever - $basearchbaseurl=file:///data/rhel_5.2dvd/Server/enabled=1gpgcheck=1gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release[root@Unix Server]#

    Note: Ensure that about 3GBs are available for the yum respository

    Yum Usage:1. Search for packagesa. 'yum search gftp'

    2. Install packages - Requires RedHat GPG Key for RPMsrpm --import http://192.168.75.100/RH5/i386/RPM-GPG-KEY-redhat-releasea. 'yum -y install gftp'b. 'yum -y install gftp dhcp' installs 2 packages

  • 8/3/2019 hat Administration

    15/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    3. Remove Packagea. 'yum -y remove gftp'

    Cron Scheduler

    Features:1. Scheduler2. Rules (Cron entries) are based on times:a. minute (0-59)b. hour (0-23)c. day of the month (1-31)d. month (1-12)

    e. day of the week (Sun,Mon,Tue, etc. OR 0-7)f. command to execute (shell, perl, php, etc.)

    3. Wakes up every minute in search of programs to execute4. Reads cron entries from multiple files5. Maintains per-user and system-wide (/etc/crontab) schedules

    /etc:cron.d/cron.deny - denies cron execution by usercron.monthly/ - runs jobs monthlycron.weekly/ - runs jobs weekly

    cron.daily/ - runs jobs dailycron.hourly/ - runs jobs hourlycrontab - contains system-wide schedules

    Note: '*' wildcard in a time column means to run for all values

    Per-user Crontabs:Stored in: /var/spool/cron

    Task:1. Create a cron entry for the user 'student1'

    a. su student1b. crontab -ec. create an entry, minus the name of the user

    Note: 'crontab -l' - enumerates per-user cron entries

    System-wide Crontab:Stored in: /etc/crontab

  • 8/3/2019 hat Administration

    16/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Task:1. Create a cron entry in: /etc/crontab

    Note: 'crontab -l -u username' - enumerates per-user cron entries

    e.g for cron job as follows:create a shellscript asnano loadshelljob1.sh with following contents in it:#! /bin/bash

    FILENAME=/home/krishna/loasjob1.txtuptime | awk '{ print $1, $2, $3, $4, $5 }' >> $FILENAME

    # chmod +x loadshelljob1.sh

    # ./loadshelljob1.sh# cat loasjob1.txt

    create the cron job entry by# crontab -e

    1 * * * * /home/krishna/loadshelljob1.sh

    The cron job entries in the crontab can be listed by command:# crontab -l

    SysLogD

    Features:1. Handles logging2. Unix Domain Sockets (/dev/log)3. Internet Sockets (UDP:514)4. Ability to log to local and remote targets

    Implented as 'sysklogd' package

    Primary configuration file: /etc/syslog.conf

    Standard syslog.conf file contains:1. Rulesa.facilities -> applications/daemons/network device/etc.b. levels -> Importance of messageRange: 0-77 = emergency (less information)

  • 8/3/2019 hat Administration

    17/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    6 = alert5 = critical4 = error

    3 = warning2 = notice1 = info0 = debug (more information)

    2. Targetsa. file - /var/log/messagesb. tty - /dev/consolec. remote hosts - @IP_ADDR_of_REMOTE_HOST

    '*' = catchall/wildcard to mean any facility or level

    '.none' = exclusion rule

    'man syslog.conf' to learn about the support facilities.levels

    Task:1. Enable UDP logging for remote Cisco gateway (192.168.75.1)a. netstat -nul | grep 514 - reveals UDP:514 listenerb. nano /etc/sysconfig/syslogb1. 'SYSLOGD_OPTIONS="-r"'c. restart syslog and confirm UDP:514 listener

    c1. confirm using 'netstat -nul | grep 514'd. Configure the router using facility 'local0' and level 'info'e. configure /etc/syslog.conf to accept 'local0.info'f. restart or reload 'syslog'

    Log Rotation

    Features:

    1. Rotation of logs based on criteriaa. sizeb. age (daily, weekly, monthly)

    2. Compression3. Maintain logs for a defined period

    /etc/logrotate.conf - primary (global) config file for all logs-can be overriden by context-sensitive files. i.e. apacherun 'man logrotate'

  • 8/3/2019 hat Administration

    18/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    /etc/logrotate.d - directory for logs to be rotated-httpd - used to rotate Apache logs

    /var/log/httpd/*log {missingoknotifemptysharedscriptspostrotate

    /bin/kill -HUP `cat /var/run/httpd.pid 2>/dev/null` 2> /dev/null || trueendscript

    }

    Task: Setup rotation rule for Cisco log1. Create entry in: /etc/logrotate.d based on /etc/logrotate.d/syslog

    2. Modified the entry to rotate based on new criteria3. Rotated using: 'logrotate /etc/logrotate.conf'Note: Force using: 'logrotatate -f /etc/logrotate.conf'

    Commong Network Utilities

    Features:1. Useful for basic troubleshooting

    PING:Features:1. ability to communicate with hosts using ICMPa. PING sends ICMP echo-requestsb. PING expects to receive ICMP echo-replies

    Task: PING some hosts and evaluate the output1. ping localhost (127.0.0.1)2. ping -c 3 localhost - sends 3 ICMP echo-requests

    Note: 'ping localhost' performs name resolution using /etc/hosts/etc/hosts stores static name-to-IP mappings

    Note: 127.0.0.0/8 is fully-reserved to the loopback adapter of ALL IPv4 hosts

    3. ping -c 3 192.168.75.1994. ping -c 3 -i 3 192.168.75.199 - delays PINGs to 3 seconds apart

  • 8/3/2019 hat Administration

    19/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Note: PING defaults to a standard 1-second intervalNote: Firewall(s) may block ICMP traffic, causing PING to fail

    TELNET:Features:1. Great for basic TCP port diagnosis

    Task:1. Connect to TCP ports on various hostsa. telnet 192.168.75.100 22b. telnet www.unixservices.com 80

    NETSTAT:

    Features:1. Provides network connection information from /proc/net/*

    Task:1. Return useful information for various protocolsa. netstatb. netstat -a - returns all protocols/socketsc. netstat -ntlp - returns all TCP LISTENERS without name resolutiond. netstat -nulp - returns all UDP lISTENERS without name resolution

    Note: netstat uses /etc/services to translate ports to names

    Note: 0.0.0.0:514 - this means that Syslog will accept traffic to any of the defined IPaddresses/interfaces on the system

    e. netstat -ntp - returns established connections (sockets)f. netstat -rn - returns the routing table

    ARP:Features:1. Resolves layer-2 (OSI model) MAC addresses to layer-3 IP addresses

    Task:1. Examine MAC addresses using: ifconfig and arpa. ifconfig - returns our local MAC addressesLink encap:Ethernet HWaddr 00:02:B3:98:41:08

    b. arp -a - returns MAC to IP mappings

    Note: When 2 TCP/IP hosts communicate, ARP is performed to translate the IP address (v6/v4)to a MAC address.

  • 8/3/2019 hat Administration

    20/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    Note: If a one or more routers separate the communicating hosts, then the MAC address of thedefault router's (gateway's) interface is stored by each client

    IPv4 Configuration & Network Settings

    Network Support:1. Boot system into a multi-user mode2. /etc/modprobe.conf - contains alias and reference to module(s) to be loaded in order to

    provide networking3. Linux decides if the interface is DHCP or static by viewing the contents of:a. /etc/sysconfig/network - networking=yes|no, IPv6_Support, Default Gateway, etc.b. /etc/sysconfig/network-scripts/ifcfg-eth0 - contains ifup, ifdown, and ifcfg-* scriptsc. /etc/init.d/network - main service

    service network status - checks networking

    system-config-network-* - network interface configuration

    Note: Either update your net configuration manually from the shell, or using the 'system-config-network*' tools to avoid losing settings

    /etc/resolv.conf - DNS configuration file/etc/hosts - static list of hosts

    IPv4 Aliases:1. ifconfig eth0:1 192.168.75.112. ifconfig eth0:2 192.168.76.11

    Note: To ensure that aliases persist do the following:1. cp /etc/sysconfig/network-scripts/ifcfg-eth0 ./ifcfg-eth0:12. Modify ifcfg-eth0:1 to reflect aliased IP

    Note: Aliases do NOT work with DHCP interfaces

    ifconfig eth0:2 del 10.168.76.11 - removes the virtual interface

    IPv6 Config:Features:1. Auto-configured by default gateway (router)2. fe80:: - link-local address (loopback/local subnet address)3. 2002:: - 6to4 address, that can be configured based on IPv4 embedded address, using HEX

    notation

    ping6 -I eth0 fe80::

  • 8/3/2019 hat Administration

    21/21

    Page 1 of21

    Created by Unix Services (An Unix and Linux Training Company)

    traceroute6 - used to trace routes on IPv6 networks

    Run level Service Management tools

    Features:

    1. The ability to indicate desired run levels for service2. Service are located in /etc/init.d

    Usage:

    1. ntsysv - manages services in the current run level2. ntsysv 35 manages services for run levels 3&5

    Note:

    ntsysv nor chkconfig starts/stops servicechkconfig usag:

    1. chkconfig - - list ntpd returns run level environment for ntpdNote:

    Items listed as off have k (kill) scriptsNote:

    Items listed as on have S (start) scipts

    2. chkconfig - -level 3 ntpd off creates a K (kill) scripts in run level 33. chkconfig - - level 35 ntpd off4. chkconfig ntpd on :- enables ntpd in levels 2-55. chkconfig ntpd off :- disables ntpd in levels 0-6

    Note:Use chkconfig from the shell or a script

    Note:Use ntsysv from the shell in interactive mode

    Note:When controlling services using chkconfig reference the name of theService as its specified in: /etc/init.d

    System- config services GUI tool to manage services


Recommended