Results 1 to 14 of 14

Thread: HOWTO: Setup A New DirectAdmin Server

  1. #1
    Join Date
    May 2003
    Location
    /home/admin
    Posts
    298

    HOWTO: Setup A New DirectAdmin Server

    This guide is no longer applicable.

    Please view:
    http://directadmin.com/installguide.html

    For the DirectAdmin installation guide!

    ------------------------------------------------------------

    The purpose of this HOWTO is to give DirectAdmin newbies a "to-the-point" method of getting their new server set up. With this said, let's get started setting up our server!

    Just a note before we begin, you will see tags like this: [TAB], [ESC], [ENTER] in this guide. They simply mean to hit that key on your keyboard.

    Additionally, this guide is for a bare-naked machine (fresh/clean install of Redhat 8), so you may skip some features listed in this guide, if you need to.

    Register with RedHat Network

    If you are not registered already, just type the following to do so now:

    Code:
    up2date --register
    Fill out all the fields on-screen, and you'll be set to go in no time.

    Make sure ifconfig is in your PATH

    Code:
    locate ifconfig
    Note the path to the binary, and then type:

    Code:
    export PATH=$PATH:/path/to/bindir
    More than likely, ifconfig will be found in /sbin.

    Disable Telnet

    The first thing we will do, before anything else, is disable Telnet. We are doing this because SSH exists, and Telnet is simply useless, and too insecure for us. Depending on your setup, the method for turning telnet off may vary. If you are running xinetd, all that is needed is to do the following:

    Code:
    vi /etc/xinetd.d/telnet [ENTER]
    Find the "disabled" field and set it to "yes". Then:

    Code:
    [ESC] :wq [ENTER]
    /etc/rc.d/init.d/xinetd reload [ENTER]
    Install/Upgrade Webalizer

    The DirectAdmin installation requires Webalizer to be installed. The easiest way to do this, is to go to www.rpmfind.net and find the latest version for your OS distribution. If you are using RH8, like I am, you can do the following:

    Code:
    up2date -u webalizer [ENTER]
    Ensure GCC is Installed

    Next, we will upgrade GCC. We'll want to most recent version before we install DirectAdmin:

    Code:
    up2date -u gcc [ENTER]
    Additionally, we need pam-devel, bison, and flex. So, run these commands also:

    Code:
    up2date -u pam-devel [ENTER]
    up2date -u bison [ENTER]
    up2date -u flex [ENTER]
    Ensure named Configuration Exists

    We'll also need to check that named is configured properly. Type:

    Code:
    less /etc/named.conf [ENTER]
    If it does not exist, do this:

    Code:
    wget http://66.51.122.131/named.conf -O /etc/named.conf [ENTER]
    wget http://66.51.122.131/named.ca -O /var/named/named.ca [ENTER]
    Install DirectAdmin

    We are now ready to begin installing DirectAdmin:

    Code:
    mkdir /usr/local/directadmin [ENTER]
    cd /usr/local/directadmin [ENTER]
    Replace yourlid with your License ID and youruid with your user ID:

    Code:
    wget https://www.directadmin.com/cgi-bin/...d\&uid=youruid -O /usr/local/directadmin/update.tar.gz [ENTER]
    Now confirm that you've downloaded the file successfully by running:

    Code:
    ls -lh /usr/local/directadmin/update.tar.gz [ENTER]
    The file size should be around 2.5mb. If it is not, try removing the file and downloading it again.

    Next, we can untar the file and begin the installation:

    Code:
    tar xvzf update.tar.gz [ENTER]
    cd /usr/local/directadmin/scripts [ENTER]
    ./getInfo.sh [ENTER]
    Now check that getInfo.sh set everything up properly, by running:

    Code:
    cat ./setup.txt [ENTER]
    If there is something you need to change, edit setup.txt to your liking. Then continue on:

    Code:
    ./install.sh [ENTER]
    Last edited by loopforever; 04-18-2005 at 10:16 PM.
    Matt Savona
    serveIO
    Creator of the DirectAdmin Enhanced Theme

  2. #2
    Join Date
    May 2003
    Location
    /home/admin
    Posts
    298
    More to come as I continue messing with my new machine... ...
    Matt Savona
    serveIO
    Creator of the DirectAdmin Enhanced Theme

  3. #3
    That's great, it will save us a lot of time for support requests!

    Just a few changes:
    The /etc/named.conf and /var/named/named.ca files are automatically downloaded if they don't exist.

    Many servers don't have bind installed, but they do have bind-utils (old version), so:
    rpm -e --nodeps bind-utils
    up2date -u bind

    Also, I've found all places I call ifconfig and hardcoded the full path so its no longer required to add the path to your environment.

    MySQL has been existant on so many servers in so many forms that the mysql installer now has to use brute force to get things done. It will ask you if it can delete the /var/lib/mysql directory, say 'y' (yes) so that any root passwords (that are usually long forgotten) will be wiped out nice and clean.. you *can* say no, but you have to be absolutely sure you have the correct root password in the setup.

    Note: *** Don't use spaces in your mysql passwords!!! ***
    bash interprets spaces as being the next variable so things might get messed up

    The Installer will chug along happily... for ./install.sh

    Note: the admin user will be deleted before the install (if it exists), so if it exsits, backup whatever you need

    After the installer is done, its a good idea to make sure that your license file has downloaded properly. It's filesize should be 1298 bytes, and if you "cat license.key" you should see:
    version=1.1
    (a whole pile of Hex)
    (binary stuff that will mess up your screen )

    Thats how you know it worked. If you see any error messages, you can either download it manually or just send us an email... to manually get it, its very similar to getting directadmin in the first few steps:

    wget https://www.directadmin.com/cgi-bin/...d=UID\&lid=LID -O /usr/local/directadmin/conf/license.key

    Also, always check that the databases section of DirectAdmin is working properly. If you can see a table without any databases, you know it worked. It will give an error if it can't connect when the CMD_DB page is loaded.

    For almost all of the new installs that *we* do, we will install our "customapache" build script to overwrite all of the old versions of the software. Until we integrate this into the installer, it will have to be downloaded and executed seperatly... note that you don't *have* to run it, but it's highly recommended.

    John

  4. #4
    Join Date
    Dec 2003
    Posts
    51
    Very Nice

    What about FreeBSD "HOWTO: Setup A New DirectAdmin on FreeBSD Server"?

    I will be waiting for this.

    Thanks mate

  5. #5
    Hello,

    Just a note about this Redhat How-To.. we now use setup.sh to Install DA and it does about 90% of the commands listed above. (Doesn't install gcc)

    FreeBSD is basically the same, just downlaod setup.sh, chmod it to 755 and answer the questions.

    John

  6. #6
    Join Date
    Jun 2003
    Location
    Tehachapi, California
    Posts
    49

    56 bytes

    When d/ling the update.tar.gz file I'm given a 56 byte file.

    I need to re-install DA on a server which had a hdd failure.

    Can someone please tell me where to d/l installation files?

    Thanks!

    *edit*

    NM Mark to the rescue! Thanks Mark your the best!
    Last edited by bonnmac; 02-14-2004 at 02:47 PM.
    http://peachydomains.com

  7. #7
    Join Date
    Oct 2004
    Posts
    6
    I'm getting this error, could anybody help me with it?

    cat: /etc/rc.conf: No such file or directory
    ./doChecks.sh: line 20: [: !=: unary operator expected
    *** bison is required for compiling, please install bison ***
    Installation didn't pass, halting install.

  8. #8
    Join Date
    Mar 2004
    Location
    TeleCity 2, Amsterdam
    Posts
    45
    Originally posted by S4rz
    I'm getting this error, could anybody help me with it?

    cat: /etc/rc.conf: No such file or directory
    ./doChecks.sh: line 20: [: !=: unary operator expected
    *** bison is required for compiling, please install bison ***
    Installation didn't pass, halting install.
    Install bison. Use yum install bison, if u have configured yum correctly.
    #yum install bison

    Else... check rpmfind.net

    With other os'es... check Google.

  9. #9
    Join Date
    Feb 2005
    Posts
    57
    Any updates for red hat 9?

    I'm kinda new as admin, and I don't want to mess my brand new server

  10. #10
    Join Date
    Apr 2005
    Posts
    8
    i dont have up2date installed on my server and cant seem to find it (FC2) so whenever i ./setup.sh i get an error message:
    Cannot find /etc/sysconfig/rhn/up2date... up2date may break things.
    *** g++ is required for compiling, please install g++ (up2date -u gcc-c++)***
    Installation didn't pass, halting install.


    please advise.

  11. #11
    Join Date
    Apr 2005
    Posts
    4
    Originally posted by MIA
    i dont have up2date installed on my server and cant seem to find it (FC2) so whenever i ./setup.sh i get an error message:
    Cannot find /etc/sysconfig/rhn/up2date... up2date may break things.
    *** g++ is required for compiling, please install g++ (up2date -u gcc-c++)***
    Installation didn't pass, halting install.


    please advise.

    On Fedora there is the option YUM (nearly the same as up2date)

    Installing it with yum : yum install gcc-c++


    Thats should to the trick and after installing the gcc-c++ module you will be able to install directadmin.

  12. #12
    Join Date
    Apr 2005
    Posts
    8
    yah, i found that after my 6 hours wasted.

  13. #13
    Join Date
    May 2003
    Location
    /home/admin
    Posts
    298
    Just so you guys know...this guide is rather old. Some parts no longer apply...you're better off just reading this:

    http://directadmin.com/installguide.html
    Matt Savona
    serveIO
    Creator of the DirectAdmin Enhanced Theme

  14. #14
    Join Date
    Jun 2003
    Location
    California
    Posts
    26,122
    Matt,

    Why don't you edit your first post to point this out, instead of placing it at the end?



    Jeff
    +1 951 643-5345
    Third-Party DirectAdmin administration and support
    Dedicated Servers, Dedicated Reseller Accounts
    NoBaloney Internet Services div. Qnito Incorporated
    848 North Rainbow Blvd., Suite #3789
    Las Vegas, NV 89107-1103

Similar Threads

  1. HOWTO: Setup Nameservers
    By loopforever in forum How-To Guides
    Replies: 26
    Last Post: 05-17-2016, 02:56 AM
  2. Replies: 23
    Last Post: 03-01-2013, 01:43 PM
  3. Emergency Assistance: Directadmin About New Server Setup
    By reistek in forum DirectAdmin General Discussion
    Replies: 3
    Last Post: 02-27-2010, 06:42 PM
  4. HowTo Setup Imap.
    By milan in forum E-Mail
    Replies: 6
    Last Post: 02-23-2007, 08:16 AM
  5. HowTo setup external secondary DNS?
    By resolveit in forum How-To Guides
    Replies: 17
    Last Post: 05-13-2004, 02:54 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •