For configuring linux I found that ifconfig did not work, found that on my centos environment (minimal setup) it was easy to simply

yum install net-tools

as long as the yum repos are setup properly you should be able to download this and install

top -c -H -b -d 60 -n 20 > top.txt



This should go into the Linux_common.ksh library file

# Create the tar file
tar -cvf /oracle/admin/scripts/mrc/apex_common_09062017.tar /oracle/admin/scripts/apex/*.ksh

tar --help


# Create archive.tar from files foo and bar.
tar -cf archive.tar foo bar

# List all files in archive.tar verbosely.
tar -tvf archive.tar

# Extract all files from archive.tar
tar -xf archive.tar

On Linux using -cvf will
c = create a tar
v = verbosely list the files
f = use archive file

The tar command allows creating a .tar file that can be gziped for easier transmit and smaller size

To pull a file from the archive you can use this

tar -xzf archive.tar.gz my/path/to/file.txt

To list the files in the archive
tar tzf archive.tar.gz

t = list
z = zipped
v = verbose (if you include this you will see the dates of the files)
f = file archive

tar does not support "in-place" updating of files. However, you can add files to the end of an archive, even if they have the same path as a file already in the archive. In that case, both copies of the file will be in the archive, and the file added later will override the earlier one. The command to use for this is tar r (or tar u to only add files that are newer than the archive) is the command to use. The . in the path should not be a problem.

There is a catch, though: you can't add to a compressed archive. So you would have to do:

Unzip the tar
gunzip archive.tar.gz

add to the tar file once it is unzipped
tar rf archive.tar data/data/com.myapp.backup/./files/settings.txt

rezip the tar file
gzip archive.tar

add to the mrc_10192017.tar file unzipped
tar -rvf mrc_10192017.tar /oracle/admin/scripts/mrc/nc1xtxsb03

scp <filename> oracle@<hostname>:/directory1/directory2 if necessary

ls -al |grep '^d' - shows just the directories, need to put this into the alias of commands

scp -r * oracle@mrctest:/oracle/admin/scripts - This will copy current folder and subdirectory under it


scp -rp * oracle@mrctest:/oracle/admin/scripts - This will copy current folder and subdirectory under it


Setting Shared Memory

Finding Large Directories

look for large files with this command:

find . -type f -size +100000k -exec ls -lh {} \; | awk ‘{ print $9 “: ” $5 }’

This looks for files over 100MB, but other than datafiles there were very few files found. I knew I needed to look for large directories. Directories that had a large amount of small files. This command worked nicely:

du -h / | grep ^[1-9][0-9][0-9.]*G | sort -rn

From there I was able to find the directories that I needed to clear out.

Find and zip files newer than X minutes

find . -mmin -1620 -type f -name \*_lm[d,s]\*trc -print -exec zip /tmp/`hostname` {} \;

This should be found in linux_common.ksh

Preinstall requirements:

Minimum RAM requirement: 1.5 GB for GRID Infrastructure and 2.5GB for GI plus RAC

you can verify easily by:

# grep memTotal /proc/meminfo

For Swap space checking

# grep SwapTotal /proc/meminfo

For disk temp space

# df -h /tmp

Ready for Action?

Ready to engage MRC Consulting
envelopephone linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram