1. Bicom Systems
  2. Solution home
  3. SERVERware
  4. HOWTOs SERVERware 5

HOWTO:: Patching the system

When it comes to applying a patch, the procedure is straightforward. After downloading the patch and checking which directories and files it contains, you need to determine where exactly to apply the patch on the PBXware system. For example, let's consider applying a patch to the `admin` directory in the `sitemanager`.


In our case, the path to the `sitemanager` is located at `/opt/pbxware/pw/home/sitemanager`.


1. Navigate to the directory by running:  

   `cd /opt/pbxware/pw/home/sitemanager`


2. The next step is to type the command:  

   `ls -lah`  

   With this we are checking whether there are already any backups of the directory, which we will also back up.


3. If there are existing backups, create a new backup with a unique name to avoid conflicts by executing:  

   `cp -a admin admin.backup` (example).


4. To confirm that the backup has been created, run:  

   `ls -lah`.


5. After confirming the backup, the next step is to download the patch onto the system where it will be applied.


6. Return to the root directory and create a new folder to store the patch. For example:  

   `mkdir testsitemanager`  

   Navigate into the newly created folder with:  

   `cd testsitemanager`.


7. Once in the directory, download the patch using the command:  

   `wget $linktopatch`.


8. After downloading the patch, extract it with the command:  

   `tar -xvzf sitemanager.tar.gz`.


9. Finally, copy the `admin` directory to the appropriate path using the command:  

   `cp -r admin /opt/pbxware/pw/home/sitemanager`.


With this, the patch has been applied. You now need to test it to ensure everything is functioning correctly.  


Note: In some cases, you may need to reload or restart the system for the patch to take effect.  


Additional Note: If dealing with hosted systems, it is recommended to create a full backup before starting this procedure.