Exclude Functionality for cpanelsync

For cPanel & WHM 11.38

If you do not want specific files to update, we recommend that you do not set cPanel-distributed files to immutable. This action will cause a variety of problems. Instead, enter the paths for those files in the /etc/cpanelsync.exclude file.

Each entry in the /etc/cpanelsync.exclude file must use a fully specified path, with each path on its own line. For example, if you wish to prevent an update to the following files:

  • /usr/local/cpanel/usr/local/cpanel/scripts/pkgacct
  • /usr/local/cpanel/Cpanel/Logd.pm

then add the files' paths to the /etc/cpanelsync.exclude file through the following 2 commands:

  • echo "/usr/local/cpanel/usr/local/cpanel/scripts/pkgacct" >> /etc/cpanelsync.exclude
  • echo "/usr/local/cpanel/Cpanel/Logd.pm" >> /etc/cpanelsync.exclude

PICK Remember: This method only prevents an update from the cpanelsync utility. This method does not prevent updates that occur at application runtime. You cannot use cpanelsync.exclude to prevent modifications to configuration files, datastores, or similar types of files.

note Note: You cannot block updates to RPM-managed files within /etc/cpanelsync.exclude and /etc/cpanelsync.no_chmod To determine whether a file is managed by an RPM, run the following command: rpm -qf /path/to/file

If you wish to edit a cPanel-provided RPM, review our document on how to customize and override the rpm.versions system.

Topic revision: r10 - 15 May 2013 - 19:54:43 - Main.RosieArcelay