\section{System Configuration Files in /etc}

\begin{frame}
   {Configuration Files in /etc}
   \begin{itemize}
      \item
      \textbf{Linux} distributions cooperate to place
      certain kinds of files in standard places
      \item
      System-wide configuration files are generally placed
      in \filelink{/etc} subdirectories
      \item User-specific ones are in individual home
      directories
      \item
      All \textbf{Red Hat}-derived systems make extensive
      use of \filelink{/etc/sysconfig}

      \item
      All \textbf{Debian}-based systems use
      \filelink{/etc/default}
      \item
      \textbf{RHEL} and \textbf{SUSE} use both
   \end{itemize}

\end{frame}

\cprotect\note{

   The general rule about saving configuration information is:
   \begin{itemize}
      \item
      System wide files go in \filelink{/etc}.
      \item
      User-specific files go in \filelink{/home/[username]}.
   \end{itemize}

   This is not completely true; for example, default configuration information
   might be stored in \filelink{/usr/lib/systemd}, but can be overridden by
   files in \filelink{/etc/systemd}.

   There should be only text files found under \filelink{/etc/}, no binary formats
   or data.

}

\begin{frame}
   {/etc/sysconfig}

   \begin{itemize}

      \item Files in this directory and its subdirectories
      are used by many system utilities service
      \item They are often consulted or invoked when the system
      starts and stops services or queries their status.
      \item
      For example, on one particular \textbf{RHEL} system:
   \end{itemize}
   \begin{figure}[H]
      \includegraphics[width=5.8in]{IMAGES/etcselinux}
      \caption{ Configuration Example: /etc/sysconfig/selinux}
   \end{figure}

\end{frame}

\cprotect\note{

   On a \textbf{RHEL} system:

   \begin{figure}[H]
      \includegraphics[width=6.50in]{IMAGES/etcsysconfig}
      \caption{/etc/sysconfig on RHEL 8}
   \end{figure}

}


\begin{frame}
   {/etc/default}

   \begin{itemize}

      \item
      Use is similar to that of \textbf{Red Hat}'s
      \filelink{/etc/sysconfig}
      \item Files provide extra options when starting a
      service.
      \item Contain code to set environment
      variables.
      \item
      For example, \filelink{/etc/default/useradd} sets
      defaults used when creating new user accounts.
      \item
      All significant \textbf{Linux} distributions,
      including \textbf{Red Hat}-based ones, now have
      \filelink{/etc/default}, even if they still have
      \filelink{/etc/sysconfig}.
   \end{itemize}

\end{frame}

\cprotect\note{

   On an \textbf{Ubuntu} system:
   \begin{figure}[H]
      \includegraphics[width=5.8in]{IMAGES/ubuntuetcdefault}
      \caption{/etc/default}
   \end{figure}

}


