Difference between revisions of "FOG installation on CentOS5"
m (→Links) |
m (→Kickstart file) |
||
Line 198: | Line 198: | ||
# Set the root password for the DCUI and Tech Support Mode | # Set the root password for the DCUI and Tech Support Mode | ||
rootpw Password | rootpw Password | ||
+ | # Clears the entire disk | ||
+ | clearpart --firstdisk --all --overwritevmfs | ||
# Choose the first discovered disk to install onto | # Choose the first discovered disk to install onto | ||
autopart --firstdisk --overwritevmfs | autopart --firstdisk --overwritevmfs |
Revision as of 21:44, 12 February 2011
What is FOGFOG is a free open-source cloning/imaging solution/rescue suite. An alternative solution used to image Windows XP, Vista, Windows 7 PCs using PXE, PartImage, and a Web Gui to tie it together. Includes featues like memory and disk test, disk wipe and av scan Getting preparedAfter installing CentOS 5.2 with firewall and SeLinux disabled.
Install yum-proorities[root@fog1 ~]# <input>yum install yum-priorities</input>
<notice>OUTPUT OMITTED</notice>
[root@fog1 ~]# <input>yum info yum-priorities</input>
Installed Packages
Name : yum-priorities
Arch : noarch
Version : 1.1.16
Release : 13.el5.centos
Size : 13 k
Repo : installed
Summary : plugin to give priorities to packages from different repos
URL : http://linux.duke.edu/yum/download/yum-utils/
License : GPLv2+
Description: This plugin allows repositories to have different priorities.
: Packages in a repository with a lower priority can't be overridden
: by packages from a repository with a higher priority even if repo
: has a later version. |
Install rpmforge-release
Get newest rpmforge-release for your release
[root@fog1 ~]# <input>cd /tmp</input>
[root@fog1 tmp]# <input>wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.3.6-1.el5.rf.i386.rpm</input>
[root@fog1 tmp]# <input>rpm -i rpmforge-release-0.3.6-1.el5.rf.i386.rpm</input>
[root@fog1 tmp]# <input>rpm -qi rpmforge-release</input>
Description :
RPMforge.net release file. This package contains apt, yum and smart
configuration for the RPMforge RPM Repository, as well as the public
GPG keys used to sign them.
Download and install FOG
Download FOG from FOG download Select latest fog_x.xx.tar.gz and extract the files.
- When I downloaded the latest version was fog_0.26.tar.gz. (Henrik Thomsen 04:01, 2 June 2009)
[root@fog1 tmp]# <input>wget http://dfn.dl.sourceforge.net/sourceforge/freeghost/fog_0.26.tar.gz</input>
[root@fog1 tmp]# <input>tar xzf fog_0.26.tar.gz</input>
[root@fog1 tmp]# <input>cd fog_0.26</input>
[root@fog1 fog_0.26]# <input>cd bin</input>
[root@fog1 bin]# <input>./installfog.sh</input>
___ ___ ___
/\ \ /\ \ /\ \
/::\ \ /::\ \ /::\ \
/:/\:\ \ /:/\:\ \ /:/\:\ \
/::\-\:\ \ /:/ \:\ \ /:/ \:\ \
/:/\:\ \:\__\ /:/__/ \:\__\ /:/__/_\:\__\
\/__\:\ \/__/ \:\ \ /:/ / \:\ /\ \/__/
\:\__\ \:\ /:/ / \:\ \:\__\
\/__/ \:\/:/ / \:\/:/ /
\::/ / \::/ /
\/__/ \/__/
###########################################
# Free Computer Imaging Solution #
# #
# Created by: #
# Chuck Syperski #
# Jian Zhang #
# #
# GNU GPL Version 3 #
###########################################
Version: 0.26 Installer/Updater
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: []<input>1</input>
<notice>OUTPUT OMITTED</notice>
Here are the settings FOG will use:
Distro: Redhat
Installation Type: Normal Server
Server IP Address: 192.168.22.3
DHCP router Address: 192.168.22.73
DHCP DNS Address: 172.16.4.77
Interface: eth0
Using FOG DHCP: 1
Are you sure you wish to continue (Y/N)<input>y</input>
During installation
The Foginstaller installs various packages, check them and installs and configures the services. Quite impressive install script which do all the hard work for you.
Enabling Wake On Lan
To enable Wake On Lan, Remote Shell or rsh must be enabled using sudo. Using visudo Comment the line If you would like to use wake on lan with FOG, you will have to run the following commands as root:
[root@fog1 bin]# <input>visudo</input>
Scroll to the line that says
Defaults requiretty
Press i to enter insert mode. Change the line to:
<input>#</input> Defaults requiretty
Hit ESC to exit insert mode. Now type:
<input>:wq</input>
and press the enter key.
Login from WEB server
Login as username: fog password: password .. Remember to change password!
Preparing the Master Client host
Windows XP
Install Windows XP service Pack 2 support tools and if using the 'danish edition of Windows XP edit C:\Program files\FOG\etc\config.ini line with the path to netdom.exe from C:\Program files\Support tools\netdom.exe to C:\Programmer\Support tools\netdom.exe
Install fog client http://192.168.22.3/fog/client program. (Note below Danish version of XP)
Issues
With FOX Service Installer (FOX Tray version 0.1) The installer installs in C:\Program files\FOX but looks for the FoxServiceConfig.exe in C:\programmer\FOX in the danish version of XP.
Windows 2003
Fog service
After installing the support tool you need to install the fog service
Go to http://FogServerNameOrIP/fog/client webpage
Files
Installed version 0.28 (Same procedure)
- logfiles: /opt/fog/log
- basic Configfile: /opt/fog/service/etc/config.php
- www installation: /var/www/html/fog
/opt/fog/service/etc/config.php
- UDPSENDER_MAXWAIT: default null wait forever on all multicast members. Set to seconds to abandom stucked hosts.
DHCP on another server
- On a Linux DHCP server you must set: next-server
- On a Windows DHCP server you must set: option 066 & 067
Known issues
Uploading images with NTFS (XP) to machines which had a linux EXT3 filesystem (CentOS 5.2) gave problems. The Restore process on the client never started. It just bootet from the server saying "Please Wait" on the blue screen - then jumped direcly to Cleanup.
After running Fast-Wipe on the machines, everything was OK.
Customization
ESXi installer
To enable the functionality to install ESXi from the FOG server we need to add the ESXi install image and create a new menu in the FOG install menu.
TFTP files needed for installation
From the VMWare ESXi install iso extract these files into an tftp folder:
cim.vgz
ienviron.vgz
install.vgz
mboot.c32
menu.c32
sys.vgz
vmkboot.gz
vmkernel.gz
In the FOG installation its called /tftboot/ESXi/
NFS files needed for installation
Create a place where the installation can access the rest of the files from the install iso. In this installation its located at /tftpboot/ESXi/iso/. Copy the files from the iso to this folder and export it via nfs:
/etc/exports:
# Install folder for ESXi
/tftpboot/ESXi/iso *(rw,sync,no_wdelay,no_root_squash,insecure)
pxelinux.cfg/default
Add this enty to the default pxe file:
LABEL esx.install
kernel ESXi/mboot.c32
append ESXi/vmkboot.gz ks=http://fog.tekkom.dk/kickstart/ESXi.ks --- ESXi/vmkernel.gz --- ESXi/sys.vgz --- ESXi/cim.vgz --- ESXi/ienviron.vgz --- ESXi/install.vgz
MENU LABEL Install VMWare ESXi 4.1
TEXT HELP
This will install VMware ESXi 4.1 and wipe the HDD.
Default password = Password
ENDTEXT
\n
Kickstart file
The kickstart file is located on a web server and contains the installation notes.
/var/www/html/kickstart/ESXi.ks:
# Accept the VMware End User License Agreement
vmaccepteula
# Set the root password for the DCUI and Tech Support Mode
rootpw Password
# Clears the entire disk
clearpart --firstdisk --all --overwritevmfs
# Choose the first discovered disk to install onto
autopart --firstdisk --overwritevmfs
# The installation media is NFS on the FOG server
install nfs --server=fog.tekkom.dk --dir=/tftpboot/ESXi/iso
# Set the network to DHCP on the first network adapater
network --bootproto=dhcp --device=vmnic0
#Enable SSH service when the host boots for the first time
%firstboot --unsupported --interpreter=busybox --level=899
vim-cmd hostsvc/enable_local_tsm
vim-cmd hostsvc/start_local_tsm
vim-cmd hostsvc/enable_remote_tsm
vim-cmd hostsvc/start_remote_tsm
# Mount a NFS datastore on the first boot
# Copy selected VM's to local datastore and add to inventory
# %firstboot --unsupported --interpreter=busybox --level=900
# esxcfg-nas –-add –-host 192.168.15.252 –-share /storage/iso ISO
# cp -r /vmfs/volumes/ISO/Server2008KursusMaskiner/* /vmfs/volumes/datastore1
# vmware-cmd -s register /vmfs/volumes/datastore1/Win2008/Win2008.vmx
Links
- FOG user Guide
- CloneZilla vs. FOG (Youtube)
- ESXi Installable and vCenter Server Setup Guide
- Mount NFS datastore from CLI
- Add splash screen to VMware
Notes
To make snapins try InstallRITE