Vous êtes sur la page 1sur 19

SERVER

CONFIGURATION
Sec 5, System Management, Web apps

Introduction
Linux has many built-in tools to assist sys admins
in administering Linux servers and workstations
Many of these tools provide much utility for
managing Linux hosts
However, many of them also use legacy
command line interfaces
Since the advent of the Web, modern tools can
often take advantage graphical user interfaces
and easy to read and interpret graphics making it
easier to both identify issues and manage Linux
systems
Web tools
Nice features of web tool interfaces include
functional graphics
the ability to view log files graphically
the ability to record system statistics in real time
and view them in the browser
General business Web apps
The largest category of Web apps, also known as
Software As A Service (SAAS) or, if youre storing
the associated data online, called Cloud
Services, are business applications
These include
Customer Relationship Management (CRM)
Human Resources (HR)
Ordering and Provisioning (Tomato Cart)
Social Media for businesses (Wikis, Bulletin Boards,
Groupware, Chat)
The last category is in some instances, replacing
email for internal company communications
System management
Of interest to us, sys admins, is a category that
includes tools to
Manage the distribution of subnets and ip addresses
Monitor multiple systems uptime
Monitor multiple systems internal statistics counters (MIB,
SNMP)
Manage system inventory
Manage trouble tickets
Manage clusters
Provide general system management tools
Manage multiple virtual machines
Manage databases
And much, much more
Web tool basics
Depending the setup, web tools can have a
very involved setup
Most web tools require a certain set of specific
feature in place before you can install them
Most web tools rely on several interacting tools
including a web server, database server, the
host operating system itself, and scripting tools
The package web tools
The package of tools described on the
previous slide is called a LAMP server
LAMP because
L inux operating system
A pache web server
M ySQL database server
P HP (Perl or Python, but originally PHP) scripting
language
Web tool setup i
The steps for choosing and installing a web
package are pretty much the same across most
operating systems and web servers
Steps include
Determining company needs
Matching software packages to company needs using
sites like Sourceforge.com or Freecode.org (formerly
Freshmeat.com)
Downloading packages, setting them up, and testing
them for stability and usability, and level of support
package creator may (or may not) provide
Choice made, setup ii
Once a choice has been made, the process
begins, suggesting a fresh install on your
production server
Download or copy fresh package to a directory on
your system for unpacking
Read the README or Installation instructions, as
you did for your testing phase
Unpack the package (install instructions may be
here after unpacking)
Copy the package to Web server directory
On SuSE /srv/www/htdocs
Basic installation, setup iii
The general basic installation steps in order
Unpack the rpm or tarball (.tar.gz) package
Copy the unpacked package to the ../../htdocs folder,
the folder name will be your Web URL for the package
chown -R the package (folder) (must have the -R to
score this step) with the web server user and group as
new owner
Create the database
Run the installer
Sometimes, the installer will create the database
for you, other times, youll have to create it by
hand
Basic installation, setup iv
Database install tips
If your installer creates the database for you, it will
also create a database user
The database user has permissions to modify the data
in the database and is used exclusively by the web
program
If you create the database by hand, youll not only
create the database, but create the above mentioned
database user that can change records and tables in
the database, again, used exclusively by the web
program

Basic installation, setup v
If your installer is a fully featured installer, it will
create and edit the necessary configuration file
If your installer is basic, or non-existent, youll
have edit some form of configuration file
Most often this file is
config.php
Sometimes the README/Installation
instructions file will have you alter a different
configuration file, or more than one
Hand edits, setup iv
Most often hand edits of the config.php file
include altering
database name
database username
database user password
Database creation, setup vii
Steps for database creation can include
Create the catalog (schema or database if using
Webmin)
Create a database user
Give the database user the correct permissions via
the README's or installation instructions
Add hosts/host permissions, if required
Once again, the database user the app or we
create is the user used to modify the database
(sugaruser, orangeuser etc., the name is usually
your choice)
Web server access, setup viii
The web server itself must have complete access to
manage the web app files, we give it access as
described below
chown -R wwwrun.www <folder name> ex. chown -R
wwwrun.www sugarce

chown -R - change owner, changes the folder and file
ownership to that of the Web server user and group. -R
applies chown recursively to all folders and file
below the specified directory

wwwrun - the web server user
www - the web server group
<folder name> - the base folder that contains the web app

Possible host permission, setup
ix
Certain host permissions may need to be set
to access the database and allow web access
localhost
% - anywhere
IP address or host name
PHP modules, setup x
Sometimes, your app may require PHP
modules beyond the base installation
Youll need to use your package manager to
add them, then restart the web server, three
different ways are shown below
restart the web server
rcapache2 restart
service apache2 restart
/etc/init.d/apache2
Setup finished, testing
Once setup is finished, point your browser to:
http://localhost/<your folder name>
Example for Sugar CRM for the folder named
sugar
http://localhost/sugar

Summary
Web apps are a powerful tool for you business
and are just as powerful for managing your
systems
Consider Web apps for business use
Consider Web apps for system management
Choose a capable LAMP platform
Research and test your choices
Install the app per README or Installation
documentation

Vous aimerez peut-être aussi