Skip to main content

Posts

Difference between SSH and SSL

SSH vs SSL The internet has opened a lot of doors, and windows as well. You can essentially do anything with internet nowadays. People can buy and do transactions online. You can reboot any  computer  system or program in your office from your personal computer. People do not even have to leave their homes anymore. Since there are lot of open doors and windows, hackers and eavesdroppers can illegally  get  personal  information  and have access to your personal program and files. Therefore, people now demand  web  security. Enter  SSH  and SSL. Both are public key cryptography tunneling protocols and aims to create a secure, confidential exchange of  data  and connection across the network particularly, the internet. The encryption technologies used by both protocols are very reliable, and it is extremely difficult or impossible for hackers to break into them. SSH SSH means “Secure Shell”. It has a built-in  username/password authentication   system  to establish a connectio
Recent posts

Boot process hangs at dracut: Switching root

Environment Red Hat Enterprise Linux 6 Issue When server is booting the boot process hangs at  dracut: Switching root , and never displays anything else. Raw device-mapper: ioctl: 4.33.1-ioctl (2015-8-18) initialised: xx-xxxx@redhat.com udev: starting version 147 dracut: Starting plymouth daemon dracut: rd_NO_DM: removing DM RAID activation dracut: rd_NO_MD: removing MD RAID activation scsi0 : ata_piix scsi1 : ata_piix ata1: PATA max MWDMA2 cmd 0x1f0 ctl 0x3f6 bmdma 0xc120 irq 14 ata2: PATA max MWDMA2 cmd 0x170 ctl 0x376 bmdma 0xc128 irq 15 Refined TSC clocksource calibration: 2599.999 MHz. virtio-pci 0000:00:03.0: PCI INT A -> Link[LNKC] -> GSI 11 (level, high) -> IRQ 11 virtio-pci 0000:00:05.0: PCI INT A -> Link[LNKA] -> GSI 10 (level, high) -> IRQ 10 virtio-pci 0000:00:07.0: PCI INT A -> Link[LNKC] -> GSI 11 (level, high) -> IRQ 11 virtio-pci 0000:00:08.0: PCI INT A -> Link[LNKD] -> GSI 11 (level, high) -> IRQ 11 input: ImExPS/2 Gener

How to mount a non root filesystem early in the boot process

Environment Red Hat Enterprise Linux 7 Issue I would like to mount a non root filesystem early in the boot process Resolution Create  /etc/fstab.sys Raw # vi /etc/fstab.sys UUID="71be1001-d764-4505-a225-30d4771833f5" /mnt/test xfs defaults 0 0 fstab.sys  uses the same syntax style as  /etc/fstab Rebuild  initramfs Raw # dracut -f Reboot Raw # reboot Root Cause The  dracut fstab-sys  module allows the ability to load a seperate  fstab  into the initramfs which can allow the ability to load a file system earlier in the boot process. /usr/lib/dracut/modules.d/95fstab-sys/module-setup.sh Raw #!/bin/bash # -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- # ex: ts=8 sw=4 sts=4 et filetype=sh check() { test -f /etc/fstab.sys || [[ -n $add_fstab || -n $fstab_lines ]] } depends() { echo fs-lib } install() { [ -f /etc/fstab.sys ] && inst_simple /etc/fstab.sys inst_hook pre-pivot 00 &qu

How to get list of all the files which are touched by Red Hat Enterprise Linux during boot process?

Environment Red Hat Enterprise Linux 6 Issue How to get list of all the files which are touched by Red Hat Enterprise Linux during boot process? Resolution To get such a list,  stap  script is required. There is an attachment with this Solution which is a zip file containing two programs,  bootinit.sh  and  bootprobe2.1.stp  file in  stapscripts.zip  file. Extract them and use as following. Make sure one has installed  kernel-devel  and  kernel-debuginfo  package of the currently booted kernel, otherwise it won't work at all. Follow  section 2.1.  in the SystemTap Beginners Guide for the  systemtap  and  kernel-debug  installation - Run the test at 2.1.3 to verify the install. 1.  Create  /tmp/stap  and  /tmp/stap/data Raw # mkdir -p /tmp/stap/data 2.  Place  bootprobe2.1.stp  and  bootinit.sh  into  /tmp/stap  and make  bootinit.sh  executable. Raw # chmod +x /tmp/stap/boot* 3.  Edit  bootinit.sh  and change  exec /sbin/init 3  to  exec /sbin/init

/sbin/init & rc.sysinit

The  /sbin/init  Program The  /sbin/init  program (also called  init ) coordinates the rest of the boot process and configures the environment for the user. When the  init  command starts, it becomes the parent or grandparent of all of the processes that start up automatically on the system. First, it runs the  /etc/rc.d/rc.sysinit  script, which sets the environment path, starts swap, checks the file systems, and executes all other steps required for system initialization. For example, most systems use a clock, so  rc.sysinit  reads the  /etc/sysconfig/clock  configuration file to initialize the hardware clock. Another example is if there are special serial port processes which must be initialized,  rc.sysinit  executes the  /etc/rc.serial  file. The  init  command then runs the  /etc/inittab  script, which describes how the system should be set up in each  SysV init runlevel . Runlevels are a state, or  mode , defined by the services listed in the SysV  /etc/rc.d/rc

Virtual IP Address (VIPA) & Determine Your Private and Public IP Addresses from the Command Line

A virtual IP address ( VIPA ) is an IP address assigned to multiple domain names or servers that share an IP address based on a single network interface card (NIC). VIPAs are allocated to virtual private servers, websites or any other application residing on a single server. The host server for these applications has a network IP address assigned by a network administrator, whereas the different server applications have VIPAs. VIPAs enhance network load balancing and redundancy. VIPAs are primarily implemented for the following reasons: To consolidate resources through the allocation of one network interface per hosted application To improve redundancy by providing alternative failover options on one machine A server IP address depends on the Media Access Control (MAC) address of the attached NIC, and only one logical IP address may be assigned per card. However, VIP addressing enables hosting for several different applications and virtual appliances on a server with only one

IP addressing and subnetting: What network administrators need to know

IP addressing and subnetting are an important part of networks. Learn about how IP addresses work, subnet masks, classful vs. classless IP addresses, default gateways and more. Most network administrators have learned about IP addressing and subnetting at one time or another. However, just  like a foreign language, if you don't use it, you will quickly forget it. In this article, I provide an overview of what network administrators need to know about IP addressing and subnetting. I believe this overview will be beneficial to the seasoned administrator who hasn't worked with IP in a while, as well as to novice network administrators who need to know what they should learn without having to spend a long time doing it. 1. What do you need to know about addresses? You probably know what an IP address is: a number that identifies that device on the network. But what else do you need to know? IP addresses are made up of 32 bits (IPv4 addresses, that is). We normally thin