Description of problem: Cannot edit configuration files using the web UI when is bigger then 32KB but we are able to upload files bigger then 32KB. Version-Release number of selected component (if applicable): Satellite 5.3 How reproducible: 100% Steps to Reproduce: Even changing the configuration, we still just able to edit using the WEB UI files smaller then 32Kb. The changes were made in the files below: # /etc/rhn/rhn.conf # 2MB web.maximum_config_file_size=2097152 # Limit the size of POST data (in bytes) # 2MB web.post_max = 2097152 # maximum size for a config file # 2MB web.maximum_config_file_size = 2097152 After restarting the Satellite Server (rhn-satellite restart), the problems remains. Actual results: Cannot edit configuration files using the web UI when file is bigger then 32KB. Expected results: Edit file using web UI when bigger then 32KB. Additional info: Looking into the code, we can observe some interesting points below: a) FileDetailsAction.java: /code/src/com/redhat/rhn/frontend/action/configuration/files/FileDetailsAction.java <snip> public class FileDetailsAction extends RhnAction { 46 47 // REQUEST elements <snip> 52 public static final String MAX_SIZE = "maxbytes"; 53 public static final String MAX_EDIT_SIZE = "maxEditBytes"; 54 public static final String LAST_USER = "lastUser"; 55 public static final String LAST_USER_ID = "lastUserId"; 56 public static final String TOOLARGE = "toolarge"; <snip> protected void setupRequestParams(RequestContext ctx, ConfigRevision cr) { <snip> 112 request.setAttribute(MAX_SIZE, 113 StringUtil.displayFileSize( 114 Config.get().getInt(ConfigDefaults.CONFIG_REVISION_MAX_SIZE, 115 ConfigDefaults.DEFAULT_CONFIG_REVISION_MAX_SIZE))); 116 request.setAttribute(MAX_EDIT_SIZE, 117 StringUtil.displayFileSize(ConfigFileForm.MAX_EDITABLE_SIZE)); ^^^^^^^ ---> here we can see the method requesting an attribute MAX_EDITABLE_SIZE from the class ConfigFileForm. b) ConfigFileForm.java: ./code/src/com/redhat/rhn/frontend/action/configuration/ConfigFileForm.java public class ConfigFileForm extends ScrubbingDynaActionForm { 51 52 /** 53 * Comment for <code>serialVersionUID</code> 54 */ 55 private static final long serialVersionUID = -2162768922109257186L; 56 // configFileForm elements <snip> 81 // Here to deal with form-size-limits 82 public static final long MAX_EDITABLE_SIZE = (32L * 1024L); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ---> here we can see the attribute MAX_EDITABLE_SIZE being hardcoded set to 32KB :) Meanwhile, the workaround is download the file locally, edit it, then upload again. That procedure works normally.
Hi Marcelo, closing this as NOTABUG - see bug 433378 and bug 470911 for background info. Basically the maximum edit size for configuration files is set to 32 KB due to form size limitations. For anything larger, edit it and upload it (as you noted in Description). Thanks.