Brief description

Currently, Russia uses the following Linux distributions:

To reduce dependence on particular distribution and batch database when you expand solutions to the most widely used containers Docker to avoid large overhead costs when deploying server and client solutions on a wide class of distributions. As container images are used as public containers,and containers designed for use in specific development projects. Developed containers, as a rule, are based on the distributions ALTLinux certified 7th platform and the 8th platform for General use. Deployment of solutions in the docker container system is described in the following section.

Installation and configuration of Linux OS

Description

To install and configure Linux, You need to choose a distro, download the image, burn it to physical media (flesh card or CD/DVD) and using interakcia to install it on a physical disk partition or in a virtual machine HyperV, VirtualBox, VMWare, … the table provides a list of distributions, links to the download page of the image, instructions for recording an image on a medium, the distribution and the license text.

Distribution Download Save Install License
ALTLinux P7 Download REC Setting License
BaseALT P8 Download REC Setting License  
ROSA Fresh Download REC Setting GPL License
Astra Linux Common Edition Download REC Setting License  
Ubuntu Download REC Setting GPL License
CentOS Download REC Setting the GPL and other

The application of all these distributions by individuals does not require the purchase of a license agreement from the copyright owner.

Please note that for distributions with a license GNU GPL (ROSA Fresh, Ubuntu, CentOS, …) in their application in commercial and public institutions and enterprises of the Russian Federation, a license is required to support the distribution and their application in state agencies may be restricted, as they are not included in the Unified register of the Russian software and database dannyh.

Lectures, courses, presentations, videos

Software

Laboratory work and practical tasks

Opportunities for certification

Install and configure WEB server apache2

description of the installation in the distributions of the family ALTLinux

The user in as root, type the command:

# apt-get update
# apt-get install apache2

Answer Y to the query about installing dependent packages. After installing apache2 and its dependent packages dial for automatic server startup Apache :

  • for server distros with SysV system Manager:
# chkconfig --add httpd2
# chkconfig --level 2345 httpd2 on
# service apache2 start
  • for server and desktop distributions, with a system Manager Systemd:
# systemctl enable apache2
# systemctl start apache2

By default, the apache server when obrazenia to port 80 at http://localhost/ displays the content located in /var/www/html/. If You plan to support multiple virtual hosts, You can configure in the file /etc/httpd2/conf/sites-available/vhosts.conf.

Apache2 server supports virtualizatio hosts

Code virtual host, usually located in subdirectories of the directory /var/www/vhosts/.

After the description of the virtual hosts you need to activate them and reboot the server:

# a2ensite vhosts
# service apache2 restart

Check rabotosposobnosti

After starting the server, type the command:

# netstat -nlpt | grep httpd2

the result string should be displayed with a description of the list of ports served by apache (default port 80):

tcp    0      0 :::80   :::*   LISTEN   xxxxx/httpd2

xxx is the number of process httpd2.

If the program netstat is missing, install it:

# apt-get install net-tools

or you can use the command

# fuser  -nv tcp 80

This command to display a list of root and child processes httpd2 serving port 80. For example:

80/tcp: 3756  3768  3769  3770  3771  3772

If the netstat command and/or the fuser output an empty list, look for errors in the log file /var/log/httpd2/error_log.

To check the operation of the apache2 server can be addressed in the browser to the address http://localhost/ or http://<ip-адрес-внешнего_интерфейса>/ when the server installation.

Typing

# tail -f /var/log/httpd2/*log

you can dynamically review the logs of the appeal to the pages of the apache2 server, the error and warnings in the server.

Lectures, courses, presentations, videos

Software

Laboratory work and practical tasks

Install and configure application server Mono/.NET

description of the installation in the distributions of the family ALTLinux

The user in as root, type the command:

# apt-get update
# apt-get install apache2-mod_mono mono4-full

Answer Y to the query about installing dependent packages.

After you install all the packages type the following command:

# cd /usr/bin
# ln -sf mod-mono-server4  mod-mono-server.sh
# cd /etc/httpd2/conf/mods-available/
# > mono.conf
# echo "LoadModule mono_module modules/mod_mono.so" > mono.load
# a2enmod  mono

Check rabotosposobnosti

Start your own virtual Mono/.NET site is similar to running a virtual site Apache2 server:

  • Place trees site in a separate directory (for example /var/www/vhosts/myMonoApp/) HOST system.
  • Add the configuration of Your virtual host configuration file /etc/docker/apache2/conf/vhosts.conf using the template:
Listen 881
NameVirtualHost *:881

<VirtualHost *:881>
  ServerName myMonoApp.local
  MonoServerPath test.local "/usr/bin/mod-mono-server4"
  MonoDebug myMonoApp.local true
  MonoSetEnv myMonoApp.local MONO_IOMAP=all
  MonoApplications myMonoApp.local "/:/var/www/vhosts/myMonoApp"
  AddDefaultCharset utf-8
  <Location "/">
    Allow from all
    Order allow,deny
    MonoSetServerAlias myMonoApp
    SetHandler mono
    #SetOutputFilter DEFLATE
  </Location>
  ErrorLog /var/log/httpd2/myMonoApp_error_log
  LogLevel debug
  CustomLog /var/log/httpd2/myMonoApp_access_log common
</VirtualHost>
  • Replace, if necessary, the 881 port to the port number you are going to use Your website, putting in the port in the-p flag when running the container. Domain myMonoApp.local to Your application domain name myMonoApp the name of Your mono application.

  • Restart apache2 server:

  • for server distros with SysV system Manager:

# service apache2 restart
    ``` 

* for server and desktop distributions, with a system Manager Systemd: 

systemctl restart apache2

``` 
  • Ask the browser to the root page of the virtual website URL: http://localhost:881/.

Lectures, courses, presentations, videos

Software

Laboratory work and practical tasks

Start ASP.NET applications on Linux Series of articles: Working with Mono

Go