[vmware][eng]how-to simple install and configure an ubuntu virtual server

43
Tutorial Tutorial How to prepare How to prepare Ubuntu 9.04 VMWare Image Ubuntu 9.04 VMWare Image from from http://www.thoughtpolice.co.u http://www.thoughtpolice.co.u k/ k/ Jean Marie PASCAL Jean Marie PASCAL [email protected] [email protected]

Upload: jmpascal

Post on 16-Nov-2014

156 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

TutorialTutorial

How to prepare How to prepare Ubuntu 9.04 VMWare ImageUbuntu 9.04 VMWare Image

from from http://www.thoughtpolice.co.uk/http://www.thoughtpolice.co.uk/

Jean Marie PASCALJean Marie PASCAL

[email protected]@gmail.com

Page 2: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 2

Download Ubuntu VMWare ImageDownload Ubuntu VMWare Image

Install VMWare FreePlayerInstall VMWare FreePlayer

Configure Ubuntu ImageConfigure Ubuntu Image

Install SSHInstall SSH

Check connexionCheck connexion

GoalsGoals

Page 3: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 3

Configuration UsedConfiguration Used Operating System : Operating System :

Windows XP SP2Windows XP SP2

ProcessorProcessor Intel Core 2 DuoIntel Core 2 Duo

Computer memoryComputer memory 2Gb2Gb

Page 4: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 4

Pre-requisites Pre-requisites Installation ofInstallation of

Putty (Command lines)Putty (Command lines) WinSCP (File Transfert)WinSCP (File Transfert)

Basic knowledge on Linux commandsBasic knowledge on Linux commands

Page 5: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 5

Download Ubuntu VMWare ImageDownload Ubuntu VMWare Image Go toGo to

http://www.thoughtpolice.co.uk/vmware/http://www.thoughtpolice.co.uk/vmware/ ChooseChoose

Ubuntu Server 9.04Ubuntu Server 9.04

Login : Login : notrootnotroot Password : Password : thoughtpolicethoughtpolice

Page 6: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 6

Install VMWare FreePlayerInstall VMWare FreePlayer VMWare FreePlayerVMWare FreePlayer

http://www.vmware.com/products/player/http://www.vmware.com/products/player/

Launch .exe and follow the wizardLaunch .exe and follow the wizard

Page 7: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 7

Start VMWare ImageStart VMWare Image Start VMWare PlayerStart VMWare Player

Click on this pictureClick on this picture Choose Ubuntu VMChoose Ubuntu VM

Wait the promptWait the prompt

Page 8: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 8

Ubuntu 9.04 : ConfigurationUbuntu 9.04 : Configuration

Change keyboard configurationChange keyboard configuration sudo dpkg-reconfigure console-setup sudo dpkg-reconfigure console-setup

Change « notroot » user passwordChange « notroot » user password Passwd <my-password>Passwd <my-password>

For more informations about how to configure For more informations about how to configure VMWare ImageVMWare Image http://www.thoughtpolice.co.uk/vmware/howto/1-http://www.thoughtpolice.co.uk/vmware/howto/1-

minute-guide.htmlminute-guide.html

Page 9: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 9

Update packagesUpdate packages

Type this commands :Type this commands : sudo apt-get updatesudo apt-get update sudo apt-get upgradesudo apt-get upgrade

For more information about apt-get command For more information about apt-get command https://help.ubuntu.com/community/AptGet/https://help.ubuntu.com/community/AptGet/

HowtoHowto

Page 10: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 10

SSH InstallationSSH Installation GoalsGoals

Creating communication between Putty/Winscp and Ubuntu Creating communication between Putty/Winscp and Ubuntu VmWare Server.VmWare Server.

Type the command : Type the command : sudo apt-get install sshsudo apt-get install ssh

Keep your Server IPKeep your Server IP ifconfigifconfig

Page 11: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 11

TroobleshootingTroobleshooting If you have only If you have only

Then type this commandsThen type this commands sudo rm /etc/udev/rules.d/70-persistent-net.rulessudo rm /etc/udev/rules.d/70-persistent-net.rules

