• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

Archives for May 2017

CentOS / RHEL : How to configure iptable rules to allow FTP ports 20/21

by admin

The iptables utility controls the network packet filtering code in the Linux kernel. The iptables feature is used to set up, maintain, and inspect the tables of IP packet filter rules in the Linux kernel. Several different tables may be defined. Each table contains a number of built-in chains and may also contain user-defined chains. […]

Filed Under: Linux

Basic vi commands (cheat sheet)

by admin

vi is one of the most commonly used editor program and included by default with every UNIX and linux system. vi basically operates in 3 modes, namely : vi mode – the mode vi starts in command mode – you can be in command mode from the vi mode by pressing the key colon (“:”) […]

Filed Under: Linux

Change default kernel (boot with old kernel) in CentOS/RHEL/OEL 5 and 6

by admin

The following post shows the procedure to boot CentOS/RHEL/OEL 5 and 6 systems into different kernel installed. CentOS/RHEL/OEL 5 and 6 operating system uses GRUB as the default boot loader. When you install a kernel using either rpm, up2date or yum application, the kernel package creates an entry in the boot loader configuration file for […]

Filed Under: CentOS/RHEL 5, CentOS/RHEL 6, Linux, OEL 6

CentOS / RHEL 7 : How to boot into emergency or multi-user mode from GRUB2

by admin

Prior to RHEL 7, runlevels were used to identify a set of services that would start or stop when that runlevel was requested. Instead of runlevels, systemd uses the concept of targets to group together sets of services that are started or stopped. A target can also include other targets (for example, the multi-user target […]

Filed Under: CentOS/RHEL 7

CentOS / RHEL 7 : How to add a kernel parameter only to a specific kernel

by admin

When we add a parameter to /etc/sysconfig/grub and run grub2-mkconfig -o /boot/grub2/grub.cfg, the parameter will be added to all of the kernel entries. This is the default behaviour of a RHEL 7 system. How can we add kernel parameter to a specific kernel version when there are more than one kernel in the system in […]

Filed Under: CentOS/RHEL 7

What’s the difference between locate and find command in Linux

by admin

Two popular commands for locating files on Linux are find and locate. Depending on the size of your file system and the depth of your search, the find command can sometime take a long time to scan all of the data. For example, if you search your entire filesystem for the files named data.txt: # […]

Filed Under: Linux

Change default kernel (boot with old kernel) – CentOS/RHEL/OEL 7

by admin

Question: How to modify the GRUB2 default entry to boot a different Kernel version? 1. Check the current running Kernel Version # uname -a Linux geeklab 3.8.13-94.el7uek.x86_64 #2 SMP Wed Feb 11 14:18:22 PST 2015 x86_64 x86_64 x86_64 GNU/Linux 2. List the Kernel Entries as per GRUB2 file: # awk -F\’ ‘$1==”menuentry ” {print $2}’ […]

Filed Under: CentOS/RHEL 7, Linux, OEL 7

How to use sudo to allow a non-root user run a particular command

by admin

With the help of sudo, you can give access to a non-root user to run a root only command. Here is a short howto to provide the non-root user the access to a root only command. The command access that we will give to a user named “john” will be “/sbin/poweroff”. Giving sudo access to […]

Filed Under: Linux

CentOS / RHEL 7 : How to rename the volume group for root and swap

by admin

The requirement Here’s the current setup – The root and swap volume reside on the volume group named vg_os. # vgs VG #PV #LV #SN Attr VSize VFree vg_os 1 2 0 wz–n- 557.88g 1.88g # lvs vg_os LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert lv_root vg_os -wi-ao—- 300.00g lv_swap […]

Filed Under: CentOS/RHEL 7

CentOS / RHEL 6,7 : How to use yum history to roll back a yum update

by admin

Note : Rollback of selinux, selinux-policy-*, kernel, glibc (dependencies of glibc such as gcc) packages to older version is not supported. Thus, downgrading a system to minor version (ex: RHEL6.6 to RHEL6.5) is not recommended as this might leave the system in undesired state. Use the yum history option for small update rollbacks. How yum […]

Filed Under: CentOS/RHEL 7, Linux

Next Page »

Primary Sidebar

Recent Posts

  • ncat Command Examples in Linux
  • ncat: command not found
  • nautilus Command Examples in Linux
  • namei: command not found

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright