|
foggy.phas.ubc.ca 142.103.243.243 (MAC: 00:14:5e:17:90:30) FOG Web Management Console |
Serial Number: KQRHR71 Qty Part No Description --- ------- ------------------------------------------------------------------------------------------ 1 797841U Express x3550 Intel Xeon 5130 2.00GHz 1333MHz FSB 2x2MB L2, 2x512MB, S/RAID 8k-l, 670W p/u 1 40K1239 Intel Xeon Dual Core 5130 2.00GHz 1333MHz FSB 2x2MB L2 Cache Processor 1 39M5791 4GB Kit (2x 2GB DIMM) PC2 5300 DDR2 FBD CL4 2 40K1039 73.4GB 10K 3.5in SAS Hot-Swap HDD (Old HDD replaced by the ones below) 2 42D0767 2 TB 7.2K 6 Gbps NL SAS 3.5-inch Hot-Swap HDD (Purchased in December 2011) 1 25R8079 ATB-205/32MB IBM ServeRaid 8k-l SAS Controller sSpec Number: SL9RX | CPU Speed: 2 GHz | PCG: | Bus Speed: 1333 MHz | Bus/Core Ratio: 6.0 | L2 Cache Size: 4 MB | L2 Cache Speed: 2 GHz Package Type: LGA771 | Manufacturing Technology: 65 nm | Core Stepping: B2 | CPUID String: 06F6h | Thermal Design Power: 65W | Thermal Specification: 65°C | Core Voltage: Supported Features: Dual Core | Enhanced Halt State (C1E) | Execute Disable Bit | Intel EM64T | Intel Thermal Monitor | Intel Virtualization Technology