sudo rebootsudo reboot

Page 12: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 12

Connexion to your serverConnexion to your server Check your connexion with WinSCPCheck your connexion with WinSCP

LoginLogin

Page 13: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 13

Ubuntu configuration Ubuntu configuration Verify your connexion with PuttyVerify your connexion with Putty

LoginLogin

Page 14: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 14

Modify rightsModify rightsModifying rights on installation folderModifying rights on installation folder

sudo chown -R notroot /optsudo chown -R notroot /opt

Page 15: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 15

Your Image is now Your Image is now READY !READY !

Page 16: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

EXTRASEXTRAS

Page 17: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 17

CHANGE HOSTNAMECHANGE HOSTNAME CHANGE IPCHANGE IP INSTALL JAVA 1.6INSTALL JAVA 1.6 INSTALL UNZIPINSTALL UNZIP INSTALL OPENOFFICEINSTALL OPENOFFICE INSTALL MYSQLINSTALL MYSQL INSTALL POSTGRESQLINSTALL POSTGRESQL

SUMMARYSUMMARY

Page 18: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

HostnameHostname

Page 19: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 19

HOSTNAMEHOSTNAME

Change hostname Change hostname sudo hostname <my-hostname> sudo hostname <my-hostname> sudo vi /etc/hostssudo vi /etc/hosts

sudo vi /etc/hostnamesudo vi /etc/hostnamesudo rebootsudo reboot

<my-hostname> <my-hostname>

<my-hostname>

Page 20: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

UnzipUnzip

Page 21: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 21

Unzip InstallationUnzip Installation Connect to your Ubuntu Server with puttyConnect to your Ubuntu Server with putty ::

sudo apt-get install unzipsudo apt-get install unzip

Page 22: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

Image MagickImage MagickOpen OfficeOpen OfficeSWFToolsSWFTools

Page 23: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 23

Transformer InstallationTransformer Installation Connect to your Ubuntu Server with puttyConnect to your Ubuntu Server with putty ::

Sudo apt-get install 'openoffice.org’Sudo apt-get install 'openoffice.org’ Sudo apt-get install swftoolsSudo apt-get install swftools Sudo apt-get install imagemagickSudo apt-get install imagemagick

Page 24: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

JavaJava

Page 25: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 25

JVM InstallationJVM Installation Connect to your Ubuntu Server with puttyConnect to your Ubuntu Server with putty ::

sudo apt-get install sun-java6-jdksudo apt-get install sun-java6-jdk

Page 26: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 26

JVM Installation : environment variablesJVM Installation : environment variables Define the CLASSPATH & JAVA_HOME variableDefine the CLASSPATH & JAVA_HOME variable : :

vi /home/notroot/.bashrcvi /home/notroot/.bashrc

Add following lines at the end of the fileAdd following lines at the end of the file

Restart PuttyRestart Putty

Check the following message is displayedCheck the following message is displayed

Page 27: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

MySQLMySQL

Page 28: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 28

MySQL installation MySQL installation Connect to your Ubuntu Server with puttyConnect to your Ubuntu Server with putty ::

sudo apt-get install mysql-serversudo apt-get install mysql-server

For more details on mysql installation : For more details on mysql installation : https://help.ubuntu.com/community/https://help.ubuntu.com/community/

JDBCAndMySQL?highlight=%28mysql%29JDBCAndMySQL?highlight=%28mysql%29

Page 29: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 29

MySQL Installation MySQL Installation Modifying rights to permit remote accessModifying rights to permit remote access

sudo vi /etc/mysql/my.cnfsudo vi /etc/mysql/my.cnf Comment the lineComment the line Edit this line Edit this line

Connect to MySQL with command linesConnect to MySQL with command lines sudo mysql –u root –psudo mysql –u root –p

To prompt, execute this commandsTo prompt, execute this commands grant all privileges on *.* to 'root'@‘<ip.address>' with grant option;grant all privileges on *.* to 'root'@‘<ip.address>' with grant option; set password for 'root'@’<ip.address>'=password(’<password>');set password for 'root'@’<ip.address>'=password(’<password>');

