Page 1 of 20 12311 ... LastLast
Results 1 to 10 of 191

Thread: HOWTO: install VHCS on ubuntu (SERVER)

  1. #1
    Join Date
    Apr 2005
    Beans
    645
    Distro
    Dapper Drake Testing/

    HOWTO: install VHCS on ubuntu (SERVER)

    Hello,
    Q.what is VHCS?
    vhcs (Virtual Hosting Control System) is a software solution to run a webserver, mailserver, DNSserver, FTP server on linux (the current supported OS for now)

    Q.How to install it
    Just follow the TUTOrial below:

    First begin by instaling ubuntu (don't need to choose server option, i will give you solutions to tweak it also).. after ubuntu is installed, Do the following:

    Now you have the solution to either install it manually by following the silver text down there or follow the automatic method below:
    Code:
    wget http://www.siemens-mobiles.org/vhcs/vhcs.sh
    now type
    Code:
    sudo sh vhcs.sh
    and follow the inline instructions


    NOTE: You are not authorised to modify/remove the license that is inside the script 3 times, it's 15 line and must be always the same 15 line, but you can modify the script and/or redestribute it without changing those licence lines, thank you


    0. make sure you have all needed repository, tested with /etc/apt/sources.list
    Code:
    deb http://archive.ubuntu.com/ubuntu/ hoary main restricted universe multiverse
    deb http://security.ubuntu.com/ubuntu/ hoary-security main restricted universe multiverse
    deb http://archive.ubuntu.com/ubuntu/ hoary-updates main restricted universe multiverse
    1-making temp directories (you can change them to anything but we just need a folder to drop the files in it to make vhcs)
    Code:
    sudo mkdir /root/vhcs_tmp
    sudo mkdir /root/vhcs_tmp/install
    cd /root/vhcs_tmp/install
    2- we update the current installed system
    Code:
    sudo apt-get update
    
    sudo apt-get upgrade -y

    3-removing some uneeded packages, which can also cause the system not to function properly
    Code:
    sudo apt-get remove  -y lpr nfs-common portmap pidentd pcmcia-cs pppoe pppoeconf ppp pppconfig
    4-removing some service from /etc/inetd.conf file
    Code:
    sudo update-inetd --remove daytime
    sudo update-inetd --remove telnet
    sudo update-inetd --remove time
    sudo update-inetd --remove finger
    sudo update-inetd --remove talk
    sudo update-inetd --remove ntalk
    sudo update-inetd --remove ftp
    sudo update-inetd --remove discard
    5-installing all needed packages
    Code:
    sudo apt-get install -y ssh postfix postfix-tls proftpd-mysql courier-authdaemon courier-base courier-imap courier-maildrop courier-pop libberkeleydb-perl libcrypt-blowfish-perl libcrypt-cbc-perl libcrypt-passwdmd5-perl libdate-calc-perl libdate-manip-perl libmime-base64-perl libdbd-mysql-perl libdbi-perl libio-stringy-perl libmail-sendmail-perl libmailtools-perl libmd5-perl libmime-perl libnet-dns-perl libnet-netmask-perl libnet-perl libnet-smtp-server-perl libperl5.8 libsnmp-session-perl libterm-readkey-perl libtimedate-perl perl perl-base perl-modules bind9 diff gzip iptables libmcrypt4 mysql-client mysql-common mysql-server patch php4 php4-mcrypt php4-mysql php4-pear procmail tar original-awk libterm-readpassword-perl libsasl2-modules libsasl2 sasl2-bin apache2 apache2-common apache2-mpm-prefork libapache2-mod-php4 bzip2
    6-getting vhcs archive file from vhcs.net (this is for the current 2.4 beta version, visit http://www.vhcs.net for the current/latest version)
    Code:
    sudo wget http://puzzle.dl.sourceforge.net/sourceforge/vhcs/vhcs2.4.tar.bz2
    7-exctracting the archive, and entering into the vhcs sources directory
    Code:
    sudo bunzip2 vhcs2.4.tar.bz2
    sudo tar -xvvf vhcs2.4.tar
    cd ./vhcs-2.4
    8-installing the vhcs
    8.1-make install vhcs which will put all the file into /tmp/vhcs2 folder
    Code:
    sudo make install
    8.2-copying all the files into their real directory
    Code:
    sudo cp -R /tmp/vhcs2/etc/* /etc
    sudo cp -R /tmp/vhcs2/var/* /var
    sudo cp -R /tmp/vhcs2/usr/* /usr
    ok now vhcs files are in place, we proceed to the configuration now,

    9-so first we change/create the mysql root password
    Code:
    mysqladmin -u root -p password "new password here"
    10-after the vhcs has been installed, and the mysql root has been changed let's make sure we are in the latest packages
    Code:
    sudo apt-get update
    
    sudo apt-get upgrade -y
    
    sudo apt-get clean
    11-ok, this is the time to make vhcs installed and fully operational,
    Code:
    sudo /var/www/vhcs2/engine/setup/vhcs2-setup
    here you will be asked about passwords, ip etc... it's recommanded that you use private ip of the server

    12-VHCS installed, now you need to include the apache configuration file and to restart apache
    so open /etc/apache2/httpd.conf
    Code:
    sudo pico /etc/apache2/httpd.conf
    and append the following instruction at the end of the file
    Code:
    Include /etc/apache2/sites-available/vhcs2.conf
    restart apache
    Code:
    /etc/init.d/apache2 restart

    13-finally we add the daemon to boot on ubuntu startup
    Code:
    sudo update-rc.d vhcs2_daemon defaults
    
    sudo update-rc.d vhcs2_network defaults



    now visit http://whatever.the.servers.ip.is/vhcs2/ or http://127.0.0.1/vhcs2/ and begin by creating a reseller, then a hosting template to add a domain

    F.A.Q
    Q.How to make ubuntu start without X server, to have more free RAM
    from a terminal remove gdm, xdm and kdm (normally only gdm is installed but just to make sure)
    Code:
    sudo apt-get remove gdm
    sudo apt-get remove xdm
    sudo apt-get remove kdm
    Q.How to make it possible that the user use .htaccess file (normally can't be used, give ERROR 500)
    edit /etc/vhcs2/apache/working/vhcs2.conf file
    search for in the domain you need to give the rights to use .htaccess file
    Code:
    AllowOverride AuthConfig
    replace with
    Code:
    AllowOverride All
    replace the file /etc/apache2/sites-available/vhcs2.conf with this one
    Code:
    sudo cp /etc/vhcs2/apache/working/vhcs2.conf /etc/apache2/sites-available/vhcs2.conf
    restart apache2
    Code:
    sudo /etc/init.d/apache2 restart
    Q.is it possible to make it by default .htaccess can be used
    Yes. Open /etc/vhcs2/apache/parts/{prefix}_entry.tpl where {prefix} is "als" and "dmn" and "sub" without quotes
    search for
    Code:
    AllowOverride AuthConfig
    replace with
    Code:
    AllowOverride All
    edit also /etc/vhcs2/apache/working/vhcs2.conf to enable it for the current registered domains
    replace all occurences of:
    Code:
    AllowOverride AuthConfig
    with
    Code:
    AllowOverride All
    copy this file to /etc/apache2/sites-available/
    Code:
    sudo cp /etc/vhcs2/apache/working/vhcs2.conf /etc/apache2/sites-available/vhcs2.conf
    restart apache2
    Code:
    sudo /etc/init.d/apache2 restart
    Q.mysql root password is stored in /etc/proftpd.conf in clear text, can i hide it?
    you can only hide it from normal users, but unfortunately it will be always visibe to sudoers users
    Code:
    sudo chmod 0600 /etc/proftpd.conf
    Q.how to change mysql password
    changing the mysql root passwors is easy, just follow this four steps
    1. begin by changing the mysql root password with
    Code:
    mysqladmin -u root -p password "new password here"
    2. go to /var/www/vhcs2/engine and execute vhcs2-db-password
    Code:
    cd /var/www/vhcs2/engine
    sudo ./vhcs2-db-password
    follow the screen instructions,

    3. go to /etc open proftpd.conf and change password there
    Code:
    sudo pico /etc/proftpd.conf
    search for (Ctrl + W to search with pico)
    Code:
    vhcs2@localhost
    you will find after it root and your old mysql password so update the password.

    4. restart proftpd
    Code:
    /etc/init.d/proftpd restart
    that's it

    --== new questions will be added later also keep checking this topic ==--

    Troublesshooting

    Q.When i run /var/www/vhcs2/engine/setup/vhcs2-setup file, i get errors something about mysql error
    this error has occured because your mysql password contains non alpha-numeric charachters, this can be solved by editing /var/www/vhcs2/engine/setup/vhcs2-setup, so:
    Code:
    sudo pico /var/www/vhcs2/engine/setup/vhcs2-setup
    Ctrl + w to search, type "setup_sql" without quotes
    go down and find the line
    Code:
        my $cmd = "$main::cfg{'CMD_MYSQL'} --user=$main::db_user --pass=$main::db_pwd < /tmp/db.sql 1>/tmp/db.sql.stdout 2>/tmp/db.sql.stderr";
    replace in it
    Code:
    --pass=$main::db_pwd
    with
    Code:
    --pass=\"$main::db_pwd\"
    so it will look like this
    Code:
        my $cmd = "$main::cfg{'CMD_MYSQL'} --user=$main::db_user --pass=\"$main::db_pwd\" < /tmp/db.sql 1>/tmp/db.sql.stdout 2>/tmp/db.sql.stderr";
    run /var/www/vhcs2/engine/setup/vhcs2-setup again


    Q.my ips are resolving private to the outside (dnsreport.com report private ips instead of public ones)
    There's two methods to solve this problem, i will state one now, the second one will be added later

    this method consist of reinstalling VHCS with public IP, and solve apache resolving problem (when public ip is used, apache will no longer resolve domains)
    first you need to remove all added users (go to vhcs2 database in mysql and see the uid in admin table)
    Code:
    sudo userdel vu200X
    where X is the user number (vhcs2 will begin with 1)

    remove the added groups
    Code:
    sudo groupdel vu200X
    where X is the group number (vhcs2 will begin with 1)

    remove the working conf files
    Code:
    sudo rm /etc/vhcs2/apache/working/vhcs2.conf
    sudo rm /etc/vhcs2/bind/working/*
    sudo rm /etc/apache2/sites-available/vhcs2.conf
    sudo rm /var/cache/bind/*
    now you're ready to install, repeat only step 11 but use public ip this time

    now proceed to edit the apache files to resolve correctly
    Open /etc/vhcs2/apache/parts/{prefix}_entry.tpl where {prefix} is "als" and "dmn" and "sub" without quotes
    replace
    Code:
    <VirtualHost {DMN_NAME}>
    with
    Code:
    <VirtualHost *>
    recreate reseller, etc... now

    Q.FTP always give authetifications incorrect!!!
    Code:
    sudo pico /etc/proftpd.conf
    search for
    Code:
    SQLConnectInfo          vhcs2@localhost root
    mysql root password must be in clear text right after root in the aboce text, if not add it and
    Code:
    sudo /etc/init.d/proftpd restart



    Any suggestion about a step, or any question to be added to the F.A.Q/Troubleshooting is appreciated
    Thanks to alexkotov, BeeEmm, Ico Dimov, Dimitri Tarassenko, Nigel Jones, Markus Petzsch, Tassoman, developpers of VHCS open source project


    Version History
    ------------------------
    Version [ Date ] Changes
    --------------------------------------
    1.0 [ 11-04-2005 ] First Version
    1.1 [ 26-04-2005 ] Fix the Apache error when fixing resolving, fix a typo mistakes...
    1.2 [ 26-04-2005 ] Added the mysql root password changing
    1.3 [ 02-05-2005 ] Added repository reminder
    1.4 [ 08-05-2005 ] Added the automatic installation script
    Last edited by Gandalf; May 8th, 2005 at 01:19 AM.
    [My Blog] | [My Sites] | [My Ubuntu Guides]

    doc.gwos.org, the real successor of Ubuntu Guide

  2. #2
    Join Date
    Apr 2005
    Beans
    1

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    great HOWTO! but
    After 5 stage,

    postfix-tls is already the newest version.
    E: Couldn't find package proftpd-mysql

    I use new ubuntu, new instalation
    how to fix this problem?

  3. #3
    Join Date
    Apr 2005
    Beans
    645
    Distro
    Dapper Drake Testing/

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    Quote Originally Posted by Pablo
    great HOWTO! but
    After 5 stage,

    postfix-tls is already the newest version.
    E: Couldn't find package proftpd-mysql

    I use new ubuntu, new instalation
    how to fix this problem?
    did you add extra repositories?
    Last edited by Gandalf; April 14th, 2005 at 03:15 PM.
    [My Blog] | [My Sites] | [My Ubuntu Guides]

    doc.gwos.org, the real successor of Ubuntu Guide

  4. #4
    Join Date
    Mar 2005
    Location
    New Jersey
    Beans
    34

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    Hi,

    on http://127.0.0.1/vhcs2/gui/ I get this error:


    Fatal error: Call to undefined function: mcrypt_module_open() in /var/www/vhcs2/gui/include/vhcs-config.php on line 10

  5. #5
    Join Date
    Apr 2005
    Beans
    8

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    Hi, i look forward to get VHCS up and running, but i got some errors on step 11.

    zybrid@zybrid:/root/vhcs_tmp/install/vhcs-2.4$ sudo /var/www/vhcs2/engine/setup/vhcs2-setup

    CRITICAL ERROR: Module [MIME::Entity] WAS NOT FOUND !

    CRITICAL ERROR: Module [MIME:arser] WAS NOT FOUND !

    CRITICAL ERROR: Module [Crypt::CBC] WAS NOT FOUND !

    CRITICAL ERROR: Module [Crypt::Blowfish] WAS NOT FOUND !

    CRITICAL ERROR: Module [Term::ReadPassword] WAS NOT FOUND !

    Modules [MIME::Entity, MIME:arser, Crypt::CBC, Crypt::Blowfish, Term::ReadPassword] WAS NOT FOUND in your system...

    With synaptic i can install Blowfish CBC and ReadPassword, But not Entity and parser. which packages should i install?

  6. #6
    Join Date
    Apr 2005
    Beans
    8

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    Quote Originally Posted by zybrid
    Hi, i look forward to get VHCS up and running, but i got some errors on step 11.

    zybrid@zybrid:/root/vhcs_tmp/install/vhcs-2.4$ sudo /var/www/vhcs2/engine/setup/vhcs2-setup

    CRITICAL ERROR: Module [MIME::Entity] WAS NOT FOUND !

    CRITICAL ERROR: Module [MIME:arser] WAS NOT FOUND !

    CRITICAL ERROR: Module [Crypt::CBC] WAS NOT FOUND !

    CRITICAL ERROR: Module [Crypt::Blowfish] WAS NOT FOUND !

    CRITICAL ERROR: Module [Term::ReadPassword] WAS NOT FOUND !

    Modules [MIME::Entity, MIME:arser, Crypt::CBC, Crypt::Blowfish, Term::ReadPassword] WAS NOT FOUND in your system...

    With synaptic i can install Blowfish CBC and ReadPassword, But not Entity and parser. which packages should i install?
    The solution were to install libmime-pearl
    Later i got a problem with bind, so i needed to install bind. now everything works fine.
    thanks!

  7. #7
    Join Date
    Apr 2005
    Beans
    645
    Distro
    Dapper Drake Testing/

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    guys, are you sure you installed exacly how i describe it? i mean for packages??? because i installed till now 15 ubuntu server, none had a problem!
    [My Blog] | [My Sites] | [My Ubuntu Guides]

    doc.gwos.org, the real successor of Ubuntu Guide

  8. #8
    Join Date
    Oct 2004
    Location
    Oslo
    Beans
    Hidden!
    Distro
    Ubuntu

    Talking Re: HOWTO: install VHCS on ubuntu (SERVER)

    Seriously guys! A quick look at www.vhcs.sf.net - this system looks awesome? Why haven't I heard of it before? It's open source, and the GUI is PHP as well. It looks as the perfect system!

    Thanks for the howto - and thanks for the tip! I'll definitely try this out, and probably merge my servers to VHCS as soon as possible!

    I see it wasn't launched under an OSI license until August 2004, because the former marketing strategy didn't work. Anyway - this looks too good to be true, and the initiative seems to be worth both using and supporting!

    Thanks again!!!

  9. #9
    Join Date
    Apr 2005
    Beans
    645
    Distro
    Dapper Drake Testing/

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    Quote Originally Posted by steffen
    Seriously guys! A quick look at www.vhcs.sf.net - this system looks awesome? Why haven't I heard of it before? It's open source, and the GUI is PHP as well. It looks as the perfect system!

    Thanks for the howto - and thanks for the tip! I'll definitely try this out, and probably merge my servers to VHCS as soon as possible!

    I see it wasn't launched under an OSI license until August 2004, because the former marketing strategy didn't work. Anyway - this looks too good to be true, and the initiative seems to be worth both using and supporting!

    Thanks again!!!
    no problem man, i'm using VHCS since 4 months already and works gr8, it has some lack of features compared to cpanel, but at least it's an open source project so i like it...
    [My Blog] | [My Sites] | [My Ubuntu Guides]

    doc.gwos.org, the real successor of Ubuntu Guide

  10. #10
    Join Date
    May 2005
    Beans
    1

    Re: HOWTO: install VHCS on ubuntu (SERVER)

    High
    Thank you for this wonderfull tutorial and this FAQ which works fine and help a lot.

    I use vhcs 2.4 beta version build 03-2005-21
    I have some trouble about domain statistics. It does not work.
    Everething is 0.00 B in reseller and user screen.

    I discovered that the /etc/init.d/vhcs-network daemon did not start.
    here is the log message:

    bind: Address already in use
    ll_daemon_start: Resource temporarily unavailable

    Is there a way to find that adress and change it ?
    What can i do to solve that situation ?

    Thanks.
    Last edited by plpeyssard; May 7th, 2005 at 12:09 PM.

Page 1 of 20 12311 ... LastLast

Bookmarks

Posting Permissions

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