Long-time commandline user frustrated by limitations
Let me stick it out there right now: I'm a long-term FreeBSD/OpenSUSE/Solaris user that is in the process of moving a number of personal websites over to a CentOS machine with cPanel, and I am frustrated beyond belief at some of the limitations.
First of all: why can I not create names (both usernames and database names) with periods in them? I do that all the time under FreeBSD, and my ftp/ssh logins & MariaDB database names are all dot-based names; typically the domain name involved ( and name.domain.com, I can have two databases called
-
First time using a control panel in over a decade... My experience to date has been in the realm of hand-rolled servers, typically WinNT, FreeBSD, OpenSUSE and Solaris (now OpenIndiana). As such, I am used to a high degree of customization. Which is why I am getting frustrated out the wazoo with cPanel. Some fundamentals: I will be pretty well the only person accessing this VM. I will not be reselling space. I have replaced MySQL with MariaDB, mostly because I don"t like where MySQL is going, but also for the long name support (80 characters vs 16 for MySQL). Database prefixing has been turned off precisely because I am the only one to access this server. I have customized the install of CentOS as much as I could, spinning off nearly every partition that is typically in its own partition and then some. Which means not only is my /var/ in a separate partition, but also my /var/db/ (8GB) and my /var/www/ (20+GB). The /home/ partition is a measly 2GB because it will never actually host sites -- only be used for any easyapache rebuilds. The problems I have boil down to names -- in particular, the customizations to the cPanel templates that will allow me to expand allowable names from 16 characters to 80, and permit periods (.) within the names for both account names (as I will be naming it as the domain) as well as FTP and database names (they will be named after the domain, including whatever subdomain it caters to). With any normal, hand-rolled setup, I am able to create databases and web directories with both arbitrary lengths as well as (largely) arbitrary characters -- including periods. And I have never had an issue before. What I really need is a list of the template files and javascript files that I need to modify to allow both long names as well as embedded periods. I am hoping to have this solved in a very short period of time, rather than the many days it will take me to hunt down those things on my own. Please, any assistance would be greatly appreciated. 0 -
I'd put a ticket in. They may be able to give you the list of files you require, I fear however that you'll then find you may have problems with changes getting over written by updates, again, get the right support representative and they should be able to confirm whether you can put your changes back in with post update scripts. I guess you've probably already found it but database prefixing can be disabled per 0 -
Hello :) I'm happy to help answer some of these questions. I'm going to assume that you are using cPanel version 11.44. 1. Database prefixing is configurable under the "SQL" tab in "WHM Home " Server Configuration " Tweak Settings" with the following option: "Require a username prefix on names of new databases and database users" 2. Database names can only contain alphanumeric characters up to 64 characters long. The following blog post might also contain some useful information: [url=http://blog.cpanel.net/update-to-recent-database-prefixing-post/]Update to Recent Database Prefixing Post | cPanel Blog It's important to keep in mind that MariaDB is not supported, despite the fact that many users are able to successfully implement it. cPanel/WHM is not developed with the use of MariaDB in mind. We have an open feature request for it at: [url=http://features.cpanel.net/responses/as-a-server-administrator-i-want-mariadb-support-so-that-i-can-accomodate-both-innodb-and-noninnodb-users]MariaDB support | cPanel Feature Requests The comments section will often include information from employees on the status of the feature request. Thank you. 0 -
I have given up on database and user names with periods. However, I am still very adamant about being able to create account names that are more than 16 characters long. All I am asking for are the names/locations of the JavaScript and HTML files that contain the restrictions" I can do everything from there. 0 -
It's not a configurable limitation. You are welcome to submit a feature request if you would like to see support for cPanel usernames longer than 16-characters: Submit A Feature Request Thank you. 0 -
I never asked if it is configurable. If need be, I will dive into the PHP and Javascript files to make modifications directly. All I am asking for are the names and locations of those files on the file system. As a web developer, I can do the rest. 0 -
There are no JavaScript or HTML files that control this limit. It's hard-coded in the sense that there is no way to circumvent the limit by editing a file. Thank you. 0 -
I have been a web developer and a programmer for nearly two decades now, and if there is one thing that sets off my bullshit detector faster than anything else is someone saying that it can"t be done because it"s "hard-coded". The only way to do that is to limit the underlying technologies that underpin websites (operating system & database limitations), and I have just fixed the one and only thing that could be limiting name lengths in this manner (by replacing MySQL with MariaDB, which provides name lengths of up to 80 characters). The only other places that names can be restricted to 16 characters is in the HTML (field length attribute), Javascript (input sanitization), SQL statements (data truncation and/or rejection) or PHP (input sanitization and data handling), all of which can be edited. Now, if it is company policy to not provide that information, I can understand that. But please don"t waste both our times by beating around the bush. Just come out and say that. Don"t try to blow smoke up my arse, and I won"t call you out on it. 0 -
Hi, We have hard coded the max_length of usernames in the system. You should be able to bypass this by editing /usr/local/cpanel/Cpanel/Validate/Username.pm (MAX_LENGTH). Note: By doing this, you may inadvertently cause problems with being able to adjust these accounts inside cPanel. If there are problems with it, we wouldn't be able to support the system. 0 -
Thank you very much for that information, however even after clearing the web browser"s cache (and even using a completely different web browser) nothing gets changed on the client end (the interface provided to the client) as I am still seeing 16 character limitation in the form field"s maxlength attribute and in the JS validation. Even after modifying the HTML in the client and selectively disabling the JS validation, the server-side processing still rejects anything over 16 characters as an invalid name. Perhaps there is a caching feature within cPanel (the Magic Revision cache) that needs refreshing? Keep in mind, I"m only on my third or fourth full day using this product; I am unaware of any tool that will refresh Magic_Revision so I suspect that I am still being served cached pages created prior to my edit. I just haven"t had the time needed to truly dissect the product, so I"m not sure. 0 -
Also, keep in mind that I am looking only to create account names that are longer than 16 characters. I have already discovered workarounds to all other situations within cPanel where a longer name would normally be rejected (DB user names, for example), so as soon as I create the long account names that I require I will be resetting this MAX_LENGTH value back to the default of 16 characters. I just need to set up a half-dozen (or so) domain names and then drop the limit back down to 16. I have given up on asking for dot notation in names because, although I have become accustomed to escaping db & table names with backticks in my SQL, cPanel might introduce situations and third-party code where this is not the case, and a dot-notated DB name might indeed become an issue. Plus, there is that issue with system logs when the path to a website contains a dot; something I had also dealt with in the past but which cPanel might not be designed to handle. So please consider my prior requests as no longer being active; I am now looking only for long account names upon account creation. 0 -
"The name of another account on this server has the same initial 8 characters as the given username ("domannamenet"). Each username"s first 8 characters must be unique." Um" seriously?? Even if db prefixing has been turned off by an advanced user, such as I? I mean, I know you have to put up barriers for casual users to avoid issues, but isn"t there a hidden "advanced mode" for cPanel than can dispense of the diapers and swaddling cloths?? I"ve been a sysadmin for the last decade and a bit, and I"m just looking for something simpler to handle a web server with; I"m not actually looking to neuter some of the more advanced features that I have become used to using. For the record, I have long domain names where the only difference between account names will be the TLD at the end. So domannamenet, domainnamecom, domannameorg and so forth. How can I disable this 8-character uniqueness requirement, especially since I have disabled db prefixing to begin with? 0 -
I still haven"t seen any sort of a response to my inquiries. To wit, " I have altered the permissible length of account names in the template file from 16 to 32, but I need to have that translate out to (at the very least) the JavaScript input validators (and the form field"s maxlength attribute, although I can get around that). Disabling JavaScript in the browser (or even blocking the validation script) prevents the form from successfully submitting, and the JavaScript files I have found on the server are not the ones being served up to the web browser (I have edited them as well but they are not provided to the end user). To properly employ long account names, I suspect that on-server caching called MagicRevision needs to be refreshed or turned off. " I have turned off database prefixing, so I need to have 8-character uniqueness turned off in the account names. I know that account names need to be unique, but I need to turn off the restriction that the first 8 characters of a file name need to be unique. This can be extended to at least 16 characters (at minimum, if it cannot be turned off) but I need that restriction eased. I am a paying customer, and an advanced Unix/Linux user. I do not need to be handled with diapers and swaddling cloths. I just want to be able to ease up two of the most onerous restrictions I have run up against. If this is information that cPanel does not desire to be public knowledge, we can take this to PM for privacy. I am also willing to sign an NDA to ensure cooperation. 0 -
I've moved this thread to our Developer's forum where you may receive more feedback on this topic. Note that you may want to open a support ticket using the link in my signature for additional assistance. Thank you. 0
Please sign in to leave a comment.
Comments
14 comments