Skip to content

Commit

Permalink
Labs: use "exportfs -r" instead of restarting the NFS server
Browse files Browse the repository at this point in the history
Restarting the NFS server is a rather ugly thing to
do in an environment with multiple users (imagine a central
NFS server).

We just need to ask the server to update the directories
it exports, not to stop and restart.

Signed-off-by: Michael Opdenacker <michael.opdenacker@bootlin.com>
  • Loading branch information
michaelopdenacker committed Dec 2, 2021
1 parent c52bdbd commit 9a4fa7e
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
Expand Up @@ -135,7 +135,7 @@ \section{Setting up the NFS server}
Then, restart the NFS server:
\begin{verbatim}
sudo /etc/init.d/nfs-kernel-server restart
sudo exportfs -r
\end{verbatim}
If there is any error message, this usually means that there was a
Expand Down
Expand Up @@ -49,8 +49,8 @@ \section{Debugging setup}
and extract the \code{buildroot-2021.08.<n>/output/images/rootfs.tar}
archive in the \code{nfsroot} directory.
Add this directory to the \code{/etc/exports} file and restart
\code{nfs-kernel-server}.
Add this directory to the \code{/etc/exports} file and run
\code{sudo exportfs -r}.
Boot your ARM board over NFS on this new filesystem, using the same
kernel as before.
Expand Down
4 changes: 2 additions & 2 deletions labs/sysdev-tinysystem/sysdev-tinysystem.tex
Expand Up @@ -68,9 +68,9 @@ \section{Setting up the NFS server}
options, otherwise default options will be used for this IP address,
causing your root filesystem to be read-only.
Then, restart the NFS server:
Then, make the NFS server the new configuration:
\bashcmd{$ sudo service nfs-kernel-server restart}
\bashcmd{$ sudo exportfs -r}
\section{Booting the system}
Expand Down
Expand Up @@ -72,9 +72,9 @@ \section{Set up the NFS server on the workstation}
\code{/nfs *(rw,sync,no_root_squash,subtree_check)} to the
\code{/etc/exports} file.

Finally restart the service:
Finally, make the NFS server use the new configuration:
\begin{verbatim}
sudo service nfs-kernel-server restart
sudo exportfs -r
\end{verbatim}

\section{Add a package to the rootfs image}
Expand Down
Expand Up @@ -63,9 +63,9 @@ \section{Set up the NFS server on the workstation}
\code{/nfs *(rw,sync,no_root_squash,subtree_check)} to the
\code{/etc/exports} file.

Finally restart the service:
Finally update the NFS server:
\begin{verbatim}
sudo service nfs-kernel-server restart
sudo exportfs -r
\end{verbatim}

\section{Add a package to the rootfs image}
Expand Down
Expand Up @@ -177,8 +177,8 @@ \subsection{Principle and solutions}
\item \code{rw,no_root_squash,no_subtree_check} are the NFS server
options for this directory export.
\end{itemize}
\item Start or restart your NFS server (example: Debian, Ubuntu)\\
\code{sudo /etc/init.d/nfs-kernel-server restart}
\item Ask your NFS server to reload this file:\\
\code{sudo exportfs -r}
\end{itemize}
\end{frame}
Expand Down

0 comments on commit 9a4fa7e

Please sign in to comment.