Results 1 to 8 of 8

Thread: FTP usernames without @mysite.com on the end?

  1. #1
    Member
    Join Date
    Feb 2004
    Posts
    14

    Default FTP usernames without @mysite.com on the end?

    I want to give FTP access to certain users to specific folders on my server to upload music.

    The users are not technically minded I'm providing links for them so they can FTP drag-and- drop style with IE.

    The name of my website is quite long. Certain versions of Internet Explorer (it seems) or possibly Windows won't allow a username greater than 31 characters:

    someuser@myverylongwebsitename.com

    This is a real pain.

    Besides root I have another username for FTP (I didn't set this up - it was set up for me when I arrived on the server) and I can enter that without the myverylongwebsite.com extention and all works fine.

    In cPanel I try to create a username without the @myverylongwebsite.com but it won't work.
    Can anyone suggest a solution? Can I create usernames in UNIX or in some file on the server instead?

  2. #2
    Member
    Join Date
    Feb 2004
    Posts
    14

    Default

    I found kind of a solution.

    You can just edit the passwd.vhosts file and delete the extra part of the user name.

    Does anyone know if you can stop the FTP manager in cPanel adding the extra bit?
    I'll be adding users regularly so this will be a pain in the ass.

  3. #3
    cPanel Partner NOC cPanel Partner NOC Badge
    Join Date
    Oct 2003
    Posts
    2,003

    Default

    I found kind of a solution.
    thats not kind a solution that is the solution

    thats the only why I have found that plays nice with IE with the @domainname.com

    but watchout cpanel will ovewrite

  4. #4
    Registered User
    Join Date
    Feb 2005
    Posts
    3

    Default

    and what about the email login name. I realy don't like it everytime i have to type the complets mailaddress like you+mail.com Is there a way to login on f.e. Squirrelmail and he'll still recognizes it as a "+mail.com" username?

  5. #5
    cPanel Partner NOC cPanel Partner NOC Badge
    Join Date
    Oct 2003
    Posts
    2,003

    Default

    this was a question about FTP not mail


    thats how cpanel keeps track of users otherwise you would confilcict with email users with the same username

  6. #6
    Member
    Join Date
    Feb 2004
    Posts
    14

    Default

    Quote Originally Posted by dalem
    but watchout cpanel will overwrite
    yes, it does which is a nightmare. I hadn't anticipated that.

    Everytime I add a new ftp user I have to edit the file and delete all the @mydomain extensions it adds to each FTP username. As I add more users it I have mroe work to do.

    I have a few usernames (like root) that don't have the @mydomain extension but they were all created before cPanel was installed. How come cPanel doesn't add the extensions to those usernames also? They must be contained somewhere besides the passwd.vhosts file?
    Can I add FTP users at the shell maybe?

    Perhaps I'll write a unix script that removes the @mydomain.com part from the file but its messy...
    Last edited by cronjob78; 03-14-2005 at 09:19 AM.

  7. #7
    Member
    Join Date
    Feb 2004
    Posts
    14

    Default

    This is my basic solution for a 2 line unix script which removes the instance of the domain name from the passwd.vhosts file.



    cp /etc/proftpd/passwd.vhosts /etc/proftpd/tempfile1

    (copies the file to a temporary file so you'll have a copy of the original)

    sed -e 's/@mylongdomainname.com//g' /etc/proftpd/tempfile1 > /etc/proftpd/passwd.vhosts

    (replaces all instances of @mylongdomainname.com in tempfile1 with nothing and puts the result back into passwd.vhosts). Note that tempfile1 will not be changed but the one you want will!

    Stuck it on as a cronjob and seems to be working ok. I run the script every time I use ftp manager in cpanel.

    hope this helps somebody somewhere in the future. Its wrecked me head for too long.

  8. #8
    kdr
    kdr is offline
    Registered User
    Join Date
    Aug 2002
    Posts
    4

    Default

    Hi,

    I have an application that requires the ability to use the plain usernames for ftp. I have this working on another domain and couldn't figure out why I couldn't do this on the new domain I will be using. Then I realized that the reason for requiring the @domain.com part is to prevent getting ftp accounts on different virtual hosts mixed up. But, if I assign a dedicated IP address to a domain, I can use the simple ftp usernames without the @ part in that domain with the dedicated IP.

    Hope this helps someone,
    Karen

Similar Threads

  1. ftp & mysql usernames
    By zyxep in forum Database Discussions
    Replies: 3
    Last Post: 09-06-2009, 09:24 AM
  2. Custom FTP usernames
    By Abdujap in forum cPanel & WHM Discussions
    Replies: 2
    Last Post: 11-25-2008, 06:36 AM
  3. Replies: 1
    Last Post: 06-02-2006, 09:29 AM
  4. FTP usernames
    By Zim in forum cPanel & WHM Discussions
    Replies: 6
    Last Post: 03-11-2004, 10:18 AM
  5. FTP usernames for subdirectories
    By Wallaby in forum cPanel & WHM Discussions
    Replies: 3
    Last Post: 02-03-2003, 05:21 AM