If you want to change Port in the Apache configuration file it’s easy to do. You can also run a website on a different port rather than the default port. 1. Let’s check which is listening to which service: # nmap -sT -O localhost 2. Check whether Port 8000 is free or not: # lsof […]
CentOS/RHEL
How to move /tmp on a separate disk as a separate mount point (Online)
By default when you install any Linux system, the /tmp directory is created automatically under the root partition(‘/’). In some situations, you might want to separate out the /tmp directory on a different mount point or partition altogether. Especially when you want to manage it independently and have a large amount of data to be […]
How to use ldconfig Command in Linux
ldconfig command is used to tell the system about new locations of shared libraries. The uses information provided by the /etc/ld.so.conf configuration file. The ldconfig command creates a cache database of all libraries based on the configuration file. This cache is normally stored in the /etc/ld.so.cache file. Here is the syntax of the ldconfig command: […]
How to Troubleshoot Performance Issues on Linux – Beginners Guide
Following is the list of OS commands apart from basic commands output that are useful in diagnosing the problems at OS end causing the slow performance to the Database or application side. 1. iotop The iotop command is top like utility for disk I/O. It watches I/O usage information output by the Linux kernel (requires […]
How to use perf tool for tracing similar to dtrace
Basics Perf is useful profiling tool which might be useful to trace kernel/application calls/functions and many more. For example to start perf as a live monitor tool similar to top execute: # perf top It will display performance counters in real time. Example output: PerfTop: 474 irqs/sec kernel:100.0% exact: 0.0% [4000Hz cpu-clock], (all, 6 CPUs) […]
ldconfig Command Options
ldconfig command is used to tell the system about new locations of shared libraries, the ldconfig command uses information provided by the /etc/ld.so.conf file. The ldconfig command creates a cache database of all libraries based on the configura- tion file. This cache is normally stored in the /etc/ld.so.cache file. Here is the syntax of the […]
“cannot install the best update candidate for package” – error on running dnf update
The Problem Running the ‘dnf update’ command fails with below error: # dnf update Error: Problem 1: package perl-4:5.26.3-419.el8.x86_64 requires perl-interpreter(x86-64) = 4:5.26.3-419.el8, but none of the providers can be installed – cannot install both perl-interpreter-4:5.26.3-419.el8_4.1.x86_64 and perl-interpreter-4:5.26.3-419.el8.x86_64 – cannot install the best update candidate for package perl-interpreter-4:5.26.3-419.el8.x86_64 – cannot install the best update candidate […]
ldd Command Options in Linux
You can see what shared libraries a specific command uses by using the ldd command. Here is the syntax of the ldd command: # ldd [options] FILE For example: # ldd /bin/cp linux-vdso.so.1 => (0x00007ffc35df9000) libselinux.so.1 => /lib64/libselinux.so.1 (0x00007f93faa09000) libacl.so.1 => /lib64/libacl.so.1 (0x00007f93fa800000) libattr.so.1 => /lib64/libattr.so.1 (0x00007f93fa5fa000) libc.so.6 => /lib64/libc.so.6 (0x00007f93fa239000) libpcre.so.1 => /lib64/libpcre.so.1 (0x00007f93f9fd8000) […]
How To Configure sssd To Work With Multiple Active Directory Domains in Different Forests (CentOS/RHEL)
This post describes an approach to configuring sssd in order to interact with multiple Active Directory Domains located in different forests. This method involves altering /etc/krb5.conf and /etc/sssd/sssd.conf files. 1. Join the first domain (domain1.com) from the first forest. # realm join –verbose domain1.com -U LinuxAD@DOMAIN1.COM 2. Edit /etc/krb5.conf file and add the secondary domain […]
How to remove unwanted entries in /etc/shadow file
Question: How to remove all the unnecessary user entries in /etc/shadow file? 1. Create a backup copy of /etc/shadow file. # cp -p /etc/shadow /etc/shadow.backup 2. Ensure the user is not existing anymore in /etc/password file. # cat /etc/passwd | grep [userid] 3. Edit the /etc/shadow file, look for the line and remove the unnecessary […]