Changes between Version 17 and Version 18 of ubuntuinstall


Ignore:
Timestamp:
Nov 23, 2016, 4:55:14 PM (7 years ago)
Author:
admin
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • ubuntuinstall

    v17 v18  
    3939=== Setting up boot device and Booting===
    4040
    41  - Click on '''Storage''' title and select '''CD ROM icon''' under the '''Controller:IDE''' Click on CD ROM icon under the '''Attribute''' on the left side to select
     41 - Click on '''Storage''' title and select '''CD ROM icon''' with Caption "Empty" under the '''Controller:IDE''', Click on CD ROM icon under the '''Attribute''' on the left side to select
    4242 - Choose '''Virtual Optical Disk File'''
    43  - Locate the '''Ubuntu CD Image''' file you downloaded from the LEARN ftp
    44  - Right click on VM to make a '''Normal Start''' VM. You should now see a separate window with Installation screen
     43 - Locate the '''Ubuntu CD Image''' file you downloaded from the LEARN ftp. Press OK to close the settings window.
     44 - Right click on VM and select Start to make a '''Normal Start'''. You should now see a separate window with Installation screen"
    4545
    4646== Installation ==
     
    5757Now it might take sometime to detect the hardware and load the necessary Linux modules
    5858
    59 Note that it configure network with DCHP
     59Note that it configure network with DHCP
    6060
    6161 - Type host name as: '''pc.'your domain'.ws.learn.ac.lk'''
    62  - When it asked, add a User by entering Your '''Name, your username, password'''
     62 - When it asked, add a User by entering Your '''Name, your username, password''' (Please give a strong password. This VM will be directly exposed to the internet)
    6363 - You may select '''No''' for not to encrypt home directory
    6464 - Select '''Yes''' confirm the time-zone
     
    6868    Your have 10GB hard drive previously configured for your VM
    6969 - Select '''Manual'''
    70  - Select the Disk '''SCSI3(0,0,0) (sda) - 10.0 GB ATA VBOX HARDDISK''' and Select '''Yes''' to create new partition table
    71  - Select Free Space to create following partitions and mount them as follows.
    72     * a primary partition for /boot 
    73        * Partition size: 512MB
    74        * Type : Primary
    75        * Location : Begining
    76        * Use as : Ext4
    77        * Mount point : /boot
    78        * Bootable flag : on
    79        * Done
    80     * a primary partition for Linux SWAP (two times the RAM) SWAP 2GB
    81        * Partition size:2GB
    82        * Type : Primary
    83        * Location : Begining
    84        * Use as : swap area
    85        * Done
    86  - Then use '''Logical Volume Manager''' to create a Volume Group named as "linux". create logical volumes for followings (Select the largest volume by pressing space key)
    87  - Create following Logical volumes and Select finish
    88     * a logical volume name : root, size : 2GB for /
    89     * a logical volume name : usr, size : 2GBfor /usr
    90     * a logical volume name : var, size : rest of the space for /var
    91  - Then select root Volume
    92    * Use as : Ext4
    93    * Mount point : /
    94    * Done
    95  - Then select usr Volume
     70 - Select the Disk '''SCSI3(0,0,0) (sda) - 10.0 GB ATA VBOX HARDDISK''' and Select '''Yes''' to create new partition table
     71 - Then select Free Space just below SCSI3(0,0,0) (sda) to create following partitions and mount them as follows.
     72 - Select '''Create new partition'''
     73    * Partition size: 512MB ---> Continue
     74    * Type : Primary
     75    * Location : Begining
     76    * Use as : Ext4
     77    * Change Mount point : /boot
     78    * Bootable flag : on
     79    * Select "Done setting up the partition"
     80    *
     81 - Again select FREE SPACE to create a primary partition for Linux SWAP (two times the RAM) SWAP 2GB
     82    * Partition size:2GB
     83    * Type : Primary
     84    * Location : Begining
     85    * Use as : swap area
     86    * Select "Done setting up the partition"
     87
     88 - Then '''select Logical Volume Manager'''  and press '''Yes'''.
     89 - Select '''create a Volume Group''' and name as "linux". When asked select '''FREE SPACE device (most probably /dev/sda free #1)''' and select '''yes''' for the confirmation
     90 - Go to '''create logical volumes''', select '''linux''', type logical volume name as '''root''', size : '''2GB'''
     91 - Repeat the same Create Logical Volume procedure and make another two volumes as usr and var
     92
     93   * a logical volume name : usr, size : 2GB
     94   * a logical volume name : var, size : rest of the space
     95
     96These Logical Volumes can be used as partitions containing file system root(/), /usr and /var.
     97
     98Now you will have 1 Volume Group and 3 Logical Volumes.
     99 - Once you finish creating logical volumes select '''finish'''. You will be once again presented with Disk Partition Window.
     100
     101 - Then Select #1 just below the LVM VG linux, LV root - 2.0 GB Linux device-mapper (linear) option and change Use as to '''Ext4''' , Mount point : '''/''' and Done.
     102 - Then repeat same for the #1 in  usr Volume with following options
    96103   * Use as : Ext4
    97104   * Mount point : /usr
    98    * Done
    99  - Then select var Volume
     105   * Done 
     106 - Then repeat same for the #1 in  var Volume with following options
    100107   * Use as : Ext4
    101108   * Mount point : /var
    102109   * Done
    103  - Then finish the partitioning and confirm it to write to the disk
     110
     111 - Then finish the partitioning and confirm it to write to the disk 
    104112
    105113Now it might take sometime to install the OS base.
     
    123131
    124132    You will now easily create the second VM using VM cloning. This VM is for your Web Server which will be used for hands-on tomorrow.
    125  - First Power off/shutdown your VM
     133 - First Log in to the VM and enter
     134{{{
     135 sudo init 0
     136}}}
    126137 - Right click on the VM to select Clone option
    127138 - Assign new name as www."your domain".ws.ac.lk
     
    237248$ pwd
    238249/home/dilum
     250
    239251$ cd  /etc
    240252/etc$ pwd
    241253/etc
     254
    242255$ cd ..
    243256/$ls
     
    245258boot  home        lib64       mnt    root  snap  tmp  vmlinuz
    246259dev   initrd.img  lost+found  opt    run   srv   usr
     260
    247261/$ ls -l
    248262total 85
     
    270284drwxr-xr-x  14 root root  4096 Nov 18 13:10 var
    271285lrwxrwxrwx   1 root root    29 Nov 18 13:04 vmlinuz -> boot/vmlinuz-4.4.0-21-generic
     286
    272287$ cd
     288
    273289$ pwd
    274290/home/dilum
     291
    275292$ mkdir test/one/.hidden
    276293mkdir: cannot create directory ‘test/one/.hidden’: No such file or directory
     294
    277295$ mkdir -p test/one/.hidden
     296
    278297$ mkdir -p test/one/unhidden
     298
    279299$ cd test/one
    280300test/one$ ls
     
    282302test/one$ ls -a
    283303.  ..  .hidden  unhidden
     304
    284305test/one$ rmdir unhidden/
     306
    285307test/one$ ls -a
    286308.  ..  .hidden
     309
    287310test/one$ cd
     311
    288312$ rmdir test
    289313rmdir: failed to remove ‘test’: Directory not empty
     
    514538 - Create another file numbers2.txt(with lines contain eleven to fifteen)
    515539{{{
    516 $ cat numbers2.txt
     540$ cat > numbers2.txt
    517541eleven
    518542twevelve
     
    751775iface enp0s3 inet static
    752776
    753    address 192.248.4.60
     777   address 'Your IP address'
    754778   netmask 255.255.255.0
    755    network 192.248.4.0
    756    broadcast 192.248.4.255
    757    gateway 192.248.4.254
     779   network 192.248.6.0
     780   broadcast 192.248.6.255
     781   gateway 192.248.6.254
    758782   dns-nameservers 192.248.1.161
    759    dns-search userx.ws.ac.lk
     783   dns-search 'your domain'
    760784}}}
    761785Change it to
     
    763787#iface enp0s3 inet static
    764788
    765 #    address 192.248.4.60
     789#    address 'Your IP address'
    766790#    netmask 255.255.255.0
    767 #    network 192.248.4.0
    768 #    broadcast 192.248.4.255
    769 #    gateway 192.248.4.254
     791#    network 192.248.6.0
     792#    broadcast 192.248.6.255
     793#    gateway 192.248.6.254
    770794#    dns-nameservers 192.248.1.161
    771 #    dns-search userx.ws.ac.lk
     795#    dns-search 'your domain'
    772796}}}
    773797Find the following line