• Skip to main content

Uly.me

cloud engineer

  • Home
  • About
  • Archives

centos

Check Reboot After Updates

July 16, 2021

Here’s the command to check if the system needs a reboot after running yum update.

Must be root or run it sudo.

$ needs-restarting -r ; echo $?
Core libraries or services have been updated:
  openssl-libs -> 1:1.0.2k-21.el7_9
  kernel -> 3.10.0-1160.31.1.el7
  dbus -> 1:1.10.24-15.el7
  linux-firmware -> 20200421-80.git78c0348.el7_9
  glibc -> 2.17-324.el7_9
  systemd -> 219-78.el7_9.3
 
Reboot is required to ensure that your system benefits from these updates.
 
More information:
https://access.redhat.com/solutions/27943
1

$ needs-restarting -r ; echo $? Core libraries or services have been updated: openssl-libs -> 1:1.0.2k-21.el7_9 kernel -> 3.10.0-1160.31.1.el7 dbus -> 1:1.10.24-15.el7 linux-firmware -> 20200421-80.git78c0348.el7_9 glibc -> 2.17-324.el7_9 systemd -> 219-78.el7_9.3 Reboot is required to ensure that your system benefits from these updates. More information: https://access.redhat.com/solutions/27943 1

In this instance, it requires a reboot due to a new kernel.

Filed Under: Linux Tagged With: centos, check, reboot, redhat, update

Install OpenJDK 8

January 31, 2021

Here’s the installation instructions for OpenJDK 8.

For Fedora, Redhat and Oracle Linux.

yum install java-1.8.0-openjdk

yum install java-1.8.0-openjdk

For Debian and Ubuntu.

apt-get install openjdk-8-jre

apt-get install openjdk-8-jre

To see if the packages (symbolic links) are there, they can be found in /etc/alternatives/, at least in Redhat 7.

ls -l /etc/alternatives/

ls -l /etc/alternatives/

Filed Under: Misc Tagged With: 1.8.0, centos, java, jdk, jre, redhat, ubuntu

HTTPD on Redhat & Centos

December 4, 2020

Here are the commands to start, stop, enable and get the status of Apache on RHEL and CentOS.

systemctl enable httpd  # enable on bootup
systemctl status httpd  # get status
systemctl start httpd   # start
systemctl stop httpd    # stop
systemctl restart httpd # restart

systemctl enable httpd # enable on bootup systemctl status httpd # get status systemctl start httpd # start systemctl stop httpd # stop systemctl restart httpd # restart

Filed Under: Linux Tagged With: centos, enable, redhat, start, status, stop

OpenSSL Upgrade

October 19, 2020

Here’s how to upgrade to OpenSSL 1.1 on Redhat/Centos.

# check
openssl version
yum info openssl
# download and install
cd /usr/local/src
wget https://www.openssl.org/source/openssl-1.0.2-latest.tar.gz
tar -zxf openssl-1.0.2-latest.tar.gz
# compile
cd openssl-1.0.2a
./config
make
make test
make install
# update softlink
mv /usr/bin/openssl /root/
ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl
# verify new version
openssl version

# check openssl version yum info openssl # download and install cd /usr/local/src wget https://www.openssl.org/source/openssl-1.0.2-latest.tar.gz tar -zxf openssl-1.0.2-latest.tar.gz # compile cd openssl-1.0.2a ./config make make test make install # update softlink mv /usr/bin/openssl /root/ ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl # verify new version openssl version

Filed Under: Linux Tagged With: centos, openssl, redhat, upgrade

Apache & Webroot

July 5, 2019

Where’s Apache and webroot for the different distros?

Webroot:

# Redhat, Fedora, Centos, Amazon Linux
/var/www/html
# Debian, Ubuntu, Mint
/var/www/html

# Redhat, Fedora, Centos, Amazon Linux /var/www/html # Debian, Ubuntu, Mint /var/www/html

Apache Configuration:

# Redhat, Fedora, Centos, Amazon Linux
/etc/httpd/conf/httpd.conf
# Debian, Ubuntu, Mint
/etc/apache2/sites-available/default

# Redhat, Fedora, Centos, Amazon Linux /etc/httpd/conf/httpd.conf # Debian, Ubuntu, Mint /etc/apache2/sites-available/default

Filed Under: Linux Tagged With: apache, centos, debian, fedora, mint, redhat, ubuntu, webroot

  • Home
  • About
  • Archives

Copyright © 2023