DISASTER RECOVERY
|
| Partition Info: |
Device Size Mount Point/ Type Location
RAID/Volume
LVM Volume Groups
vg_foggy 1907096
lv_root 51200 / ext4 /dev/mapper/vg_foggy-lv_root
lv_home 102400 /home ext4 /dev/mapper/vg_foggy-lv_home
lv_swap 11184 swap /dev/mapper/vg_foggy-lv_swap
lv_images 1742312 /images ext4 /dev/mapper/vg_foggy-lv_images
Hard Drives
sda (/dev/sda)
sda1 500 /boot ext4
sda2 1907099 vg_foggy physical volume (LVM)
|
| Install RHEL Server 6.0 i386 as webserver |
# vi /etc/selinux/config SELINUX=permissive # vi /etc/sysconfig/iptables *filter :INPUT ACCEPT [0:0] :FORWARD ACCEPT [0:0] :OUTPUT ACCEPT [5505:853819] -A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT -A INPUT -p icmp -j ACCEPT -A INPUT -i lo -j ACCEPT -A INPUT -s 142.103.237.128/25 -j ACCEPT -A INPUT -s 142.103.238.0/24 -j ACCEPT -A INPUT -s 142.103.239.0/24 -j ACCEPT -A INPUT -s 142.103.243.0/24 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 22 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 69 -j ACCEPT -A INPUT -p tcp -m state --state NEW -m tcp --dport 443 -j ACCEPT -A INPUT -j REJECT --reject-with icmp-host-prohibited -A FORWARD -j REJECT --reject-with icmp-host-prohibited COMMIT |
| Install FOG 0.32 |
# cd /opt
# wget http://sourceforge.net/projects/freeghost/files/FOG/fog_0.32/fog_0.32.tar.gz/download?use_mirror=cdnetworks-us-2
# tar -zxvf fog_0.32.tar.gz
# vi fog_0.32/lib/redhat/config.sh
remove the following items from the packages="..." section: php-gettext, htmldoc, clamav_update
they are either already installed or not needed
# cd fog_0.32/bin
# ./installfog.sh
What version of Linux would you like to run the installtion for?
1) Redhat Based Linux (Fedora, CentOS)
2) Ubuntu Based Linux (Kubuntu, Edubuntu)
Choice: [] 1
FOG Server installation modes:
* Normal Server: (Choice N)
* Storage Node: (Choice S)
What type of installation would you like to do? [N]
What is the IP address to be used by this FOG Server? [142.103.243.243]
Would you like to setup a router address for the DHCP server? [Y/n]
What is the IP address to be used for the router on the DHCP server? [142.103.243.254]
Would you like to setup a DNS address for the DHCP server and client boot image? [Y/n]
What is the IP address to be used for DNS on the DHCP server and client boot image? [142.103.236.1]
Would you like to change the default network interface from eth0?
If you are not sure, select No. [y/N]
Would you like to use the FOG server for dhcp service? [Y/n] N
This version of FOG has internationalization support, would
you like to install the additional language packs? [Y/n] N
If you want to run the installfog.sh to update the FOG server settings, rename the hidden .fogsettings file located under /opt/fog/:
sudo mv /opt/fog/.fogsettings /opt/fog/fogsettings-firstInstallOpen web broswer at the fog management url (http://foggy.phas.ubc.ca/fog/management) When prompted, choose to install the database schema Login with the following default credentials Username: fog Password: password |
| Change MySQL and FOG passwords | Add password to MySQL root account |
# mysqladmin -u root password [NEWPASSWORD] | Configure phpMyAdmin |
# cd /etc/httpd/conf.d # vi ssl.conf add the following line to the end of the file: Include conf.d/ssl.phpMyAdmin_conf # cp phpMyAdmin.conf ssl.phpMyAdmin_conf # vi ssl.phpMyAdmin_conf modify the following section to allow access from phas network Directory /usr/share/phpMyAdmin/ Order Deny,Allow Deny from All Allow from 127.0.0.1 Allow from 142.103.235.0/24 Allow from 142.103.236.0/24 Allow from 142.103.237.128/25 Allow from 142.103.238.0/24 Allow from 142.103.239.0/24 Allow from 128.189.122.32/27 Allow from ::1 /Directory> # cd /usr/share/phpMyAdmin/ # cp config.sample.inc.php config.inc.php # vi config.inc.php | Change MySQL user and password in FOG |
On phpMyAdmin page, create a new user: fogserver Give user fogserver full permission to fog table Change FOG configuration file to use fogserver to connect to MySQL: # vi /var/www/html/fog/commons/config.php define( "MYSQL_DATABASE", "fog" ); define( "MYSQL_USERNAME", "fogserver" ); define( "MYSQL_PASSWORD", "PASSWORD" ); |
$ cd /var/www/html
$ mkdir systemrescue
$ cd /var/www/html/systemrescue
$ mount -o /tmp/systemrescuecd-x64-4.3.0.iso /media
$ cp /media/sysrcd.md5 .
$ cp /media/sysrcd.dat .
$ cp /media/isolinux/initram.igz .
$ cp /media/isolinux/rescue32 .
$ cp /media/isolinux/rescue64 .
$ umount /media
$ rm /tmp/systemrescuecd-x86-4.3.0.iso
Add an entry to the fog advanced boot menu (Fog Configuration -> PXE Boot Settings -> Advanced Boot Menu)
#!ipxe
cpuid --ext 29 && set arch x86_64 || set arch i386
colour --rgb 0xff6600 2
cpair --foreground 7 --background 2 2
console --picture http://${fog-ip}/fog/service/ipxe/bg.png --left 100 --right 80
:MENU
menu
colour --rgb 0xff0000 0
cpair --foreground 0 3
item --gap -- -------------------------------------
item sysrcd64 SystemRescueCD (64 bit)
item sysrcd32 SystemRescueCD (32 bit)
choose target && goto ${target}
:sysrcd64
kernel /systemrescue/rescue64 scandelay=1 docache netboot=http://${fog-ip}/systemrescue/sysrcd.dat
initrd /systemrescue/initram.igz
boot || goto MENU
:sysrcd32
kernel /systemrescue/rescue32 scandelay=1 docache netboot=http://${fog-ip}/systemrescue/sysrcd.dat
initrd /systemrescue/initram.igz
boot || goto MENU
autoboot
Login foggy from terminal
[root@foggy pxelinux.cfg]# vi /tftpboot/pxelinux.cfg/default DEFAULT vesamenu.c32 MENU TITLE FOG Computer Cloning Solution MENU BACKGROUND fog/bg.png MENU MASTER PASSWD $1$NnSyk0$4e3IRgsUZTF2s52Ky3oe11 \n menu color title 1;36;44 #ffffffff #00000000 std \n LABEL fog.local localboot 0 MENU DEFAULT MENU LABEL Boot from hard disk TEXT HELP Boot from the local hard drive. If you are unsure, select this option. ENDTEXT \n LABEL fog.memtest kernel fog/memtest/memtest MENU LABEL Run Memtest86+ MENU PASSWD $1$NnSyk0$4e3IRgsUZTF2s52Ky3oe11 TEXT HELP Run Memtest86+ on the client computer. ENDTEXT \n LABEL fog.reg kernel fog/kernel/bzImage append initrd=fog/images/init.gz root=/dev/ram0 rw ramdisk_size=127000 ip=dhcp dns=142.103.236.1 mode=autoreg web=142.103.243.243/fog/ loglevel=4 MENU LABEL Quick Host Registration and Inventory TEXT HELP Automatically register the client computer, and perform a hardware inventory. ENDTEXT \n LABEL fog.reginput kernel fog/kernel/bzImage append initrd=fog/images/init.gz root=/dev/ram0 rw ramdisk_size=127000 ip=dhcp dns=142.103.236.1 mode=manreg web=142.103.243.243/fog/ loglevel=4 MENU LABEL Perform Full Host Registration and Inventory TEXT HELP Perform a full host registration on the client computer, perform a hardware inventory, and optionally image the host. ENDTEXT \n LABEL fog.quickimage MENU PASSWD $1$NnSyk0$4e3IRgsUZTF2s52Ky3oe11 kernel fog/kernel/bzImage append initrd=fog/images/init.gz root=/dev/ram0 rw ramdisk_size=127000 ip=dhcp dns=142.103.236.1 mode=quickimage keymap= web=142.103.243.243/fog/ loglevel=4 MENU LABEL Quick Image TEXT HELP This mode will allow you to image this host quickly with it's default assigned image. ENDTEXT LABEL fog.sysinfo MENU PASSWD $1$NnSyk0$4e3IRgsUZTF2s52Ky3oe11 kernel fog/kernel/bzImage append initrd=fog/images/init.gz root=/dev/ram0 rw ramdisk_size=127000 ip=dhcp dns=142.103.236.1 mode=sysinfo loglevel=4 MENU LABEL Client System Information TEXT HELP View basic client information such as MAC address and FOG compatibility. ENDTEXT \n LABEL fog.debug MENU PASSWD $1$NnSyk0$4e3IRgsUZTF2s52Ky3oe11 kernel fog/kernel/bzImage append initrd=fog/images/init.gz root=/dev/ram0 rw ramdisk_size=127000 ip=dhcp dns=142.103.236.1 mode=onlydebug MENU LABEL Debug Mode TEXT HELP Debug mode will load the boot image and load a prompt so you can run any commands you wish. ENDTEXT \n LABEL System Rescue CD "Live Image" MENU LABEL System Rescue CD MENU PASSWD $1$NnSyk0$4e3IRgsUZTF2s52Ky3oe11 LINUX sysrescue/rescuecd INITRD sysrescue/initram.igz APPEND scandelay=1 docache netboot=nfs://foggy.phas.ubc.ca:/images/sysrescue setkmap=us TEXT SystemRescueCD network boot image (recovery) ENDTEXT \n PROMPT 0 TIMEOUT 30\n
Go to Web GUI: http://foggy.phas.ubc.ca
1. Go to Storage Management 2. Add Storage Groups Storage Group Name: Astro Storage Group Description: Storage group for Astro computers 3. Add Storage Nodes Storage Node Name: astro Storage Node Description: Storage node for astro images IP Address: 142.103.243.243 Max Clients: 20 Is Master Node: Yes Storage Group: Astro Image Location: /images/astro Is Enabled: Yes Managment Username: fog Management Password: encypted password
ssh in foggy server
ssh root@foggy cd /images mkdir astro chmod 777 astro cp -r /images/dev /images/astro/ cp /images/.mntcheck /images/astro/ vi /etc/exports add the following two lines: /images/astro *(ro,sync,no_wdelay,insecure_locks,no_root_squash,insecure) /images/astro/dev *(rw,sync,no_wdelay,no_root_squash,insecure) exportfs -av
Reference: Change_NFS_location
Go to Web GUI: http://foggy.phas.ubc.ca
1. Go to Other Information tab 2. Click on FOG Settings 3. Enter the following Active Directory Defaults: FOG_AD_DEFAULT_DOMAINNAME: phas.ubc.ca FOG_AD_DEFAULT_OU FOG_AD_DEFAULT_USER : phas\bigcheese FOG_AD_DEFAULT_PASSWORD : (encrypted password created by FOGCrypt.exe) 4. When add new computer, enable Join Domain after image task
Go to Web GUI: http://foggy.phas.ubc.ca
1. Go to Snap-in Management tab 2. Click New Snapin 3. Snapin Name: KMS-win7 Snapin File: upload UBC_KMS.cmd script 4. Click Add, then apply the snap-in to Windows 7 host
UBC_KMS.cmd script:
"%windir%\system32\cscript.exe" "%windir%\system32\slmgr.vbs" -skms kms1.it.ubc.ca "%windir%\system32\cscript.exe" "%windir%\system32\slmgr.vbs" -ato IF EXIST "%ProgramFiles(x86)%\Microsoft Office\Office14\ospp.vbs" ( cscript "%ProgramFiles(x86)%\Microsoft Office\Office14\ospp.vbs" /sethst:kms1.it.ubc.ca cscript "%ProgramFiles(x86)%\Microsoft Office\Office14\ospp.vbs" /act ) ELSE ( cscript "%ProgramFiles%\Microsoft Office\Office14\ospp.vbs" /sethst:kms1.it.ubc.ca cscript "%ProgramFiles%\Microsoft Office\Office14\ospp.vbs" /act )
Download System rescue CD from http://www.sysresccd.org/Download and loopback mounted it
cd /tmp mkdir sysrescueCD mount -o loop -t iso9660 systemrescuecd-x86-2.7.1.iso /tmp/sysrescueCD
On the fog server created /tftpboot/sysrescue and /images/sysrescue
mkdir /tftpboot/sysrescue mkdir /images/sysrescue
Copy the necessary kernel and ramdisk into place.
cp /tmp/sysrescueCD/isolinux/initram.igz /tftpboot/sysrescue cp /tmp/sysrescueCD/isolinux/rescuecd /tftpboot/sysrescue
Next copy the sysrcd.dat and sysrcd.md5 files into place
cp /tmp/sysrescueCD/sysrcd.md5 /images/sysrescue cp /tmp/sysrescueCD/sysrcd.dat /images/sysrescue
Ensure that the new nfs directory will be exported by adding the following line to /etc/exports
/images/sysrescue *(ro,insecure)
And export it
exportfs -va
Now update the prelinux menu settings by editing /tftpboot/pxelinux.cfg/default, and add the following section to the end of the file.
LABEL System Rescue CD "Live Image"
LINUX sysrescue/rescuecd
INITRD sysrescue/initram.igz
APPEND scandelay=1 docache netboot=nfs://foggy.phas.ubc.ca:/images/sysrescue setkmap=us
TEXT
SystemRescueCD network boot image (recovery)
ENDTEXT
FOG kernel 3.2.4 supports ext4
cd /tftpboot/fog/kernel wget http://sourceforge.net/projects/freeghost/files/Kernels/Kernel-3.2.4.core/Kernel-3.2.4.core/download mv bzImage bzImage.bak mv Kernel-3.2.4.core bzImage
scp /images/dev/.mntcheck /images/.
-A INPUT -s 142.103.237.128/25 -j ACCEPT -A INPUT -s 142.103.238.0/24 -j ACCEPT -A INPUT -s 142.103.239.0/24 -j ACCEPT -A INPUT -s 142.103.243.0/24 -j ACCEPT
mysqldump fog > /home/phasadmin/fog.sql scp /home/phasadmin/fog.sql root@foggy:/opt/fog/.2. Import fog database on Foggy server
mysql -u root -p fog < /opt/fog/fog.sql3. Change fog user password on foggy server
- Reset the local password for user fog with: [sudo] passwd fog
- In management front end,
Go to Storage Management -> All Storage Nodes
Click on DefaultMember
Change the Management Password to match the password you just changed.
Go to Other Information and change FOG_TFTP_FTP_PASSWORD also.
- Restart the service: service vsftpd restart
4. Change fog web management login password
Login FOG Web Management: https://foggy.phas.ubc.ca
Go to User Management
Click on fog
Type in the new password twice
Click on Update
5. Change fog server settings
Login FOG Web Management: https://foggy.phas.ubc.ca
Go to Other Information -> FOG Settings
Under General Settings, change FOG_WOL_HOST to 142.103.243.243
Under TFTP Server, change FOG_TFTP_HOST to 142.103.243.243
Under Web Server, change FOG_WEB_HOST to 142.103.243.243
6. On Foggy server, copy images from Cobra to Foggy
cd /images scp -r phasadmin@cobra:/images/* .
wget http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-5.noarch.rpm rpm -Uvh epel-release-6-5.noarch.rpm yum update yum install phpmyadmin
For more assistance
contact sysadmin@phas.ubc.ca
( Sysadmin
)
| webmaster@phas.ubc.ca | [Dept. Home Page] | last updated: |