Page 30: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 30

MySQL Installation MySQL Installation

Restart MysqlRestart Mysql sudo /etc/init.d/mysql restartsudo /etc/init.d/mysql restart

Check yout installationCheck yout installation mysql -u root -p <password>mysql -u root -p <password>

Page 31: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 31

MySQL GUI Tools InstallationMySQL GUI Tools Installation

Download the last version of MySQL GUI ToolsDownload the last version of MySQL GUI Tools RessourceRessource : Mysql GUI Tools : Mysql GUI Tools

Follow installation wizard instructionsFollow installation wizard instructions

Page 32: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 32

MySQL GUI Tools Installation MySQL GUI Tools Installation

Run MySQL AdministratorRun MySQL Administrator

Check your connexionCheck your connexion

Page 33: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

PostgreSQLPostgreSQL

Page 34: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 34

PostgreSQL Installation PostgreSQL Installation Connect to your Ubuntu Server with puttyConnect to your Ubuntu Server with putty::

sudo apt-get install postgressudo apt-get install postgres

For more informationsFor more informationshttps://help.ubuntu.com/community/PostgreSQLhttps://help.ubuntu.com/community/PostgreSQLhttp://www.postgresql.org/docs/http://www.postgresql.org/docs/

Page 35: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 35

PostgreSQL InstallationPostgreSQL InstallationHow to init postgres password How to init postgres password (Database side)(Database side)

sudo su postgres -c psql template1sudo su postgres -c psql template1 ALTER USER postgres WITH PASSWORD 'password';ALTER USER postgres WITH PASSWORD 'password'; \q\q (to quit)(to quit)

How to init postgres password How to init postgres password (linux user side)(linux user side)

Page 36: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 36

PostgreSQL InstallationPostgreSQL Installation To create a remote access to PostgreSQLTo create a remote access to PostgreSQL

Edit configuration file Edit configuration file sudo vi sudo vi

/etc/postgresql/8.3/main/postgresql.conf/etc/postgresql/8.3/main/postgresql.conf Open remote access Open remote access

uncomment this lineuncomment this lineChange this line Change this line

Password protectionPassword protectionUncomment this lineUncomment this line

Page 37: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 37

PostgreSQL InstallationPostgreSQL Installation To create a remote access to PostgreSQLTo create a remote access to PostgreSQL

Edit configuration fileEdit configuration filesudo vi /etc/postgresql/8.3/main/pg_hba.confsudo vi /etc/postgresql/8.3/main/pg_hba.conf

Open remote accessOpen remote access Add this line at the end of the fileAdd this line at the end of the file

Your server IP

Page 38: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 38

PostgreSQL InstallationPostgreSQL InstallationRestart PostgreSQLRestart PostgreSQL

sudo /etc/init.d/postgresql-8.3 restart sudo /etc/init.d/postgresql-8.3 restart

Page 39: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 39

Pgadmin III Installation Pgadmin III Installation Download this application at :Download this application at :

http://www.pgadmin.org/download/http://www.pgadmin.org/download/

Page 40: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 40

Pgadmin III InstallationPgadmin III InstallationUnzip the file and execute Unzip the file and execute Follow the wizardFollow the wizard

Page 41: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 41

Using PGAdmin IIIUsing PGAdmin IIIStart pgadmin IIIStart pgadmin IIIClick on this picture to addClick on this picture to add

a servera server

Fill the form Fill the form

<hostname>

Page 42: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

08/04/23 http://www.open-source-ecm.com/ 42

Using PGAdmin IIIUsing PGAdmin IIICheck Server propertiesCheck Server properties

<hostname>

Page 43: [VMWARE][ENG]How-To Simple install and configure an Ubuntu Virtual Server

How to prepare How to prepare Ubuntu 9.04 VMWare ImageUbuntu 9.04 VMWare Image

from from http://www.thoughtpolice.co.uk/http://www.thoughtpolice.co.uk/

By JM.PASCALBy JM.PASCAL

www.opensourceecm.frwww.opensourceecm.fr&&

www.open-source-ecm.comwww.open-source-ecm.com