.. Reminder for header structure:        
  Parts (H1)          : #################### with overline
  Chapters (H2)       : ******************** with overline
  Sections (H3)       : ====================
  Subsections (H4)    : --------------------
  Subsubsections (H5) : ^^^^^^^^^^^^^^^^^^^^
  Paragraphs (H6)     : """""""""""""""""""""

.. |date| date::

.. meta::
  :description: Handling common errors with the Samba file serve
  :keywords: File Server, common errors, Samba, documentation

.. _samba_fileserver_common_errors:

#################################################
Handling common errors with the Samba file server
#################################################

*******************
convert ISO to utf8
*******************

* Stop the samba service:

  .. code-block:: bash

    systemctl stop smb

* Install the module :program:`convmv`:

  .. code-block:: bash

    # RedHat8 and derived distributions
    yum install convmv
    # Debian
    apt-get install convmv

* In a command prompt, run the conversion command on the shared directory. Here in our example, the root directory is named :file:`data`:

  .. code-block:: bash

    convmv --notest -f iso-8859-15 -t utf8 -r /data

* Then in :file:`/etc/smb.conf`, delete or comment the line *dos charset*:

* Finally, restart Samba:

  .. code-block:: bash

    systemctl restart smb
    systemctl restart winbind
    systemctl restart nmb #<== Necessary if NetBIOS is enabled.
