:_mod-docs-content-type: PROCEDURE
[id="decommissioning-RHOSP-standalone-Ceph-NFS-service_{context}"]

= Decommissioning the {rhos_prev_long} standalone Ceph NFS service

[role="_abstract"]
If your deployment uses CephFS through NFS, you must decommission the {rhos_prev_long}({OpenStackShort}) standalone NFS service. Since future software upgrades do not support the previous NFS service, ensure that the decommissioning period is short.

.Prerequisites

* You identified the new export locations for your existing shares by querying the Shared File Systems API.
* You unmounted and remounted the shared file systems on each client to stop using the previous NFS server.
* If you are consuming the {rhos_component_storage_file} shares with the {rhos_component_storage_file} CSI plugin for {rhocp_long}, you migrated the shares by scaling down the application pods and scaling them back up.

[NOTE]
Clients that are creating new workloads cannot use share exports through the previous NFS service. The {rhos_component_storage_file} no longer communicates with the previous NFS service, and cannot apply or alter export rules on the previous NFS service.

.Procedure

. Remove the `cephfs_ganesha_server_ip` option from the `manila-share` service configuration:
+
[NOTE]
This restarts the `manila-share` process and removes the export locations that applied to the previous NFS service from all the shares.
+
----
$ cat << __EOF__ > ~/manila.patch
spec:
  manila:
    enabled: true
    apiOverride:
      route: {}
    template:
      manilaShares:
        cephfs:
          replicas: 1
          customServiceConfig: |
            [DEFAULT]
            enabled_share_backends = cephfs
            host = hostgroup
            [cephfs]
            driver_handles_share_servers=False
            share_backend_name=cephfs
            share_driver=manila.share.drivers.cephfs.driver.CephFSDriver
            cephfs_conf_path=/etc/ceph/ceph.conf
            cephfs_auth_id=openstack
            cephfs_cluster_name=ceph
            cephfs_protocol_helper_type=NFS
            cephfs_nfs_cluster_id=cephfs
          networkAttachments:
              - storage
__EOF__

----

. Patch the `OpenStackControlPlane` custom resource:
+
----
$ oc patch openstackcontrolplane openstack --type=merge --patch-file=~/<manila.patch>
----
* Replace `<manila.patch>` with the name of your patch file.

. Clean up the standalone `ceph-nfs` service from the {OpenStackShort} control plane nodes by disabling and deleting the Pacemaker resources associated with the service:
+
[IMPORTANT]
You can defer this step until after {rhos_acro} {rhos_curr_ver} is operational. During this time, you cannot decommission the Controller nodes.
+
----
$ sudo pcs resource disable ceph-nfs
$ sudo pcs resource disable ip-<VIP>
$ sudo pcs resource unmanage ceph-nfs
$ sudo pcs resource unmanage ip-<VIP>
----
+
* Replace `<VIP>` with the IP address assigned to the `ceph-nfs` service in your environment.
