Sometimes it’s necessary to log all the sudo commands run in your environment. Let”s see how to achieve this. Edit the sudoers file by running visudo visudo Add the below line to the Defaults section Defaults logfile=/var/log/sudo Now all the commands from a sudo user will be logged in /var/log/sudo file. [root@awsadminz ~]# cat /var/log/sudo Jan 11 ...
Today apache was stuck with the below error and it was not starting at all. Sep 15 06:18:24 server.example.com systemd[1]: Starting The Apache HTTP Server... Sep 15 06:18:24 server.example.com httpd[15037]: [Thu Sep 15 06:18:24.591424 2016] [so:warn] [pid 15037] AH01574: module ruid2_module is alread...skipping Sep 15 06:18:33 server.example.com systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE Sep 15 06:18:33 ...
Issue You are trying to install vmware-tools on RHEL / CentOS 7 You are stuck with the below error. The path "" is not a valid path to the 3.10.0-327.el7.x86_64 kernel headers. Solution You have to install the below two packages, kernel-headers and kernel-devel You can run the below command to install those via yum. ...
Issue You are note able to restart / start postfix and getting the below error. fatal: parameter inet_interfaces: no local interface found for ::1 Solution Edit the file /etc/postfix/main.cf vim /etc/postfix/main.cf search for the line inet_interfaces = all And change it to: inet_interfaces = 127.0.0.1, 10.10.11.12 10.10.11.12 is your local IP address :wq! Save and ...
Issue how to set hostname persistent across reboots in CentOS 7 / RHEL 7 on AWS ec2 CentOS 7 / RHEL 7 Hostname changes after reboots in aws ec2 Solution Set the hostname with the below command hostnamectl set-hostname hostname.yourdomainname.com Now run the below to change the cloud.cfg echo "preserve_hostname: true" >> /etc/cloud/cloud.cfg Reboot the ...
Issue How to change the boot order in RHEL 7 / CentOS 7 / OEL 7 How to set default boot to windows on Dual boot on the above environments. Solution In boot menu, the number starts with 0, so the 3rd selection will have the number 2. so to set the 3rd kernel in ...
We often need to add or modify a disk to a running server. In this article, we will see how you can Add new LUN or Disk, or Resize the LUN or Disk on a Linux without a reboot Scenario 1 – Add a new Disk or LUN You have added a new disk / ...