VPs configuration tutorial

Source: Internet
Author: User

CD to change the working directory to dirname. Dirname can be an absolute or relative path.

LsCommand is used to view the list of files in any directory where the user has the execution permission. This command has many interesting options.

Cat checks the content of a text file from the command line,CatOutput all rows in the file at a time.

VI edit text document

LinuxVPSHow to Use

VPSApache, PHP, and MySQL are installed by default. You only need to configure the website and virtual host. The specific process is

1: users purchase linuxserver on the volcano Internet siteVPSThe correspondingVPSService information.

2: remotely log on to the linuxserver virtual machine. You need to install the SSH client locally (Windows platform: securecrt, putty, and other tools ).

3: All associated with the volcanoVPSYou have configured and run the website and FTP services. Users can make changes as needed.

    • The Apache service installation path is/usr/local/apache2/; the website data path is/data/web/; the Apache configuration file is/usr/local/apache2/CONF/httpd. conf; the PHP configuration file is/etc/PHP. INI,

      You can edit/usr/local/apache2/CONF/httpd. conf or/usr/local/apache2/CONF/vhost. conf to change the VM.

Important:VPSWith the shared IP address, all Website access (port 80 service) is forwarded to the realVPSSo all website services must be in our member centerVPSUse"Domain NameBind"Function addedVPSWebsite inDomain NameBefore normal access.

For exampleVPSTest.volit.comDomain NamePointVPSThe website cannot be accessed normally. Only when"Domain NameBindBefore access.

"Domain NameBind"Process: log on to the member center and go to"VPSManagement "-> display the purchased or appliedVPSProduct, click the product name or click "manage" next to it to go to the Management page.Domain NameBind"Input in the input boxDomain Name, After submission.

Start configuring our own website now

Input:

VI/usr/local/apache2/CONF/httpd. conf (Press ESC to exit editing, and then SHIFT + ZZ to exit editing and save)

Follow the prompts to go To the content section of httpd. conf and press ENTER or the down arrow to go to the last screen:

The last line includes "/usr/local/apache2/CONF/vhost. conf refers to the configuration file of the VM. Of course, if it is the same as the previous section, it can be directly used in httpd. configure the VM in Conf.

Modify the followingCode

# My.mysql.cn begin

<Virtualhost *>

DocumentRoot/data/web/mysqladmin

Servername mysq; .mysql.cn

Php_admin_valut open_basedir/data/web/mysqladmin

Php_admin_value upload_tmp_dir/data/web/mysqladmin

</Virtualhost>

# My.mysql.cn end

Is

# My.mysql.cn begin

<Virtualhost *>

DocumentRoot/data/web/mysqladmin

Servername mysql.asgone.net

# Php_admin_value open_basedir/data/web/mysqladmin

# Php_admin_value upload_tmp_dir/data/web/mysqladmin

</Virtualhost>

# My.mysql.cn end

In this way, mysql.asgone.net is configured to open the phpMyAdmin page.

Then, you can use/usr/local/apache2/CONF/vhost. conf to create more virtual hosts (free of charge for volcano interconnection ).VPSOnlyBind10Domain Name)

Input:

VI/usr/local/apache2/CONF/vhost. conf

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.